/* 聞こえにくさの体験（じぶんの聞こえプロジェクトの色にそろえる） */
:root {
  --primary: #3ABCB1; --primary-dark: #2da99e; --primary-light: #E8F7F6;
  --ink: #1F2D3A; --muted: #566676; --line: #D3DCE3; --paper: #F4F7F8; --panel: #FFFFFF; --chip: #E9EEF2;
  --right: #D93025; --left: #1A63D8; --aided: #1F2D3A;
  --radius: 12px;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: "BIZ UDPゴシック", "BIZ UDPGothic", "Yu Gothic UI", "Meiryo", sans-serif;
  font-size: 16px; line-height: 1.75;
}
body.big { font-size: 20px; }
button, input { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; }
ruby rt { font-size: 0.55em; color: var(--muted); }

.top {
  position: sticky; top: 0; z-index: 10; background: var(--paper); border-bottom: 1px solid var(--line);
  display: flex; flex-wrap: wrap; gap: .5rem 1rem; align-items: center; justify-content: space-between;
  padding: .6rem 1rem;
}
.back { font-size: .85rem; font-weight: 700; color: var(--primary-dark); text-decoration: none; }
.back:hover { text-decoration: underline; }
.top h1 { margin: 0; font-size: 1.4rem; line-height: 1.5; }
.lead { margin: 0; font-size: .85rem; color: var(--muted); max-width: 46em; }
.modes { display: flex; gap: 4px; background: var(--chip); border-radius: 12px; padding: 4px; }
.modes button {
  border: none; background: transparent; border-radius: 9px; min-height: 44px; padding: .2rem .9rem;
  font-weight: 700; color: var(--muted);
}
.modes button[aria-pressed="true"] { background: var(--panel); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.15); }

.grid {
  display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 1rem; align-items: start;
  padding: 1rem; max-width: 1400px; margin: 0 auto;
}
.left { display: flex; flex-direction: column; gap: .8rem; min-width: 0; }

.settings summary { font-weight: 700; cursor: pointer; }
.toggles { display: flex; flex-wrap: wrap; gap: .1rem 1.2rem; margin: .3rem 0; }
.toggles label { display: flex; align-items: center; gap: .4rem; min-height: 40px; }
.toggles input, .check input { width: 22px; height: 22px; accent-color: var(--primary); }
.check { display: flex; align-items: center; gap: .45rem; min-height: 40px; font-weight: 700; }
.model-note { font-size: .85rem; color: var(--muted); border-left: 3px solid var(--line); padding-left: .6rem; margin: 0; }

/* 記号 */

/* ---------- 右のパネル ---------- */
.panel {
  position: sticky; top: 5.5rem; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 1rem 1.1rem; display: flex; flex-direction: column; gap: .7rem; max-height: calc(100vh - 6.5rem); overflow: auto;
}
.panel h2 { margin: 0; font-size: 1.25rem; line-height: 1.6; }
.panel p { margin: 0; }
.hint { font-size: .88rem; color: var(--muted); margin: 0; }
.err { color: #b3261e; font-weight: 700; }
.btn { border: 1px solid var(--line); background: var(--panel); border-radius: 10px; padding: .45rem .9rem; min-height: 44px; }
.btn.small { min-height: 36px; padding: .2rem .8rem; font-size: .88rem; }
.btn.primary { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 700; }
.btn:disabled { opacity: .45; cursor: default; }
.btnrow { display: flex; gap: .5rem; }
.btnrow .btn { flex: 1; }
.steps { display: flex; gap: .35rem; flex-wrap: wrap; }
.sdot { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--line); background: var(--panel); font-weight: 700; }
.sdot[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }
.step-no { font-size: .85rem; color: var(--primary-dark); font-weight: 700; }
.note { font-size: .9rem; background: var(--primary-light); border-radius: 10px; padding: .6rem .8rem; }
.privacy { font-size: .85rem; color: var(--muted); }

