/* なぞってひらがな — クレヨンと画用紙 */
:root {
  --paper: #fffaf0;
  --paper-2: #fff3dc;
  --card: #ffffff;
  --ink: #2f2a33;
  --ink-2: #5a5160;
  --rule: #ecd9c6;
  --c-red: #d63a2c;
  --c-orange: #e2701a;
  --c-yellow: #efb20a;
  --c-green: #2a8f43;
  --c-sky: #1f84c4;
  --c-blue: #3a4db5;
  --c-purple: #8448b8;
  --c-pink: #d9467f;
  --c-brown: #8a5a35;
  --go: #24803c;
  --hand: 22px 16px 24px 14px / 16px 24px 14px 22px;
  --hand-2: 14px 20px 12px 22px / 22px 12px 20px 14px;
  --f-kid: "Zen Maru Gothic", "Hiragino Maru Gothic ProN", "Hiragino Sans", sans-serif;
  --f-kana: "Klee One", "Zen Maru Gothic", serif;
  --f-num: "Fredoka", "Zen Maru Gothic", sans-serif;
  --f-adult: "BIZ UDPGothic", "Hiragino Sans", "Yu Gothic", sans-serif;
  --spring: cubic-bezier(.34, 1.56, .64, 1);
  --ease: cubic-bezier(.2, .8, .2, 1);
  --dock-h: 74px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
[hidden] { display: none !important; }
html, body { margin: 0; height: 100%; }
body {
  font-family: var(--f-kid); color: var(--ink); background: #f4e7cf;
  line-break: strict; overflow-wrap: break-word; -webkit-font-smoothing: antialiased;
  overflow: hidden;
}
img { display: block; max-width: 100%; height: auto; -webkit-user-drag: none; user-select: none; }
button { font: inherit; color: inherit; }
a { color: inherit; }
.kl { font-family: var(--f-kana); font-weight: 600; }
.num { font-family: var(--f-num); font-weight: 600; font-variant-numeric: tabular-nums; }
.nw { white-space: nowrap; }
h1, h2, h3 { font-feature-settings: "palt"; margin: 0; }
p { margin: 0; }

.app {
  position: relative; height: 100vh; height: 100dvh; max-width: 430px; margin: 0 auto;
  background: var(--paper); overflow: hidden; isolation: isolate;
}
@media (min-width: 600px) {
  body {
    background-color: #f4e7cf;
    background-image:
      radial-gradient(circle at 12% 20%, rgba(214, 58, 44, .14) 0 22px, transparent 23px),
      radial-gradient(circle at 85% 30%, rgba(31, 132, 196, .14) 0 30px, transparent 31px),
      radial-gradient(circle at 20% 80%, rgba(42, 143, 67, .14) 0 26px, transparent 27px),
      radial-gradient(circle at 80% 85%, rgba(239, 178, 10, .2) 0 34px, transparent 35px);
  }
  .app { box-shadow: 0 0 0 1px #e6d3b5, 0 20px 60px rgba(120, 80, 30, .18); }
}

/* ---------- 画面の枠 ---------- */
.stage { position: absolute; inset: 0; }
.app.has-dock .stage { bottom: calc(var(--dock-h) + env(safe-area-inset-bottom)); }
.scr { position: absolute; inset: 0; display: flex; flex-direction: column; background: var(--paper); transition: transform .32s var(--ease), opacity .32s var(--ease); }
.scr__body { flex: 1; overflow-y: auto; overflow-x: hidden; overscroll-behavior: contain; -webkit-overflow-scrolling: touch; }
.scr.is-enter.anim-push { transform: translateX(100%); }
.scr.is-leave.anim-push { transform: translateX(-24%); opacity: .6; }
.scr.is-enter.anim-pop { transform: translateX(-24%); opacity: .6; }
.scr.is-leave.anim-pop { transform: translateX(100%); z-index: 2; }
.scr.is-enter.anim-fade { opacity: 0; transform: scale(.985); }
.scr.is-leave.anim-fade { opacity: 0; }
.boot-fallback { padding: 80px 24px; text-align: center; font-size: 15px; line-height: 1.7; }
.boot-fallback__title { font-weight: 900; font-size: 22px; margin-bottom: 8px; }
.noscript { padding: 24px; }

/* ---------- 共通: ボタン ---------- */
.roundbtn {
  flex: none; width: 46px; height: 46px; display: grid; place-items: center; border: 2.5px solid var(--ink);
  border-radius: 50% 46% 52% 48% / 48% 52% 46% 50%; background: var(--card); cursor: pointer;
  box-shadow: 2px 3px 0 var(--ink); transition: transform .12s, box-shadow .12s;
}
.roundbtn svg { width: 26px; height: 26px; }
.roundbtn:active { transform: translate(2px, 3px); box-shadow: 0 0 0 var(--ink); }
.kbtn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px; min-height: 54px; padding: 0 22px;
  border: 3px solid var(--ink); border-radius: var(--hand); background: var(--card); color: var(--ink);
  font: 900 19px/1.2 var(--f-kid); text-decoration: none; cursor: pointer; word-break: keep-all;
  box-shadow: 3px 4px 0 var(--ink); transition: transform .12s, box-shadow .12s;
}
.kbtn svg { width: 22px; height: 22px; flex: none; }
.kbtn:active { transform: translate(3px, 4px); box-shadow: 0 0 0 var(--ink); }
.kbtn--go { background: var(--go); color: #fff; }
.kbtn--plain { background: var(--card); }

/* ---------- スプラッシュ・オンボーディング ---------- */
.splash { position: absolute; inset: 0; z-index: 50; display: grid; place-content: center; justify-items: center; gap: 18px; background: var(--paper); transition: opacity .3s; }
.splash img { width: 120px; height: 120px; border-radius: 28px; box-shadow: 0 10px 30px rgba(150, 90, 40, .22); animation: wob 1.2s var(--spring) both; }
.splash__name { font: 900 26px/1.2 var(--f-kid); word-break: keep-all; }
.splash.is-out { opacity: 0; }
@keyframes wob { 0% { transform: scale(.6) rotate(-8deg); } 100% { transform: none; } }
.onboard { position: absolute; inset: 0; z-index: 40; display: flex; flex-direction: column; background: #fff; transition: opacity .28s; }
.onboard.is-out { opacity: 0; }
.onboard__art { margin: 0; flex: 1; min-height: 0; overflow: hidden; background: #fff; }
.onboard__art img { width: 100%; height: 100%; object-fit: cover; object-position: center 70%; }
.onboard__card { padding: 22px 24px calc(22px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 3px solid var(--ink); border-radius: 30px 30px 0 0 / 22px 22px 0 0; margin-top: -26px; position: relative; }
.onboard__dots { display: flex; gap: 8px; margin-bottom: 12px; }
.onboard__dots i { width: 10px; height: 10px; border-radius: 50%; background: #e2d4c2; transition: width .2s; }
.onboard__dots i.is-on { width: 26px; border-radius: 6px; background: var(--c-red); }
.onboard__title { font: 900 24px/1.35 var(--f-kid); word-break: keep-all; }
.onboard__text { margin-top: 8px; font: 700 16px/1.75 var(--f-kid); color: var(--ink-2); }
.onboard__btns { display: flex; justify-content: space-between; gap: 12px; margin-top: 18px; }
.onboard__btns .kbtn { flex: 1; }

/* ---------- ドック（下のメニュー） ---------- */
.dock {
  position: absolute; left: 0; right: 0; bottom: 0; z-index: 20; display: flex; justify-content: space-around;
  height: calc(var(--dock-h) + env(safe-area-inset-bottom)); padding: 6px 10px env(safe-area-inset-bottom);
  background: var(--card); border-top: 3px solid var(--ink); border-radius: 26px 22px 0 0 / 14px 12px 0 0;
}
.dock[hidden] { display: none; }
.dock__tab { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; min-height: 56px; text-decoration: none; color: var(--ink-2); }
.dock__ic { position: relative; width: 64px; height: 38px; display: grid; place-items: center; }
.dock__svg { position: relative; width: 30px; height: 30px; transition: transform .3s var(--spring); }
.dock__scribble { position: absolute; inset: 0; width: 64px; height: 40px; fill: none; stroke: var(--c); stroke-width: 9; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 200; stroke-dashoffset: 200; opacity: .55; transition: stroke-dashoffset .5s var(--ease); }
.dock__label { font: 700 12px/1.2 var(--f-kid); white-space: nowrap; }
.dock__tab.is-on { color: var(--ink); }
.dock__tab.is-on .dock__scribble { stroke-dashoffset: 0; }
.dock__tab.is-on .dock__svg { transform: rotate(-6deg) scale(1.06); }
.dock__tab:active .dock__svg { transform: scale(.86); }

/* ---------- ヘッダー ---------- */
.top { flex: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: calc(12px + env(safe-area-inset-top)) 16px 10px; background: var(--paper); }
.top__brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.top__brand img { width: 40px; height: 40px; border-radius: 11px; border: 2px solid var(--ink); }
.top__title { font: 900 22px/1.2 var(--f-kid); word-break: keep-all; letter-spacing: .01em; }

/* ---------- もじをえらぶ ---------- */
.scr--pick .scr__body { padding: 4px 16px 24px; }
.next {
  display: flex; gap: 14px; align-items: center; padding: 14px; background: var(--paper-2);
  border: 3px solid var(--ink); border-radius: var(--hand); box-shadow: 4px 5px 0 var(--c-yellow);
}
.next__paper { position: relative; flex: none; width: 120px; height: 120px; background: #fff; border: 2.5px solid #d98b6a; border-radius: 16px; }
.next__paper .w { position: absolute; inset: 7px; width: calc(100% - 14px); height: calc(100% - 14px); }
.next__ch { display: none; }
.next__txt { min-width: 0; flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; }
.next__eyebrow { font: 700 14px/1.3 var(--f-kid); color: var(--ink-2); word-break: keep-all; }
.next__big { display: flex; align-items: baseline; gap: 8px; }
.next__big .kl { font-size: 44px; line-height: 1; }
.next__strokes { font: 700 15px/1 var(--f-kid); color: var(--ink-2); white-space: nowrap; }
.next .kbtn { min-height: 50px; padding: 0 16px; font-size: 18px; }

.meter { margin-top: 18px; display: flex; align-items: center; gap: 12px; }
.meter__txt { flex: none; display: flex; align-items: baseline; gap: 4px; font: 700 15px/1 var(--f-kid); white-space: nowrap; }
.meter__txt b { font-size: 30px; color: var(--c-red); margin-left: 2px; }
.meter__of { color: var(--ink-2); font-size: 14px; }
.meter__bar { flex: 1; height: 26px; }
.meter__bar svg { width: 100%; height: 100%; overflow: visible; }
.meter__track { fill: none; stroke: #f0e2cf; stroke-width: 16; stroke-linecap: round; }
.meter__fill { fill: none; stroke: var(--c-red); stroke-width: 14; stroke-linecap: round; }

.sect { margin: 22px 0 10px; font: 900 19px/1.3 var(--f-kid); display: flex; align-items: center; gap: 10px; }
.sect::after { content: ""; flex: 1; height: 3px; border-radius: 3px; background: repeating-linear-gradient(90deg, var(--rule) 0 10px, transparent 10px 16px); }

.gyos { display: grid; gap: 12px; }
.gyo { display: flex; gap: 10px; align-items: stretch; padding: 10px 10px 12px; background: #fff; border: 2.5px solid var(--c); border-radius: var(--hand-2); }
.gyo__pic { flex: none; width: 70px; display: flex; flex-direction: column; align-items: center; gap: 2px; text-decoration: none; }
.gyo__pic img { width: 66px; height: 66px; object-fit: cover; border-radius: 18px; transition: transform .25s var(--spring); }
.gyo__pic:active img { transform: rotate(-6deg) scale(.94); }
.gyo__word { font: 700 13px/1.2 var(--f-kid); color: var(--ink-2); white-space: nowrap; }
.gyo__main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.gyo__name { display: flex; justify-content: space-between; align-items: baseline; font: 900 15px/1.2 var(--f-kid); }
.gyo__num { font: 600 14px/1 var(--f-num); color: var(--ink-2); }
.gyo__cells { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.cell {
  position: relative; aspect-ratio: 1; min-height: 44px; display: grid; place-items: center; text-decoration: none;
  background: var(--paper); border: 2px solid #e4d3bf; border-radius: 12px 10px 13px 9px; transition: transform .18s var(--spring);
}
.cell__ch { font: 600 28px/1 var(--f-kana); color: var(--ink); }
.cell:active { transform: scale(.88) rotate(-3deg); }
.cell.is-tried { background: #fff; border-color: var(--c); }
.cell.is-hana { background: #fff; border-color: var(--c); }
.cell--gap { background: transparent; border: 2px dashed #f0e4d4; }
.cell__stamp { position: absolute; right: -6px; top: -7px; width: 24px; height: 24px; }
.stamp--hana { color: var(--c-red); }
.stamp--maru path, .stamp--retry path { fill: none; stroke-width: 3.6; stroke-linecap: round; }
.stamp--maru path { stroke: var(--c-orange); }
.stamp--retry path { stroke: var(--c-sky); }
.foot-note { margin-top: 18px; text-align: center; font: 700 14px/1.6 var(--f-kid); color: var(--ink-2); }

/* ---------- なぞる ---------- */
.tbar { flex: none; display: flex; align-items: center; gap: 10px; padding: calc(10px + env(safe-area-inset-top)) 14px 6px; }
.tbar__mid { flex: 1; min-width: 0; display: flex; align-items: center; justify-content: center; gap: 8px; }
.tbar__pic { width: 40px; height: 40px; border-radius: 12px; object-fit: cover; }
.tbar__name { display: flex; align-items: center; gap: 8px; }
.tbar__name .kl { font-size: 30px; line-height: 1; }
.tbar__meta { font: 700 14px/1.2 var(--f-kid); color: var(--ink-2); white-space: nowrap; }
.tbar__sp { width: 46px; flex: none; }
.trace { display: flex; flex-direction: column; align-items: stretch; justify-content: space-evenly; padding: 0 16px 10px; gap: 10px; }
.steps { list-style: none; margin: 0; padding: 0; display: flex; justify-content: center; gap: 8px; }
.steps__i { width: 34px; height: 34px; display: grid; place-items: center; border-radius: 50%; border: 2.5px solid #d8c8b5; background: #fff; transition: transform .3s var(--spring), background .2s; }
.steps__i span { font: 700 16px/1 var(--f-num); color: var(--ink-2); }
.steps__i.is-now { border-color: var(--go); transform: scale(1.12); }
.steps__i.is-now span { color: var(--go); }
.steps__i.is-done { background: var(--c); border-color: var(--c); }
.steps__i.is-done span { color: #fff; }
.scr--trace { --c: var(--c-red); }
.scr--trace .steps__i.is-done { background: var(--ink); border-color: var(--ink); }
.pad-wrap { flex: none; display: flex; align-items: center; justify-content: center; }
.pad-box { position: relative; }
.pad { display: block; touch-action: none; cursor: crosshair; border-radius: 22px; filter: drop-shadow(3px 4px 0 rgba(217, 139, 106, .45)); }
.coach-row { display: flex; align-items: center; gap: 12px; }
.coach__pal { flex: none; width: 64px; height: 64px; border-radius: 20px; object-fit: cover; border: 2.5px solid var(--c); background: #fff; }
.coach { flex: 1; min-width: 0; display: flex; align-items: center; min-height: 62px; padding: 10px 14px; background: #fff6cf; border: 2.5px solid var(--ink); border-radius: var(--hand-2); position: relative; }
.coach::before { content: ""; position: absolute; left: -10px; top: calc(50% - 8px); width: 16px; height: 16px; background: #fff6cf; border-left: 2.5px solid var(--ink); border-bottom: 2.5px solid var(--ink); transform: rotate(45deg); }
.coach__txt { font: 700 16px/1.5 var(--f-kid); position: relative; word-break: keep-all; }
.coach.is-warn { background: #ffe9e2; }
.coach.is-warn::before { background: #ffe9e2; }
.coach.is-bump { animation: bump .32s var(--spring); }
@keyframes bump { 0% { transform: scale(.96); } 100% { transform: none; } }
.tools { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; }
.tool { flex: none; width: 66px; min-height: 64px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; border: 2.5px solid var(--ink); border-radius: var(--hand-2); background: #fff; cursor: pointer; box-shadow: 2px 3px 0 var(--ink); transition: transform .12s, box-shadow .12s; }
.tool svg { width: 28px; height: 28px; }
.tool span { font: 700 13px/1.2 var(--f-kid); white-space: nowrap; }
.tool:active { transform: translate(2px, 3px); box-shadow: 0 0 0 var(--ink); }
.tool[data-act="demo"] svg { color: var(--c-orange); }
.crayons { flex: 1; display: flex; justify-content: center; align-items: flex-end; gap: 2px; height: 66px; }
.crayon { width: 30px; height: 64px; padding: 0; border: 0; background: none; cursor: pointer; display: flex; align-items: flex-end; justify-content: center; }
.crayon svg { width: 20px; height: 56px; transform: translateY(12px); transition: transform .28s var(--spring); }
.crayon[aria-checked="true"] svg { transform: translateY(0) rotate(-4deg); }
.crayon__tip, .crayon__body { fill: var(--k); }
.crayon__band { fill: #fff; opacity: .42; }
.crayon:active svg { transform: translateY(4px) scale(.95); }
.pn { display: flex; justify-content: space-between; }
.pn__a { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; min-width: 64px; padding: 0 10px; text-decoration: none; color: var(--ink-2); border-radius: 14px; }
.pn__a svg { width: 20px; height: 20px; }
.pn__a .kl { font-size: 24px; color: var(--ink); }
.pn__a:active { background: var(--paper-2); }

/* ---------- 結果・シート ---------- */
.scrim { position: absolute; inset: 0; z-index: 30; background: rgba(60, 40, 20, .28); opacity: 0; transition: opacity .25s; }
.scrim.is-open { opacity: 1; }
.scrim--clear { background: transparent; }
.sheet {
  position: absolute; left: 8px; right: 8px; bottom: calc(8px + env(safe-area-inset-bottom)); z-index: 31; max-height: 86%; overflow-y: auto; overscroll-behavior: contain;
  padding: 8px 18px 18px; background: var(--paper); border: 3px solid var(--ink); border-radius: 28px 24px 26px 22px / 24px 28px 22px 26px;
  transform: translateY(110%); transition: transform .34s var(--spring); box-shadow: 0 -6px 30px rgba(80, 50, 20, .18);
}
.sheet.is-open { transform: translateY(0); }
.sheet__grip { width: 44px; height: 5px; margin: 2px auto 10px; border-radius: 4px; background: #d8c8b5; }
.res__head { display: flex; align-items: center; gap: 12px; }
.res__img { width: 84px; height: 84px; flex: none; border-radius: 20px; animation: wob .8s var(--spring) both; }
.res__grade { font: 900 30px/1.2 var(--f-kid); color: var(--c-red); word-break: keep-all; }
.res--maru .res__grade { color: #b2520e; }
.res--retry .res__grade { color: #17679b; }
.res__sub { margin-top: 4px; font: 700 15px/1.5 var(--f-kid); color: var(--ink-2); }
.res__sub .kl { font-size: 20px; color: var(--ink); }
.res__gyo { margin-top: 6px; display: inline-block; padding: 4px 10px; background: var(--c-yellow); border-radius: 10px; font: 900 14px/1.3 var(--f-kid); color: var(--ink); }
.res__checks { list-style: none; margin: 14px 0 0; padding: 0; display: grid; gap: 6px; }
.res__checks li { display: flex; align-items: center; justify-content: space-between; min-height: 46px; padding: 4px 6px 4px 14px; background: #fff; border: 2px solid #eadbc8; border-radius: 14px; }
.res__l { font: 700 16px/1.3 var(--f-kid); }
.res__m { display: flex; align-items: center; gap: 6px; font: 700 14px/1 var(--f-kid); color: var(--ink-2); }
.res__m .stamp { width: 34px; height: 34px; }
.res__btns { display: flex; gap: 10px; margin-top: 16px; }
.res__btns .kbtn { flex: 1; padding: 0 10px; font-size: 17px; }

/* ---------- はなまる帳 ---------- */
.top--book { background: var(--paper); }
.scr--book .scr__body { padding: 4px 14px 24px; }
.nb { position: relative; display: flex; background: #fff; border: 3px solid var(--ink); border-radius: 8px 22px 22px 8px; box-shadow: 4px 5px 0 var(--c-red); }
.nb__rings { flex: none; width: 22px; display: flex; flex-direction: column; justify-content: space-around; align-items: center; padding: 14px 0; background: #f6ead8; border-right: 2px dashed #e0c9ad; border-radius: 6px 0 0 6px; }
.nb__rings i { width: 11px; height: 11px; border-radius: 50%; background: var(--paper); border: 2px solid #bfa587; }
.nb__page { flex: 1; min-width: 0; padding: 12px 10px 14px; background-image: linear-gradient(#f3e5d4 1.5px, transparent 1.5px); background-size: 100% 30px; background-color: #fff; border-radius: 0 20px 20px 0; }
.nb__stats { display: flex; gap: 14px; padding: 2px 4px 10px; }
.nb__stats p { display: flex; align-items: baseline; gap: 4px; padding: 4px 10px; background: #fff; border: 2px solid #eadbc8; border-radius: 12px; }
.nb__k { font: 700 13px/1.2 var(--f-kid); color: var(--ink-2); white-space: nowrap; }
.nb__stats b { font-size: 22px; color: var(--c-red); }
.nb__u { font: 700 13px/1 var(--f-kid); }
.nb__grid { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; }
.nb__cell { position: relative; aspect-ratio: 1; padding: 3px; border: 2px solid #ecdcc9; border-radius: 10px; background: #fff; cursor: pointer; transition: transform .18s var(--spring); }
.nb__cell:active { transform: scale(.9); }
.nb__cell.is-hana { border-color: #f1b7ae; }
.nb__cell--gap { border: 0; background: transparent; }
.nb__cell .w { width: 100%; height: 100%; display: block; }
.nb__stamp { position: absolute; right: -5px; bottom: -6px; width: 26px; height: 26px; }
.nb__hint { margin: 12px auto 0; width: fit-content; padding: 2px 10px; background: #fff; text-align: center; font: 700 14px/1.5 var(--f-kid); color: var(--ink-2); }
.w__grid { fill: none; stroke: #f2d8c9; stroke-width: 1.2; stroke-dasharray: 3 3.5; }
.w__model { fill: none; stroke: #ece2d6; stroke-width: 8; stroke-linecap: round; stroke-linejoin: round; }
.w__model--dash { stroke: #d9c9b6; stroke-width: 2.6; stroke-dasharray: 3.5 4.5; }
.w__ink path { fill: none; stroke-width: 7; stroke-linecap: round; stroke-linejoin: round; opacity: .92; }
.bk__head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.bk__title { display: flex; align-items: center; gap: 12px; font: 900 20px/1.3 var(--f-kid); }
.bk__title .kl { font-size: 40px; line-height: 1; }
.bk__stamp { width: 52px; height: 52px; flex: none; }
.bk__paper { margin: 10px auto 0; width: min(260px, 72vw); aspect-ratio: 1; background: #fff; border: 2.5px solid #d98b6a; border-radius: 20px; padding: 12px; }
.bk__paper .w { width: 100%; height: 100%; display: block; }
.bk__meta { display: flex; justify-content: center; gap: 16px; margin-top: 12px; font: 700 15px/1.4 var(--f-kid); color: var(--ink-2); flex-wrap: wrap; }
.bk__meta b { font-size: 18px; color: var(--ink); }
.empty { display: flex; flex-direction: column; align-items: center; text-align: center; padding: 18px 24px 32px; gap: 10px; }
.empty img { width: 220px; height: 220px; }
.empty__title { font: 900 21px/1.4 var(--f-kid); word-break: keep-all; }
.empty__text { font: 700 15px/1.75 var(--f-kid); color: var(--ink-2); max-width: 300px; }
.empty .kbtn { margin-top: 8px; }

/* ---------- おうちのかたへ（大人向け） ---------- */
.adult { font-family: var(--f-adult); }
.scr.adult { background: #f6f2ea; }
.ptop { flex: none; display: flex; align-items: center; gap: 10px; padding: calc(14px + env(safe-area-inset-top)) 18px 10px; background: #f6f2ea; border-bottom: 1px solid #e4dccd; }
.ptop__title { font: 700 20px/1.3 var(--f-adult); letter-spacing: .02em; }
.ptop--sub { justify-content: space-between; }
.ptop--sub .ptop__title { font-size: 17px; }
.roundbtn--adult { border-width: 1.5px; box-shadow: none; border-color: #cfc5b5; width: 44px; height: 44px; border-radius: 50%; }
.roundbtn--adult svg { width: 22px; height: 22px; }
.scr.adult .scr__body { padding: 14px 16px 28px; display: flex; flex-direction: column; gap: 12px; }
.phero { margin: 0; background: #fff; border-radius: 16px; overflow: hidden; border: 1px solid #e6ded0; }
.phero img { width: 100%; height: 150px; object-fit: cover; object-position: 60% 50%; }
.phero figcaption { padding: 10px 14px 12px; font: 400 14px/1.6 var(--f-adult); color: #3c3640; }
.pcard { background: #fff; border: 1px solid #e6ded0; border-radius: 16px; padding: 16px; }
.pcard__h { font: 700 16px/1.4 var(--f-adult); margin-bottom: 10px; }
.pcard__p { font: 400 14px/1.75 var(--f-adult); color: #3c3640; }
.pcard__p b { font-weight: 700; }
.pcard__p--sub { margin-top: 10px; color: #5a5160; }
.pstats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; padding: 14px 10px; }
.pstats > div { text-align: center; }
.pstats__k { font: 400 12px/1.4 var(--f-adult); color: #5a5160; white-space: nowrap; }
.pstats__v { margin-top: 4px; display: flex; justify-content: center; align-items: baseline; gap: 2px; }
.pstats__v b { font-size: 28px; color: #2f2a33; }
.pstats__v span { font: 400 12px/1 var(--f-adult); color: #5a5160; white-space: nowrap; }
.pc { width: 100%; height: auto; display: block; }
.pc__bar { fill: #e8ddcd; }
.pc__bar.is-today { fill: var(--c-red); }
.pc__v { font: 600 12px var(--f-num); fill: #3c3640; text-anchor: middle; }
.pc__d { font: 400 12px var(--f-adult); fill: #5a5160; text-anchor: middle; }
.pgs { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.pg { display: grid; grid-template-columns: 44px 1fr 36px; align-items: center; gap: 10px; }
.pg__n { font: 700 14px/1 var(--f-adult); }
.pg__bar { height: 12px; display: flex; background: #f1ebe1; border-radius: 6px; overflow: hidden; }
.pg__bar i { display: block; height: 100%; background: var(--c); }
.pg__bar .pg__tried { background: var(--c); opacity: .3; }
.pg__v { font: 600 13px/1 var(--f-num); color: #3c3640; text-align: right; }
.pcard__legend { display: flex; gap: 14px; margin-top: 12px; font: 400 12px/1.4 var(--f-adult); color: #5a5160; }
.lg::before { content: ""; display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; background: #6f6676; vertical-align: -1px; }
.lg--tried::before { opacity: .3; }
.phs { list-style: none; margin: 0; padding: 0; }
.ph { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-top: 1px solid #efe8dc; }
.ph:first-child { border-top: 0; padding-top: 2px; }
.ph__ch { flex: none; width: 46px; height: 46px; display: grid; place-items: center; font-size: 30px; background: #fbf6ee; border-radius: 12px; }
.ph__txt { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.ph__e { font: 700 14px/1.5 var(--f-adult); }
.ph__g { font: 400 13px/1.5 var(--f-adult); color: #5a5160; }
.ph__go { flex: none; min-height: 40px; display: inline-flex; align-items: center; padding: 0 12px; border-radius: 20px; background: #f1ebe1; font: 700 13px/1 var(--f-adult); text-decoration: none; color: #2f2a33; white-space: nowrap; }
.ph__go:active { background: #e4dccd; }
.ph--none { font: 400 14px/1.7 var(--f-adult); color: #3c3640; }
.pset { padding-bottom: 14px; border-bottom: 1px solid #efe8dc; }
.pset__k { font: 700 14px/1.4 var(--f-adult); margin-bottom: 8px; }
.pset__note { margin-top: 8px; font: 400 13px/1.6 var(--f-adult); color: #5a5160; }
.seg { display: grid; grid-template-columns: repeat(3, 1fr); padding: 3px; background: #f1ebe1; border-radius: 12px; }
.seg__b { min-height: 44px; border: 0; border-radius: 9px; background: transparent; font: 700 14px/1 var(--f-adult); color: #3c3640; cursor: pointer; transition: background .2s; }
.seg__b[aria-checked="true"] { background: #fff; color: #2f2a33; box-shadow: 0 1px 3px rgba(60, 40, 20, .18); }
.psw { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 64px; padding: 10px 0; border-bottom: 1px solid #efe8dc; cursor: pointer; }
.psw:last-child { border-bottom: 0; padding-bottom: 0; }
.psw__t { display: flex; flex-direction: column; gap: 2px; }
.psw__k { font: 700 14px/1.4 var(--f-adult); }
.psw__d { font: 400 13px/1.5 var(--f-adult); color: #5a5160; }
.sw { appearance: none; -webkit-appearance: none; flex: none; position: relative; width: 52px; height: 32px; margin: 0; border-radius: 16px; background: #d6ccbd; cursor: pointer; transition: background .2s; }
.sw::after { content: ""; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0, 0, 0, .25); transition: transform .25s var(--spring); }
.sw:checked { background: var(--go); }
.sw:checked::after { transform: translateX(20px); }
.sw:focus-visible, .seg__b:focus-visible { outline: 2px solid var(--c-sky); outline-offset: 2px; }
.plinks { padding: 4px 16px; }
.plink { width: 100%; display: flex; align-items: center; justify-content: space-between; min-height: 52px; padding: 0; border: 0; background: none; text-decoration: none; color: #2f2a33; font: 700 15px/1.3 var(--f-adult); cursor: pointer; }
.plink + .plink { border-top: 1px solid #efe8dc; }
.plink svg { width: 20px; height: 20px; color: #6f6676; }
.plink--danger { color: #b3261e; }
.plink--danger svg { color: #b3261e; }
.pnote { font: 400 13px/1.75 var(--f-adult); color: #5a5160; padding: 0 4px; }
.conf { padding: 4px 2px 2px; }
.conf__h { font: 700 18px/1.4 var(--f-adult); }
.conf__p { margin-top: 8px; font: 400 14px/1.75 var(--f-adult); color: #3c3640; }
.conf__btns { display: grid; gap: 8px; margin-top: 16px; }
.abtn { display: flex; align-items: center; justify-content: center; min-height: 50px; padding: 0 16px; border: 1px solid #cfc5b5; border-radius: 14px; background: #fff; font: 700 15px/1.3 var(--f-adult); color: #2f2a33; text-decoration: none; cursor: pointer; transition: transform .12s; }
.abtn:active { transform: scale(.97); }
.abtn--danger { background: #b3261e; border-color: #b3261e; color: #fff; }
.abtn--cta { background: #2f2a33; border-color: #2f2a33; color: #fff; }
.gate { text-align: center; padding: 6px 4px 4px; }
.gate__ic { width: 34px; height: 34px; color: #5a5160; margin: 0 auto 6px; display: block; }
.gate__btn { position: relative; overflow: hidden; width: 100%; min-height: 56px; margin-top: 16px; border: 1px solid #2f2a33; border-radius: 16px; background: #fff; cursor: pointer; touch-action: none; user-select: none; -webkit-user-select: none; }
.gate__fill { position: absolute; inset: 0; background: #e3ecf5; transform: scaleX(0); transform-origin: left; }
.gate__t { position: relative; font: 700 15px/1 var(--f-adult); color: #2f2a33; }
.about__id { display: flex; align-items: center; gap: 14px; padding: 6px 2px; }
.about__id img { width: 72px; height: 72px; border-radius: 18px; border: 1px solid #e6ded0; }
.about__name { font: 700 18px/1.4 var(--f-adult); }
.about__ver { font: 400 13px/1.5 var(--f-adult); color: #5a5160; }
.about__tech { margin: 0; padding-left: 1.2em; font: 400 14px/1.9 var(--f-adult); color: #3c3640; }

/* ---------- トースト ---------- */
.toast { position: absolute; left: 50%; bottom: calc(var(--dock-h) + 16px + env(safe-area-inset-bottom)); z-index: 60; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; padding: 12px 18px; max-width: calc(100% - 32px); width: max-content; background: var(--ink); color: #fff; border-radius: 16px; font: 700 15px/1.4 var(--f-kid); transition: opacity .2s, transform .3s var(--spring); }
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

@media (max-height: 700px) {
  .tool { min-height: 56px; }
  .coach { min-height: 50px; padding: 8px 12px; }
  .coach__txt { font-size: 15px; }
  .trace { gap: 8px; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
.scr.adult .scr__body > * { flex-shrink: 0; }
.onboard__text, .empty__text, .res__sub, .foot-note, .nb__hint { word-break: keep-all; }
