/* en-where（英語 場所・道あんない・町）。正かい＝みどり、まちがい＝赤。役わりの 色：だれが＝青・する＝オレンジ・なにを＝みどり・どこ＝むらさき */
.ew { --ew-ok: #10b981; --ew-okd: #047857; --ew-ng: #ef4444; --ew-ngd: #b91c1c; --ew-o: #f59e0b; --ew-b: #1e3a8a; font-size: 1.05rem; }
.ew [hidden] { display: none !important; }
.ew-q { background: linear-gradient(180deg, #eef6ff, #f8fbff); border: 2px solid #93c5fd; border-radius: 16px; padding: 8px 14px; margin-bottom: 10px; font-weight: 700; line-height: 1.7; }
.ew rt { font-size: .5em; font-weight: 500; }
.ew-b { font: 700 1rem/1.3 inherit; font-family: inherit; border-radius: 999px; border: 2px solid #cbd5e1; background: #fff; color: #1f2937; padding: 8px 16px; min-height: 44px; cursor: pointer;
  box-shadow: 0 3px 0 #e2e8f0; touch-action: manipulation; display: inline-flex; align-items: center; gap: 6px; }
.ew-b:active { transform: translateY(2px); box-shadow: none; }
.ew-b:disabled { opacity: .45; cursor: default; }
.ew-play { border-color: #2563eb; color: #2563eb; box-shadow: 0 3px 0 #bfdbfe; }
.ew-slow { border-color: #0f8a72; color: #0f8a72; box-shadow: 0 3px 0 #a7f3d0; }
.ew-b.small { padding: 4px 10px; min-height: 40px; }
.ew-sub { border-color: #cbd5e1; color: #475569; font-size: .92rem; }
.ew-sub[aria-pressed="true"] { border-color: #7c3aed; color: #6d28d9; background: #f5f3ff; box-shadow: 0 3px 0 #ddd6fe; }
.ew-next { border-color: var(--ew-ok); background: linear-gradient(180deg, #34d399, #10b981); color: #fff; box-shadow: 0 3px 0 var(--ew-okd); }
.ew-acts, .ew-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; justify-content: center; margin: 8px 0; }
.ew-acts:empty { display: none; }
.ew-fb { min-height: 1.6em; margin: 8px 0; padding: 6px 10px; border-radius: 12px; font-weight: 700; line-height: 1.7; display: flex; gap: 6px; align-items: flex-start; }
.ew-fb.ok { background: #ecfdf5; color: var(--ew-okd); }
.ew-fb.ng { background: #fef2f2; color: var(--ew-ngd); }
.ew-mi { flex: none; width: 24px; height: 24px; margin-top: 3px; } .ew-mi svg { width: 100%; height: 100%; display: block; }
.ew-svg { display: block; width: 100%; max-width: 420px; height: auto; margin: 0 auto; border-radius: 16px; box-shadow: 0 6px 18px rgba(15, 23, 42, .08); }
.ew-note { color: #64748b; font-size: .85rem; }
/* 文の 色 */
.c-who { color: #2563eb; } .c-do { color: #ea580c; } .c-what { color: #059669; } .c-wh { color: #7c3aed; }
.c-do.ng { text-decoration: underline wavy #ef4444 2px; text-underline-offset: 4px; }
.ew-sent { display: flex; align-items: center; justify-content: center; gap: 8px; flex-wrap: wrap; margin: 10px 0 4px; padding: 10px 12px; border-radius: 16px; background: #fff; border: 2px solid #e2e8f0; }
.ew-st { font-family: "Andika", "Segoe UI", Arial, sans-serif; font-weight: 700; font-size: 1.35rem; color: var(--ew-b); text-align: center; border-radius: 10px; padding: 0 6px; }
.ew-st.saying { background: #fef3c7; }
.ew-sb { display: inline-flex; gap: 6px; }
.ew-hid { font-family: inherit; font-size: 1rem; color: #64748b; }
.ew-pp { background: #ede9fe; border-radius: 8px; padding: 0 6px; }
/* place */
.ew-zone { cursor: pointer; outline: none; }
.ew-zc { fill: rgba(255, 255, 255, .55); stroke: #7c3aed; stroke-width: 2.5; stroke-dasharray: 6 4; transition: fill .15s; }
.ew-zt { font: 800 17px sans-serif; fill: #6d28d9; pointer-events: none; }
.ew-zone:hover .ew-zc, .ew-zone:focus-visible .ew-zc { fill: #f5f3ff; }
.ew-zone.on .ew-zc { fill: rgba(255, 255, 255, 0); stroke: #f59e0b; stroke-dasharray: none; stroke-width: 3; }
.ew-zone.on .ew-zt { opacity: 0; }
.ew.quiz .ew-zt { opacity: .35; }
.ew-jp { max-width: 340px; margin: 6px auto 0; }
.ew-jp:empty { display: none; }
.ew-row { display: grid; grid-template-columns: 56px 1fr 1fr; gap: 6px; align-items: center; }
.ew-tag { font-size: .8rem; font-weight: 800; color: #64748b; }
.ew-ch { text-align: center; padding: 6px 4px; border-radius: 12px; font-weight: 800; border: 2px solid; }
.ew-row.en .ew-ch { font-family: "Andika", "Segoe UI", Arial, sans-serif; font-size: 1.15rem; }
.ew-ch.a { background: #f5f3ff; border-color: #a78bfa; color: #6d28d9; }
.ew-ch.b { background: #fff7ed; border-color: #fdba74; color: #9a3412; }
.ew-x { display: block; width: calc(100% - 62px); margin-left: 62px; height: 28px; }
.ew-x path { stroke-width: 3; fill: none; stroke-linecap: round; }
.ew-x .xa { stroke: #a78bfa; } .ew-x .xb { stroke: #fdba74; }
.ew-jp .ew-note { margin: 6px 0 0; font-weight: 700; color: #475569; font-size: .92rem; }
/* route */
.ew-map { touch-action: manipulation; }
.ew-road { stroke: #94a3b8; stroke-width: 22; stroke-linecap: round; }
.ew-lane { stroke: #f8fafc; stroke-width: 2; stroke-dasharray: 7 7; }
.ew-rot { transition: transform .6s; }
.ew-up { transition: transform .6s; transform-box: fill-box; transform-origin: center; }
@media (prefers-reduced-motion: reduce) { .ew-rot, .ew-up { transition: none; } }
.ew-lbl { fill: rgba(255, 255, 255, .92); stroke: #cbd5e1; }
.ew-lt { font: 700 10.5px "Andika", sans-serif; fill: #1e3a8a; }
.ew-bld { cursor: pointer; }
.ew-bld.goal rect:first-child { stroke: #f59e0b; stroke-width: 4; }
.ew-bld.ok rect:first-child { stroke: var(--ew-ok); stroke-width: 5; fill: #ecfdf5; }
.ew-bld.ng rect:first-child { stroke: var(--ew-ng); stroke-width: 5; fill: #fef2f2; }
.ew.listen .ew-bld.pick rect:first-child { stroke: #93c5fd; stroke-width: 3; }
.ew-tr { stroke: #f59e0b; stroke-width: 6; stroke-linecap: round; opacity: .8; }
.ew-cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; margin: 10px 0 4px; }
.ew-card { flex-direction: column; justify-content: center; border-radius: 16px; padding: 8px 4px; min-height: 76px; font-family: "Andika", "Segoe UI", Arial, sans-serif; font-size: 1rem; text-align: center; line-height: 1.15; }
.ew-card svg { width: 30px; height: 30px; }
.ew-card.c-go { border-color: #60a5fa; color: #1d4ed8; background: linear-gradient(180deg, #fff, #eff6ff); box-shadow: 0 3px 0 #bfdbfe; }
.ew-card.c-left { border-color: #f472b6; color: #be185d; background: linear-gradient(180deg, #fff, #fdf2f8); box-shadow: 0 3px 0 #fbcfe8; }
.ew-card.c-right { border-color: #fb923c; color: #c2410c; background: linear-gradient(180deg, #fff, #fff7ed); box-shadow: 0 3px 0 #fed7aa; }
.ew-log { display: flex; flex-wrap: wrap; gap: 4px 6px; list-style: none; padding: 0; margin: 4px 0; counter-reset: s; }
.ew-log li { counter-increment: s; font-family: "Andika", "Segoe UI", Arial, sans-serif; font-weight: 700; font-size: .92rem; background: #f1f5f9; border-radius: 999px; padding: 2px 10px 2px 4px; color: #334155; }
.ew-log li::before { content: counter(s); display: inline-block; min-width: 18px; height: 18px; line-height: 18px; text-align: center; border-radius: 50%; background: #64748b; color: #fff; font-size: .75rem; margin-right: 4px; font-family: sans-serif; }
/* town */
.ew-town { position: relative; border-radius: 18px; padding: 12px 10px 14px; background: linear-gradient(180deg, #e0f2fe 0, #f0fdf4 60%, #dcfce7 100%); border: 2px solid #bbf7d0; overflow: hidden; }
.ew-tbg { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 40px; }
.ew-slots { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.ew-slot { border-radius: 14px; min-height: 96px; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 4px; }
.ew-slot.empty { border: 2px dashed #86efac; background: rgba(255, 255, 255, .4); }
.ew-slot.full { border: 2px solid #fff; background: #fff; box-shadow: 0 4px 10px rgba(15, 23, 42, .1); cursor: pointer; font: inherit; animation: ew-pop .35s; }
.ew-slot img, .ew-pc img { width: 100%; max-width: 76px; aspect-ratio: 1; object-fit: contain; }
.ew-slot span, .ew-pc span { font-family: "Andika", "Segoe UI", Arial, sans-serif; font-weight: 700; color: var(--ew-b); font-size: .88rem; line-height: 1.1; text-align: center; overflow-wrap: anywhere; }
@keyframes ew-pop { 0% { transform: scale(.6); opacity: 0; } 70% { transform: scale(1.06); } }
@media (prefers-reduced-motion: reduce) { .ew-slot.full { animation: none; } }
.ew-shelf { margin-top: 8px; }
.ew-sub { font-weight: 700; color: #475569; margin: 4px 0; font-size: .92rem; }
p.ew-sub { border: 0; }
.ew-shrow { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 6px; }
.ew-pc { flex-direction: column; border-radius: 14px; padding: 4px; min-height: 84px; gap: 2px; }
.ew-big { text-align: center; margin: 10px 0 0; padding: 10px; border-radius: 16px; border: 2px solid #bbf7d0; background: #f0fdf4; }
.ew-big.no { border-color: #fecaca; background: #fff7f7; }
.ew-big .en-s { font-size: 1.3rem; }
.ew-jp1 { margin: 4px 0 0; font-weight: 700; color: #475569; }
.ew-qs { text-align: center; margin: 8px 0; min-height: 2em; }
.ew-qs .en-s { font-size: 1.3rem; }
.ew-ans { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin: 6px 0; }
.ew-tf { min-width: 120px; justify-content: center; font-size: 1.1rem; }
.ew-tf.t { border-color: #10b981; color: #047857; } .ew-tf.f { border-color: #f97316; color: #c2410c; }
.ew-tf.ok { background: #ecfdf5; box-shadow: 0 0 0 4px rgba(16, 185, 129, .25); } .ew-tf.ng { background: #fef2f2; border-color: var(--ew-ng); }
@media (max-width: 420px) { .ew-st { font-size: 1.15rem; } .ew-shrow { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.ew-ball, .ew-zin, .ew-zout { pointer-events: none; }