.part-btns { display: flex; flex-wrap: wrap; gap: .35rem; }
.pbtn { border: 2px solid var(--line); background: var(--panel); border-radius: 10px; min-height: 44px; padding: .1rem .7rem; }
.pbtn[aria-pressed="true"] { background: #FFC83D; border-color: #E0A800; font-weight: 700; }
.detail { display: flex; flex-direction: column; gap: .5rem; }
.short { font-weight: 700; color: var(--primary-dark); }
.fact { display: grid; grid-template-columns: auto 1fr; gap: .1rem .8rem; margin: 0; }
.fact dt { font-weight: 700; color: var(--muted); }
.fact dd { margin: 0; }
.loss-dl { margin: 0; }
.loss-dl dt { font-size: .82rem; font-weight: 700; color: var(--muted); margin-top: .4rem; }
.loss-dl dd { margin: 0 0 .2rem; }



.loss-tabs { display: flex; gap: .35rem; }
.lbtn { flex: 1; min-height: 46px; border-radius: 10px; border: 2px solid var(--line); background: var(--panel); font-weight: 700; }
.lbtn[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #fff; }
.choices { display: flex; flex-direction: column; gap: .4rem; }
.choice { text-align: left; border: 2px solid var(--line); background: var(--panel); border-radius: 10px; min-height: 48px; padding: .3rem .8rem; }
.choice:not(:disabled):hover { border-color: var(--primary); }
.choice.right { background: #DFF3E8; border-color: #0B7A5E; font-weight: 700; }
.choice.wrong { background: #FBE3E1; border-color: #b3261e; }
.choice:disabled { cursor: default; }
.fb { font-weight: 800; font-size: 1.05rem; }
.fb.ok { color: #0B7A5E; } .fb.ng { color: #b3261e; }
.explain { background: #F4F7F8; border-radius: 10px; padding: .6rem .8rem; }

@media (max-width: 1050px) {
  .grid { grid-template-columns: 1fr; }
  .panel { position: static; max-height: none; }
}
@media (max-width: 560px) {
  .grid { padding: .6rem; }
  .top { padding: .5rem .7rem; }
  .top h1 { font-size: 1.2rem; }
  .modes { width: 100%; }
  .modes button { flex: 1; padding: .2rem .3rem; font-size: .85rem; }
  .tools { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- 聞こえにくさの体験 ---------- */
.safety { margin: 0; background: #FFF7E0; border-radius: 12px; padding: .6rem .9rem; font-size: .95rem; }
.card { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: .7rem .9rem; display: flex; flex-direction: column; gap: .5rem; }
.card-t { margin: .2rem 0 0; font-size: 1.05rem; }
.sims { display: grid; grid-template-columns: repeat(3, 1fr); gap: .45rem; }
.simbtn { display: flex; flex-direction: column; gap: .15rem; text-align: left; border: 2px solid var(--line); background: var(--panel); border-radius: 12px; padding: .45rem .6rem; min-height: 64px; }
.simbtn b { font-size: .95rem; line-height: 1.5; }
.simbtn span { font-size: .8rem; color: var(--muted); line-height: 1.5; }
.simbtn.plain { background: #F4F7F8; }
.simbtn[aria-pressed="true"] { border-color: #D9822B; background: #FFF1DE; }
.loss-chart { display: block; width: 100%; height: auto; }
.loss-chart text { font-family: "BIZ UDPゴシック", "BIZ UDPGothic", "Yu Gothic UI", "Meiryo", sans-serif; }
.loss-chart .c-title { font-size: 14px; font-weight: 800; fill: #1F2D3A; }
.loss-chart .c-tick { font-size: 12px; fill: #3d4a58; }
.loss-chart .c-sub { font-size: 12px; font-weight: 700; fill: #566676; }
.loss-chart .c-lab { font-size: 14px; font-weight: 800; fill: #3d4a58; }
.loss-chart .c-lab.r { fill: #D93025; } .loss-chart .c-lab.l { fill: #1A63D8; }
.toggles2 { display: flex; flex-wrap: wrap; gap: .2rem 1.2rem; align-items: center; }
.voice { display: flex; align-items: center; gap: .35rem; font-weight: 700; }
.pill { border: 2px solid var(--line); background: var(--panel); border-radius: 999px; min-height: 40px; padding: .1rem .8rem; }
.pill[aria-pressed="true"] { background: var(--primary); border-color: var(--primary); color: #fff; font-weight: 700; }
.slist { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: .35rem; }
.slist li, .recrow { position: relative; display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .3rem .6rem; border: 1px solid var(--line); border-radius: 10px; padding: .35rem .5rem .45rem .7rem; overflow: hidden; }
.recrow { justify-content: flex-start; border: none; padding: 0; }
.stext { flex: 1 1 14em; }
.pb { display: flex; gap: .35rem; }
.playb { min-width: 6.2em; font-weight: 700; }
.playb.sim { background: #FFF1DE; border-color: #D9822B; }
.playb[aria-pressed="true"] { background: #FFC83D; border-color: #E0A800; }
.bar { position: absolute; left: 0; bottom: 0; height: 4px; width: 0; background: #D9822B; }
.rec.on { background: #FBE3E1; border-color: #b3261e; color: #b3261e; font-weight: 700; }
.privacy { font-size: .85rem; color: var(--muted); margin: 0; }
.chsim { margin: 0; font-weight: 700; color: #B36B00; }
.choices { display: flex; flex-direction: row; gap: .4rem; }
.choices .choice { flex: 1; text-align: center; font-size: 1.15rem; font-weight: 800; }
.fb { margin: 0; font-weight: 800; }
.box { border-radius: 12px; padding: .55rem .8rem; }
.box ul, .box ol { margin: .2rem 0 0; padding-left: 1.2rem; }
.box li { margin: .15rem 0; }
.box-t { font-weight: 800; }
.notice { background: #EEF5FB; } .help { background: #E8F7F1; } .reflect { background: #F6F1FC; }
.btn.link { display: inline-block; text-decoration: none; color: var(--primary-dark); font-weight: 700; align-self: flex-start; }
.disclaimer { font-size: .88rem; color: var(--muted); border-left: 3px solid var(--line); padding-left: .6rem; }
@media (max-width: 900px) { .sims { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .choices { flex-direction: column; } }
.slist li.en { border-color: #9BC9E8; background: #F5FAFE; }
.slist li.en .stext { font-family: "Segoe UI", "BIZ UDPゴシック", sans-serif; font-weight: 600; }
.trans { display: block; font-weight: 400; font-size: .88rem; color: var(--muted); font-family: "BIZ UDPゴシック", "BIZ UDPGothic", "Yu Gothic UI", "Meiryo", sans-serif; }
.shint { display: block; font-weight: 400; font-size: .85rem; color: #1F5F8B; margin-top: .15rem; font-family: "BIZ UDPゴシック", "BIZ UDPGothic", "Yu Gothic UI", "Meiryo", sans-serif; }
