/* 麻雀CHU！ — dopagaku.com のブランド配色を踏襲 */
:root {
  --ink: #120a2e;
  --night: #1b1150;
  --paper: #fff6fb;
  --card: #ffffff;
  --pink: #ff2e88;
  --yellow: #ffe600;
  --cyan: #22e6ff;
  --lime: #c6ff3d;
  --blue: #2f45ff;
  --mat: #17614a;
  --mat-dark: #0f4a38;
  --muted: #6b6488;
  --line: #eadff0;
  --ok: #14875a;
  --ng: #d3262b;
  --display: "Dela Gothic One", "Hiragino Sans", "Yu Gothic", sans-serif;
  --body: "M PLUS Rounded 1c", "Hiragino Maru Gothic ProN", "Hiragino Sans", sans-serif;
  --dot: "DotGothic16", "Osaka-Mono", monospace;
  --radius: 14px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: var(--body); font-weight: 500; line-height: 1.7;
}
button { font: inherit; color: inherit; }
a { color: var(--blue); }

/* ---------- ヘッダー ---------- */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: var(--night); color: #fff;
  box-shadow: 0 2px 0 var(--pink);
}
.site-header .inner { max-width: 1040px; margin: 0 auto; padding: 10px 16px 0; }
.brand { display: flex; align-items: baseline; gap: 10px; text-decoration: none; color: #fff; }
.brand b { font-family: var(--display); font-weight: 400; font-size: 24px; letter-spacing: .02em; }
.brand b em { font-style: normal; color: var(--yellow); }
.brand small { font-family: var(--dot); font-size: 12px; color: var(--cyan); }
.nav { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; margin-top: 6px; }
.nav::-webkit-scrollbar { display: none; }
.nav a {
  flex: none; padding: 8px 12px 10px; color: #cfc8ff; text-decoration: none; font-weight: 800; font-size: 14px;
  border-bottom: 3px solid transparent;
}
.nav a.active { color: #fff; border-bottom-color: var(--yellow); }

main { max-width: 1040px; margin: 0 auto; padding: 20px 16px 80px; }
h1, h2, h3 { font-family: var(--display); font-weight: 400; line-height: 1.35; }
h1 { font-size: 28px; margin: 8px 0 6px; }
h2 { font-size: 21px; margin: 32px 0 10px; }
h3 { font-size: 17px; margin: 0 0 4px; }
.lead { color: var(--muted); margin: 0 0 18px; }

/* ---------- 牌 ---------- */
.tile { display: inline-block; vertical-align: bottom; line-height: 0; flex: none; }
.tile svg { width: 100%; height: 100%; display: block; }
.tile-xs { width: 22px; height: 29px; }
.tile-sm { width: 28px; height: 37px; }
.tile-md { width: 36px; height: 48px; }
.tile-lg { width: 46px; height: 61px; }
.tile-rot { transform: rotate(-90deg); margin: 0 6px; }
.tile-sm.tile-rot { margin: 0 4px; }
.tile-xs.tile-rot { margin: 0 3px; }
.tile.is-win svg { filter: drop-shadow(0 0 0 var(--yellow)) drop-shadow(0 0 3px var(--yellow)); }
.tile-row { display: inline-flex; gap: 1px; align-items: flex-end; }
.hand { display: inline-flex; flex-wrap: wrap; align-items: flex-end; gap: 6px 10px; }
.melds { display: inline-flex; gap: 8px; }
.win-slot { margin-left: 4px; }

.mat {
  background: radial-gradient(ellipse at 50% 30%, var(--mat) 0%, var(--mat-dark) 100%);
  border-radius: var(--radius); padding: 14px; overflow-x: auto;
}
.mat .caption { color: #d7f5e8; font-size: 12px; margin-top: 6px; line-height: 1.5; }

/* ---------- カード ---------- */
.cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.card {
  background: var(--card); border: 2px solid var(--ink); border-radius: var(--radius);
  padding: 16px; box-shadow: 4px 4px 0 var(--ink);
}
a.card { display: block; text-decoration: none; color: inherit; transition: transform .12s, box-shadow .12s; }
a.card:hover { transform: translate(-2px, -2px); box-shadow: 6px 6px 0 var(--pink); }
.card .kicker { font-family: var(--dot); font-size: 12px; color: var(--pink); }
.card p { margin: 6px 0 0; font-size: 14px; color: var(--muted); }
.card.soon { border-style: dashed; box-shadow: none; opacity: .75; }
.hero {
  background: var(--night); color: #fff; border-radius: var(--radius); padding: 24px 20px; margin-bottom: 22px;
  position: relative; overflow: hidden;
}
.hero h1 { font-size: 34px; margin: 0; }
.hero h1 em { font-style: normal; color: var(--yellow); }
.hero p { margin: 8px 0 0; color: #d9d4ff; max-width: 560px; }
.hero .tiles-deco { margin-top: 16px; }

/* ---------- ルール ---------- */
.toc { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 8px; }
.toc a {
  font-size: 13px; padding: 4px 10px; border-radius: 99px; background: #fff; border: 1.5px solid var(--line);
  text-decoration: none; color: var(--ink); font-weight: 800;
}
.toc a:hover { border-color: var(--pink); }
.rule-sec { background: #fff; border-radius: var(--radius); padding: 4px 18px 16px; margin-top: 16px; border: 1.5px solid var(--line); scroll-margin-top: 110px; }
.rule-sec h2 { margin-top: 16px; }
.rule-sec h2 .no { font-family: var(--dot); color: var(--pink); font-size: 14px; margin-right: 8px; }
.rule-sec ul { padding-left: 1.3em; margin: 8px 0; }
.rule-sec li { margin: 3px 0; }
.rule-sec .mat { margin: 10px 0; }
.note {
  background: #fffbd1; border-left: 4px solid var(--yellow); border-radius: 8px;
  padding: 8px 12px; margin: 10px 0; font-size: 14px;
}

/* ---------- 役図鑑 ---------- */
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 4px 0 14px; }
.chip {
  border: 2px solid var(--ink); background: #fff; border-radius: 99px; padding: 4px 12px;
  font-weight: 800; font-size: 13px; cursor: pointer;
}
.chip[aria-pressed="true"] { background: var(--ink); color: var(--yellow); }
.yaku-list { display: grid; gap: 12px; }
.yaku {
  scroll-margin-top: 110px;
  background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); overflow: hidden;
}
.yaku > summary {
  list-style: none; cursor: pointer; padding: 12px 14px; display: grid;
  grid-template-columns: 1fr auto; gap: 4px 12px; align-items: center;
}
.yaku > summary::-webkit-details-marker { display: none; }
.yaku .nm { font-family: var(--display); font-size: 18px; }
.yaku .kana { font-size: 12px; color: var(--muted); margin-left: 6px; font-family: var(--body); }
.yaku .sum { grid-column: 1 / -1; font-size: 14px; color: var(--muted); }
.han-badge {
  font-family: var(--display); font-size: 14px; background: var(--yellow); border: 2px solid var(--ink);
  border-radius: 8px; padding: 1px 8px; white-space: nowrap;
}
.han-badge.yakuman { background: var(--pink); color: #fff; }
.han-badge small { font-family: var(--body); font-size: 11px; }
.freq { font-size: 11px; font-weight: 800; color: var(--blue); margin-left: 6px; font-family: var(--body); }
.yaku .body { padding: 0 14px 14px; }
.yaku .body h4 { margin: 12px 0 4px; font-size: 13px; color: var(--pink); }
.yaku .body ul { margin: 4px 0; padding-left: 1.3em; font-size: 14px; }
.yaku .calc-line { font-size: 13px; color: #d7f5e8; margin-top: 6px; }
.yaku .calc-line b { color: var(--yellow); }

/* ---------- 点数計算 ---------- */
.calc { display: grid; gap: 14px; }
@media (min-width: 900px) { .calc { grid-template-columns: 1.15fr .85fr; align-items: start; } }
.panel { background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); padding: 14px; }
.panel h3 { font-size: 15px; margin-bottom: 8px; }
.slot-label { font-size: 12px; font-weight: 800; color: #d7f5e8; margin-bottom: 4px; display: flex; justify-content: space-between; gap: 8px; }
.slot { min-height: 56px; display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.slot .tile, .palette .tile { cursor: pointer; }
.slot .tile:hover { transform: translateY(-3px); }
.slot-hand { gap: 1px; }
.slot-hand .win-slot { margin-left: 2%; }
.slot-hand .melds { margin-left: 2%; }
.slot-hand > .tile.fit, .slot-hand .win-slot .tile.fit { width: clamp(18px, 6.6%, 40px); height: auto; aspect-ratio: 60 / 80; }
.slot-hand .win-slot { width: clamp(18px, 6.6%, 40px); }
.slot-hand .win-slot .tile.fit { width: 100%; }
.slot .empty { color: #9fd3bd; font-size: 13px; }
.mat + .mat { margin-top: 8px; }
.target-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 10px; }
.target-tabs button {
  border: 2px solid var(--ink); background: #fff; border-radius: 10px; padding: 5px 10px; font-weight: 800; font-size: 13px; cursor: pointer;
}
.target-tabs button[aria-pressed="true"] { background: var(--pink); color: #fff; }
.palette { display: grid; gap: 6px; }
.palette .prow { display: flex; flex-wrap: wrap; gap: 3px; }
.palette .tile { transition: transform .08s; }
.palette .tile:hover { transform: translateY(-3px); }
.palette .tile.disabled { opacity: .25; pointer-events: none; }
.opts { display: grid; gap: 10px; }
.opt-row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.opt-row > .lbl { font-size: 12px; font-weight: 800; color: var(--muted); width: 64px; flex: none; }
.seg { display: inline-flex; border: 2px solid var(--ink); border-radius: 10px; overflow: hidden; }
.seg button { border: 0; background: #fff; padding: 4px 10px; font-weight: 800; font-size: 13px; cursor: pointer; }
.seg button + button { border-left: 2px solid var(--ink); }
.seg button[aria-pressed="true"] { background: var(--ink); color: var(--yellow); }
.toggle { border: 2px solid var(--line); background: #fff; border-radius: 99px; padding: 3px 10px; font-size: 13px; font-weight: 800; cursor: pointer; }
.toggle[aria-pressed="true"] { border-color: var(--ink); background: var(--yellow); }
.btn {
  border: 2px solid var(--ink); background: var(--yellow); border-radius: 12px; padding: 8px 16px;
  font-weight: 800; cursor: pointer; box-shadow: 3px 3px 0 var(--ink);
}
.btn:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.btn.ghost { background: #fff; }
.btn.pink { background: var(--pink); color: #fff; }

.result .big { font-family: var(--display); font-size: 36px; line-height: 1.2; }
.result .big small { font-size: 16px; }
.result .label { display: inline-block; background: var(--pink); color: #fff; font-family: var(--display); padding: 0 10px; border-radius: 8px; margin-left: 6px; font-size: 16px; vertical-align: middle; }
.result .hanfu { font-weight: 800; color: var(--muted); }
.result table { width: 100%; border-collapse: collapse; margin-top: 10px; font-size: 14px; }
.result td { padding: 4px 2px; border-bottom: 1px dashed var(--line); }
.result td:last-child { text-align: right; font-weight: 800; white-space: nowrap; }
.result tr.sub td { color: var(--muted); font-size: 13px; }
.result .err { color: var(--ng); font-weight: 800; }
.result .hint { color: var(--muted); font-size: 14px; }
.blocks { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 10px; }
.block { display: inline-flex; flex-direction: column; align-items: center; gap: 2px; }
.block small { font-size: 10px; color: #d7f5e8; }
.waits { display: flex; flex-wrap: wrap; gap: 6px; align-items: flex-end; }

/* ---------- ドリル ---------- */
.drill-q { display: grid; gap: 12px; }
.q-meta { display: flex; flex-wrap: wrap; gap: 6px; }
.tag { font-size: 12px; font-weight: 800; border-radius: 6px; padding: 2px 8px; background: #efe9ff; }
.tag.hot { background: var(--yellow); }
.tag.dealer { background: var(--pink); color: #fff; }
.choices { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 8px; }
.choice {
  border: 2px solid var(--ink); background: #fff; border-radius: 12px; padding: 12px 8px;
  font-family: var(--display); font-size: 17px; cursor: pointer; box-shadow: 3px 3px 0 var(--ink);
}
.choice:disabled { cursor: default; }
.choice.correct { background: var(--lime); }
.choice.wrong { background: #ffd3d3; text-decoration: line-through; }
.verdict { font-family: var(--display); font-size: 22px; }
.verdict.ok { color: var(--ok); }
.verdict.ng { color: var(--ng); }
.score-bar { display: flex; gap: 14px; align-items: center; font-weight: 800; flex-wrap: wrap; }
.score-bar .num { font-family: var(--display); font-size: 20px; color: var(--pink); }

/* ---------- 早見表 ---------- */
.table-wrap { overflow-x: auto; background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); }
table.hayami { border-collapse: collapse; width: 100%; min-width: 560px; font-size: 14px; }
table.hayami th, table.hayami td { padding: 6px 8px; text-align: center; border-bottom: 1px solid var(--line); white-space: nowrap; }
table.hayami thead th { background: var(--night); color: #fff; font-weight: 800; position: sticky; top: 0; }
table.hayami tbody th { background: #faf5ff; font-family: var(--display); font-weight: 400; }
table.hayami td.mangan { background: #fff3f9; color: var(--pink); font-weight: 800; }
table.hayami td.na { color: #c9c2d8; }
table.hayami tr.limit th { background: var(--yellow); }

.footer { text-align: center; color: var(--muted); font-size: 12px; padding: 30px 16px; }

@media (max-width: 520px) {
  .tile-md { width: 30px; height: 40px; }
  .tile-lg { width: 38px; height: 51px; }
  .hero h1 { font-size: 28px; }
  .result .big { font-size: 30px; }
}

/* =================== 対局 =================== */
.tile-pd { width: 32px; height: 43px; }
.tile-oh { width: 29px; height: 39px; }
.tile-cd { width: 26px; height: 35px; }
.tile-pd.tile-rot { margin: 0 5px; }
.tile-oh.tile-rot { margin: 0 5px; }
.tile.last svg { filter: drop-shadow(0 0 4px var(--yellow)) drop-shadow(0 0 2px var(--yellow)); }

.play-setup { max-width: 720px; margin: 0 auto; }
.play-setup h1 { font-size: 30px; }
.play-setup h1 em { font-style: normal; color: var(--pink); }
.play-setup .vs { display: flex; gap: 10px; justify-content: center; margin: 4px 0 6px; }
.play-setup figure { margin: 0; text-align: center; }
.play-setup figure img { width: 120px; height: 120px; border-radius: 50%; border: 3px solid var(--ink); object-fit: cover; background: var(--night); }
.play-setup figcaption { font-family: var(--display); font-size: 16px; }
.play-setup .opt-row .lbl { width: 72px; }
.big-btn { font-size: 20px; padding: 12px 28px; font-family: var(--display); font-weight: 400; }

main.wide { max-width: 1320px; padding-top: 10px; }
.play { display: grid; gap: 12px; }
@media (min-width: 1080px) { .play { grid-template-columns: minmax(0, 1fr) 360px; align-items: start; } }
.play-main { min-width: 0; }
.tbl-outer {
  position: relative; width: min(100%, 720px, calc(100vh - 270px)); min-width: 300px; aspect-ratio: 1; margin: 0 auto;
}
.tbl {
  position: absolute; left: 0; top: 0; width: 720px; height: 720px; transform-origin: 0 0; transform: scale(var(--s, 1));
  background: radial-gradient(ellipse at 50% 45%, #1d7a5c 0%, var(--mat) 45%, var(--mat-dark) 100%);
  border-radius: 22px; box-shadow: inset 0 0 0 8px #0b3a2c, 0 6px 0 var(--ink); overflow: hidden;
}
.seat { position: absolute; inset: 0; transform-origin: 360px 360px; pointer-events: none; z-index: 1; } /* 風と点数の札を中央パネルより手前に（パネルの半透明でくすまないように） */
.seat-1 { transform: rotate(-90deg); }
.seat-2 { transform: rotate(180deg); }
.seat-3 { transform: rotate(90deg); }
.seat .pond { position: absolute; left: 258px; top: 472px; width: 400px; }
.seat .pond .prow { display: flex; gap: 1px; height: 44px; align-items: flex-end; }
.seat .seat-label {
  position: absolute; left: 262px; top: 430px; width: 196px; height: 30px; display: flex; align-items: center; justify-content: center; gap: 8px;
  color: #d7f5e8; font-weight: 800; font-size: 15px; border-radius: 8px;
}
/* 風の字は極太のDela Gothicだと東・南の画数が潰れるので、本文の丸ゴシックを太字で、牌っぽい白い札に載せる（2026-10-14 FB「東西南北の文字が潰れて読みづらい」） */
.seat .seat-label .w {
  font-family: var(--body); font-weight: 900; font-size: 1.15em; line-height: 1;
  display: inline-flex; align-items: center; justify-content: center; width: 1.6em; height: 1.6em;
  background: #f4f1e6; color: #0b3a2c; border-radius: 6px; box-shadow: 0 2px 0 rgba(0, 0, 0, .35);
}
.seat .seat-label.dealer .w { background: var(--yellow); color: var(--ink); }
.seat .seat-label.turn { background: rgba(255, 230, 0, .22); color: #fff; box-shadow: inset 0 0 0 2px var(--yellow); }
.seat .stick { display: inline-block; width: 46px; height: 7px; background: #fff; border-radius: 4px; position: relative; }
.seat .stick::after { content: ''; position: absolute; left: 50%; top: 50%; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: var(--ng); }
.opp-hand { position: absolute; left: 0; right: 0; top: 664px; display: flex; justify-content: center; align-items: flex-end; gap: 1px; }
.opp-melds { display: inline-flex; gap: 6px; margin-left: 14px; }
.center {
  position: absolute; left: 258px; top: 258px; width: 204px; height: 204px; border-radius: 16px;
  background: rgba(10, 30, 24, .55); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .12);
  display: flex; flex-direction: column; align-items: center; justify-content: center; color: #e7fff5; text-align: center; padding: 34px 6px;
}
.center .rnd { font-family: var(--body); font-weight: 900; font-size: 26px; line-height: 1.1; letter-spacing: .04em; } /* 場風（東1局の「東」）もDela Gothicだと潰れるので丸ゴシック太字に */
.center .sub { font-size: 12px; opacity: .85; }
.center .left { font-size: 13px; }
.center .left b { font-family: var(--display); font-weight: 400; color: var(--yellow); font-size: 16px; }
.center .dora { display: flex; gap: 1px; margin-top: 4px; }
.center .dora-lbl { font-size: 10px; opacity: .85; line-height: 1.3; margin-top: 2px; }
.avatar { position: absolute; width: 112px; text-align: center; z-index: 5; }
.avatar img { width: 92px; height: 92px; border-radius: 50%; border: 3px solid var(--c); background: var(--night); object-fit: cover; display: block; margin: 0 auto; }
.avatar .nm { display: inline-block; margin-top: -10px; position: relative; background: var(--c); color: #fff; font-family: var(--display); font-size: 13px; padding: 0 10px; border-radius: 99px; }
.av-1 { right: 10px; bottom: 14px; }
.av-2 { right: 10px; top: 12px; }
.av-3 { left: 10px; top: 12px; }
.bubble {
  position: absolute; width: 180px; background: #fff; color: var(--ink); border: 3px solid var(--c); border-radius: 14px;
  padding: 6px 10px; font-weight: 800; font-size: 16px; line-height: 1.35; animation: pop .25s cubic-bezier(.3, 1.6, .5, 1);
}
.av-1 .bubble { right: 104px; bottom: 30px; }
.av-2 .bubble { right: 104px; top: 26px; }
.av-3 .bubble { left: 104px; top: 26px; }
@keyframes pop { from { transform: scale(.4); opacity: 0; } to { transform: scale(1); opacity: 1; } }

.my-area { max-width: 900px; margin: 10px auto 0; }
.my-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; min-height: 44px; }
.my-status { font-weight: 800; color: var(--muted); font-size: 14px; }
.acts { display: flex; flex-wrap: wrap; gap: 6px; }
.act {
  border: 2px solid var(--ink); background: #fff; border-radius: 12px; padding: 6px 14px; font-family: var(--display); font-size: 17px;
  cursor: pointer; box-shadow: 3px 3px 0 var(--ink); display: inline-flex; align-items: center; gap: 6px; animation: pop .2s;
}
.act:active { transform: translate(2px, 2px); box-shadow: 1px 1px 0 var(--ink); }
.act-win { background: var(--pink); color: #fff; font-size: 22px; padding: 6px 22px; animation: pop .2s, glow 1s ease-in-out infinite alternate; }
.act-riichi { background: var(--yellow); }
.act-riichi.on { background: var(--ink); color: var(--yellow); }
.act-pass { background: #eee; }
.act-rec { background: var(--yellow); position: relative; animation: pop .2s, glow 1s ease-in-out infinite alternate; }
.act-rec-tag { position: absolute; top: -11px; left: 50%; transform: translateX(-50%); font-style: normal; font-family: var(--body, inherit); font-size: 10px; font-weight: 800; background: var(--cyan); color: var(--ink); border: 1.5px solid var(--ink); border-radius: 8px; padding: 0 6px; white-space: nowrap; }
.kan-rec { border: 2px solid var(--ink); background: #fffbe0; border-radius: 12px; padding: 8px 10px; margin: 0 0 10px; font-size: 13px; line-height: 1.6; box-shadow: 3px 3px 0 var(--yellow); }
.kan-rec b { display: block; color: var(--pink); font-size: 14px; }
.kan-rec small { display: block; color: var(--muted); font-size: 11px; margin-top: 2px; }
@keyframes glow { from { box-shadow: 3px 3px 0 var(--ink), 0 0 0 0 rgba(255, 46, 136, .6); } to { box-shadow: 3px 3px 0 var(--ink), 0 0 0 10px rgba(255, 46, 136, 0); } }
.my-hand {
  display: flex; align-items: flex-end; gap: 1px; padding: 12px 10px 10px; border-radius: 16px;
  background: linear-gradient(#17614a, #0f4a38); flex-wrap: nowrap; overflow-x: auto;
}
.my-hand .tiles { display: flex; gap: 1px; align-items: flex-end; flex: 1 1 auto; min-width: 0; }
.my-hand .drawn { display: flex; margin-left: 2%; }
.my-hand .my-melds { display: flex; gap: 6px; margin-left: auto; padding-left: 10px; }
.my-hand .tile.mine { width: clamp(22px, 6.2vw, 52px); height: auto; aspect-ratio: 60 / 80; cursor: pointer; transition: transform .1s; }
@media (min-width: 1080px) { .my-hand .tile.mine { width: clamp(22px, 3.4vw, 52px); } }
.my-hand .tile.mine:hover { transform: translateY(-6px); }
.my-hand .tile.mine.sel { transform: translateY(-12px); }
.my-hand .tile.mine.off { filter: brightness(.55); cursor: default; }
.my-hand .tile.mine.off:hover { transform: none; }
.my-hand .tile.mine.rec svg { filter: drop-shadow(0 -3px 0 var(--cyan)); }

.coach { background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); padding: 12px; box-shadow: 4px 4px 0 var(--ink); }
@media (min-width: 1080px) { .coach { position: sticky; top: 100px; max-height: calc(100vh - 116px); overflow-y: auto; } }
.coach-head { font-family: var(--dot); color: var(--pink); font-size: 12px; margin-bottom: 6px; }
.speech { display: flex; gap: 10px; align-items: flex-start; margin: 4px 0 8px; }
.speech img { width: 58px; height: 58px; border-radius: 50%; border: 3px solid var(--c); background: var(--night); flex: none; object-fit: cover; }
.speech .say { background: #fff; border: 2px solid var(--c); border-radius: 12px; padding: 6px 10px; font-size: 14px; line-height: 1.55; position: relative; }
.speech .say b { display: block; font-family: var(--display); font-weight: 400; color: var(--c); font-size: 12px; }
.speech.sm img { width: 40px; height: 40px; }
.speech.sm .say { font-size: 13px; }
.fb { border-radius: 12px; padding: 2px 6px; margin-bottom: 6px; }
.fb-good { background: #effff1; }
.fb-bad { background: #fff0f0; }
.fb-meh { background: #fbf6ff; }
.c-sec { border-top: 1px dashed var(--line); padding-top: 8px; margin-top: 8px; }
.c-sec h4 { margin: 0 0 6px; font-size: 13px; color: var(--pink); }
.c-note { font-size: 12px; color: var(--muted); margin: 6px 0 0; line-height: 1.5; }
.cand {
  width: 100%; display: grid; grid-template-columns: auto 1fr; gap: 2px 10px; align-items: center; text-align: left;
  border: 2px solid var(--line); background: #fff; border-radius: 12px; padding: 6px 8px; margin-bottom: 6px; cursor: pointer;
}
.cand:hover { border-color: var(--ink); }
.cand.best { border-color: var(--ink); background: #f3fdff; box-shadow: 3px 3px 0 var(--cyan); }
.cand .ct { font-size: 14px; line-height: 1.35; }
.cand .ct small { color: var(--muted); }
.cand .ukeire-tiles { grid-column: 1 / -1; display: flex; flex-wrap: wrap; gap: 1px; align-items: center; font-size: 12px; color: var(--muted); }
.safe { color: var(--ok); font-weight: 800; }
.mid { color: #c27b00; font-weight: 800; }
.danger { color: var(--ng); font-weight: 800; }
.hints { margin: 0; padding-left: 1.2em; font-size: 13px; }
.hints li.sure { font-weight: 800; color: var(--ok); }
.pv { font-size: 13px; }
.tipmsg { margin-bottom: 4px; }

.overlay { position: fixed; inset: 0; z-index: 50; display: grid; grid-template-columns: minmax(0, 1fr); place-items: center; background: rgba(18, 10, 46, .55); padding: 16px; overflow-y: auto; }
/* ↑ 列の幅を画面に固定する（2026-11-08）。指定が無いと、手牌の行が長いとき列が中身に合わせて広がり、スマホで結果・クイズの窓が右にはみ出していた */
.overlay[hidden] { display: none; }
.banner { text-align: center; color: #fff; animation: pop .3s cubic-bezier(.3, 1.6, .5, 1); }
.banner .b-big { font-family: var(--display); font-size: clamp(40px, 10vw, 84px); text-shadow: 4px 4px 0 var(--pink); }
.banner .b-sm { font-weight: 800; font-size: 18px; }
.cutin {
  position: relative; width: min(820px, 100%); height: 300px; background: var(--night); border-top: 8px solid var(--c); border-bottom: 8px solid var(--c);
  overflow: hidden; transform: skewY(-4deg); animation: cutin .35s cubic-bezier(.2, 1.4, .5, 1);
}
.cutin .cut-img { position: absolute; right: -10px; bottom: -40px; height: 360px; transform: skewY(4deg); animation: slidein .4s ease-out; }
.cutin .cut-img.multi { height: 220px; bottom: -10px; }
.cutin .cut-img.multi:nth-child(1) { right: 330px; } .cutin .cut-img.multi:nth-child(2) { right: 170px; } .cutin .cut-img.multi:nth-child(3) { right: 10px; }
.cutin .cut-text {
  position: absolute; left: 30px; top: 40px; font-family: var(--display); font-size: clamp(64px, 14vw, 140px); color: #fff; transform: skewY(4deg);
  text-shadow: 6px 6px 0 var(--c), -2px -2px 0 var(--ink); animation: slam .4s .1s both cubic-bezier(.3, 1.8, .5, 1);
}
.cutin .cut-who { position: absolute; left: 36px; bottom: 30px; color: var(--yellow); font-weight: 800; font-size: 20px; transform: skewY(4deg); }
@keyframes cutin { from { transform: skewY(-4deg) translateX(-110%); } to { transform: skewY(-4deg) translateX(0); } }
@keyframes slidein { from { transform: skewY(4deg) translateX(60%); opacity: 0; } to { transform: skewY(4deg) translateX(0); opacity: 1; } }
@keyframes slam { from { transform: skewY(4deg) scale(2.6); opacity: 0; } to { transform: skewY(4deg) scale(1); opacity: 1; } }
.result-card {
  width: min(680px, 100%); background: #fff; border: 3px solid var(--ink); border-radius: 18px; box-shadow: 6px 6px 0 var(--pink);
  padding: 18px; text-align: center; animation: pop .25s;
}
.result-card .r-title { font-family: var(--display); font-size: 22px; margin-bottom: 8px; text-shadow: 1px 1px 0 var(--ink); }
.result-card.draw .r-title, .result-card.over .r-title { color: var(--ink); text-shadow: none; }
.r-hand { background: linear-gradient(#17614a, #0f4a38); border-radius: 12px; padding: 10px; overflow-x: auto; }
.r-dora { font-size: 12px; color: var(--muted); margin: 6px 0; display: flex; align-items: center; justify-content: center; gap: 4px; flex-wrap: wrap; }
.r-yaku { list-style: none; padding: 0; margin: 8px auto; max-width: 360px; min-height: 30px; }
.r-yaku li { display: flex; justify-content: space-between; font-family: var(--display); font-size: 20px; border-bottom: 2px dashed var(--line); padding: 2px 4px; }
.r-yaku li b { font-weight: 400; color: var(--pink); }
.slam { animation: slam2 .3s cubic-bezier(.3, 1.8, .5, 1); }
@keyframes slam2 { from { transform: scale(1.8); opacity: 0; } to { transform: scale(1); opacity: 1; } }
.r-total { font-family: var(--display); font-size: 22px; min-height: 34px; }
.lbl-big { display: inline-block; background: var(--pink); color: #fff; padding: 0 14px; border-radius: 10px; font-size: 28px; margin-left: 6px; transform: rotate(-4deg); }
.r-pts { font-family: var(--display); font-size: 46px; line-height: 1.2; min-height: 56px; }
.r-pts small { display: block; font-family: var(--body); font-size: 14px; color: var(--muted); }
.r-delta { display: flex; flex-wrap: wrap; justify-content: center; gap: 4px 14px; font-weight: 800; margin: 6px 0 10px; }
.plus { color: var(--ok); } .minus { color: var(--ng); }
.r-why { text-align: left; margin: 0 auto 12px; max-width: 420px; font-size: 14px; }
.r-why summary { cursor: pointer; font-weight: 800; color: var(--blue); }
.r-why table { width: 100%; border-collapse: collapse; }
.r-why td { border-bottom: 1px dashed var(--line); padding: 2px 4px; } .r-why td:last-child { text-align: right; }
.shake { animation: shake .45s; }
@keyframes shake { 0%, 100% { transform: none; } 20% { transform: translate(-8px, 4px) rotate(-1deg); } 40% { transform: translate(8px, -4px) rotate(1deg); } 60% { transform: translate(-5px, 2px); } 80% { transform: translate(4px, -2px); } }
.draw-grid { display: grid; gap: 6px; text-align: left; margin: 10px 0; }
.dg { border: 2px solid var(--line); border-radius: 10px; padding: 6px 10px; }
.dg.tp { border-color: var(--ok); }
.dg .d { float: right; font-weight: 800; }
.rank { list-style: none; padding: 0; margin: 8px auto 12px; max-width: 360px; }
.rank li { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-bottom: 2px dashed var(--line); font-size: 18px; }
.rank li.me { background: #fffbd1; border-radius: 10px; }
.rank .pl { font-family: var(--display); width: 48px; }
.rank img { width: 40px; height: 40px; border-radius: 50%; background: var(--night); }
.rank .nm { font-weight: 800; }
.rank b { margin-left: auto; font-family: var(--display); font-weight: 400; }
.result-card .speech { text-align: left; justify-content: center; }
@media (max-width: 520px) {
  .cutin { height: 220px; } .cutin .cut-img { height: 260px; } .cutin .cut-img.multi { height: 140px; }
  .cutin .cut-img.multi:nth-child(1) { right: 200px; } .cutin .cut-img.multi:nth-child(2) { right: 100px; }
  .r-pts { font-size: 36px; }
}

.card-play { grid-column: 1 / -1; background: var(--yellow); }
.card-play .faces { display: flex; gap: 6px; margin-top: 10px; }
.card-play .faces img { width: 64px; height: 64px; border-radius: 50%; border: 2px solid var(--ink); background: var(--night); }

/* 文章中の牌（絵＋ふりがな）と用語 */
.tref { display: inline-flex; align-items: flex-end; gap: 2px; margin: 0 2px; vertical-align: -6px; white-space: nowrap; }
.tref .tile { width: 18px; height: 24px; }
.tref ruby { font-weight: 800; }
.tref rt { font-size: 9px; font-weight: 800; color: var(--pink); letter-spacing: 0; }
.mat .tref, .caption .tref { color: #fff; }
.mat .tref rt { color: var(--yellow); }
ruby { ruby-position: over; }
.rd { font-weight: 800; color: var(--pink); font-size: 11px; }
.term { text-decoration: underline dotted var(--pink) 2px; text-underline-offset: 3px; cursor: help; }
.term-pop {
  position: fixed; z-index: 80; background: var(--night); color: #fff; border-radius: 12px; padding: 10px 12px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, .3); font-size: 13px; line-height: 1.6;
}
.term-pop b { font-family: var(--display); font-weight: 400; font-size: 15px; color: var(--yellow); margin-right: 6px; }
.term-pop small { color: var(--cyan); }
.term-pop p { margin: 4px 0 0; }
.speech .say { line-height: 1.9; }

/* コーチ: 理由・おすすめ度・方針・河の読み */
.cand .why { grid-column: 1 / -1; margin: 2px 0 2px; padding-left: 1.1em; font-size: 12px; line-height: 1.5; }
.cand .why li { color: var(--muted); }
.cand .why li.g { color: var(--ok); }
.cand .why li.b { color: var(--ng); }
.stars { color: #f5a400; letter-spacing: 1px; margin-left: 4px; }
.stars .off { color: #ddd; }
.grade { font-size: 11px; font-weight: 800; border-radius: 6px; padding: 0 6px; margin-left: 4px; }
.grade.g3 { background: var(--yellow); }
.grade.g2 { background: #e8f4ff; }
.grade.g1 { background: #f2f2f2; color: var(--muted); }
.policy { display: grid; grid-template-columns: 92px 1fr; gap: 8px; font-size: 13px; padding: 6px 0; border-bottom: 1px dashed var(--line); line-height: 1.7; }
.policy .pn { font-weight: 800; font-size: 12px; border-radius: 8px; padding: 2px 6px; text-align: center; align-self: start; }
.pol-speed .pn { background: #e3fbff; } .pol-value .pn { background: #fff3c2; } .pol-safe .pn { background: #e6ffe9; } .pol-riichi .pn { background: #ffe3f0; }
.policy small { display: block; color: var(--muted); font-size: 11px; line-height: 1.5; }
.read { display: flex; gap: 8px; margin-bottom: 6px; font-size: 13px; }
.read img { width: 32px; height: 32px; border-radius: 50%; background: var(--night); flex: none; }
.read ul { margin: 0; padding-left: 1.1em; line-height: 1.6; }
.read .lv-danger { color: var(--ng); font-weight: 800; }
.read .lv-warn { color: #b06a00; }
.read .lv-calm, .read .lv-info { color: var(--muted); }

/* 用語のルビ */
ruby rt { font-size: 9px; font-weight: 800; color: var(--pink); }
.term ruby rt { color: var(--pink); }
.mat ruby rt, .term-pop ruby rt { color: var(--yellow); }
.cand .ct, .policy, .read, .speech .say, .rule-sec p, .rule-sec li, .yaku .body { line-height: 2; }
ruby rt { font-size: 8px; letter-spacing: -0.5px; }

/* 目指す役の方向性 */
.dir { margin-bottom: 8px; font-size: 13px; }
.dir-head { display: flex; align-items: baseline; gap: 6px; }
.dir-head small { color: var(--muted); font-size: 11px; }
.dir-head .pct { margin-left: auto; font-family: var(--display); color: var(--pink); }
.bar { height: 8px; background: #f0e8f5; border-radius: 99px; overflow: hidden; margin: 2px 0 3px; }
.bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--pink)); border-radius: 99px; }
.dir-text { color: var(--muted); font-size: 12px; line-height: 1.9; }

/* AIコーチ */
.ai-box { border: 2px solid var(--ink); border-radius: 12px; padding: 10px; margin-bottom: 10px; background: linear-gradient(180deg, #fff 0%, #fff6fb 100%); }
.ai-head { font-family: var(--display); font-size: 15px; margin-bottom: 6px; }
.ai-head small { font-family: var(--dot); font-size: 11px; color: var(--muted); margin-left: 6px; }
.ai-who { display: flex; gap: 6px; margin-bottom: 6px; }
.chip-who { display: inline-flex; align-items: center; gap: 4px; border: 2px solid var(--line); background: #fff; border-radius: 99px; padding: 2px 10px 2px 2px; font-weight: 800; font-size: 12px; cursor: pointer; }
.chip-who img { width: 24px; height: 24px; border-radius: 50%; background: var(--night); }
.chip-who.on { border-color: var(--c); background: color-mix(in srgb, var(--c) 14%, #fff); }
.ai-quick { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 6px; }
.qbtn { border: 1.5px solid var(--line); background: #fff; border-radius: 99px; padding: 3px 9px; font-size: 12px; font-weight: 800; cursor: pointer; }
.qbtn:hover { border-color: var(--pink); }
.ai-form { display: flex; gap: 6px; }
.ai-form input { flex: 1; min-width: 0; border: 2px solid var(--ink); border-radius: 10px; padding: 6px 10px; font: inherit; font-size: 13px; }
.ai-form .btn { padding: 6px 14px; }
.ai-ans { margin-top: 10px; }
.ai-ans .aq { display: block; font-family: var(--body); color: var(--muted); font-size: 11px; font-weight: 800; }
.typing { color: var(--muted); }

/* ===== コーチ欄を広く（2026-10-03 Aira「右側の解説を広げてもいい」） ===== */
main.wide { max-width: 1560px; }
@media (min-width: 1080px) {
  .play { grid-template-columns: minmax(480px, 1fr) minmax(420px, 1.05fr); }
}
.play-main { container-type: inline-size; }
.my-hand .tile.mine { width: clamp(22px, 6.4cqw, 54px) !important; }
.coach { container-type: inline-size; }
@container (min-width: 640px) {
  #coach { display: grid; grid-template-columns: 1fr 1fr; gap: 0 16px; align-items: start; }
  #coach > .full, #coach > .c-idle { grid-column: 1 / -1; }
  .ai-box { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 16px; }
  .ai-box .ai-head { grid-column: 1 / -1; }
  .ai-box #ai-answer { grid-column: 1 / -1; }
}

/* ===== ドパドパ演出（ポン・チー・カン・リーチ・ロン・ツモ・テンパイ） ===== */
.tbl-outer { container-type: inline-size; }
.callfx { position: absolute; inset: 0; z-index: 30; pointer-events: none; overflow: hidden; border-radius: 22px; }
.fx-flash { position: absolute; inset: 0; background: radial-gradient(circle at var(--x) var(--y), rgba(255,255,255,.95) 0%, color-mix(in srgb, var(--c) 55%, transparent) 25%, transparent 60%); animation: fxflash .55s ease-out forwards; }
.fx-rays {
  position: absolute; left: var(--x); top: var(--y); width: 220cqw; height: 220cqw; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--c) 75%, transparent) 0deg 7deg, transparent 7deg 18deg);
  -webkit-mask: radial-gradient(circle, transparent 0 6%, #000 10% 22%, transparent 48%); mask: radial-gradient(circle, transparent 0 6%, #000 10% 22%, transparent 48%);
  animation: fxrays .9s ease-out forwards;
}
.fx-text {
  position: absolute; left: var(--x); top: var(--y); white-space: nowrap;
  font-family: var(--display); font-size: 15cqw; line-height: 1; color: #fff;
  -webkit-text-stroke: 1.4cqw var(--ink); paint-order: stroke fill; text-shadow: 1.2cqw 1.2cqw 0 var(--c);
  transform: translate(-50%, -50%); animation: fxslam .8s cubic-bezier(.2, 1.7, .4, 1) forwards;
}
.callfx.big .fx-text { font-size: 24cqw; -webkit-text-stroke: 2cqw var(--ink); text-shadow: 1.8cqw 1.8cqw 0 var(--c); animation-duration: 1.1s; }
.callfx.small .fx-text { font-size: 9cqw; -webkit-text-stroke: 1cqw var(--ink); text-shadow: .8cqw .8cqw 0 var(--pink); }
.fx-sub { position: absolute; left: var(--x); top: calc(var(--y) + 11cqw); transform: translateX(-50%); font-family: var(--display); font-size: 4cqw; color: var(--ink); background: var(--c); padding: 0 2cqw; border-radius: 99px; animation: fxfade .8s forwards; }
.fx-img { position: absolute; height: 46cqw; filter: drop-shadow(0 0 1cqw var(--c)); animation: fxin .76s cubic-bezier(.2, 1.3, .4, 1) forwards; -webkit-mask: radial-gradient(ellipse 70% 75% at 50% 45%, #000 60%, transparent 72%); mask: radial-gradient(ellipse 70% 75% at 50% 45%, #000 60%, transparent 72%); }
.side-1 .fx-img { right: -4cqw; bottom: 8cqw; --from: 40cqw; }
.side-2 .fx-img { right: 4cqw; top: -2cqw; --from: 40cqw; }
.side-3 .fx-img { left: -4cqw; top: 6cqw; --from: -40cqw; }
.side-0 .fx-img { left: 4cqw; bottom: 2cqw; --from: -40cqw; }
.callfx.big .fx-img { height: 70cqw; bottom: -6cqw; right: -6cqw; top: auto; left: auto; }
.callfx.big .fx-img.multi { height: 42cqw; bottom: -2cqw; }
.callfx.big .fx-img.m0 { left: 2cqw; right: auto; } .callfx.big .fx-img.m1 { left: 50%; right: auto; transform: translateX(-50%); } .callfx.big .fx-img.m2 { right: 2cqw; }
.tbl-outer.quake .tbl { animation: quake .38s; }
.tbl-outer.quake-big .tbl { animation: quakebig .6s; }
@keyframes fxflash { 0% { opacity: 1; } 100% { opacity: 0; } }
@keyframes fxrays { 0% { opacity: 0; transform: translate(-50%, -50%) rotate(0deg) scale(.4); } 25% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) rotate(40deg) scale(1.15); } }
@keyframes fxslam {
  0% { transform: translate(-50%, -50%) scale(3.2) rotate(-14deg); opacity: 0; }
  18% { transform: translate(-50%, -50%) scale(.92) rotate(-6deg); opacity: 1; }
  28% { transform: translate(-50%, -50%) scale(1.05) rotate(-6deg); }
  80% { transform: translate(-50%, -50%) scale(1) rotate(-6deg); opacity: 1; }
  100% { transform: translate(-50%, -50%) scale(1.15) rotate(-6deg); opacity: 0; }
}
@keyframes fxin { 0% { transform: translateX(var(--from, 30cqw)); opacity: 0; } 25% { transform: none; opacity: 1; } 80% { opacity: 1; } 100% { opacity: 0; } }
@keyframes fxfade { 0%, 80% { opacity: 1; } 100% { opacity: 0; } }
@keyframes quake { 0%, 100% { transform: scale(var(--s, 1)); } 20% { transform: scale(var(--s, 1)) translate(-7px, 4px); } 40% { transform: scale(var(--s, 1)) translate(6px, -5px); } 60% { transform: scale(var(--s, 1)) translate(-4px, 2px); } 80% { transform: scale(var(--s, 1)) translate(3px, -1px); } }
@keyframes quakebig { 0%, 100% { transform: scale(var(--s, 1)); } 10% { transform: scale(var(--s, 1)) translate(-14px, 8px) rotate(-.6deg); } 25% { transform: scale(var(--s, 1)) translate(12px, -10px) rotate(.6deg); } 45% { transform: scale(var(--s, 1)) translate(-8px, 5px); } 65% { transform: scale(var(--s, 1)) translate(6px, -3px); } 85% { transform: scale(var(--s, 1)) translate(-2px, 1px); } }
@media (prefers-reduced-motion: reduce) { .tbl-outer.quake .tbl, .tbl-outer.quake-big .tbl { animation: none; } }

.basis { color: var(--muted); font-size: 11px; }

/* 捨て牌が「パチッ」と着地（雀魂風）・ツモ牌の滑り込み */
.tile.pop { animation: tilepop .34s cubic-bezier(.2, 1.3, .4, 1) both; }
.tile.pop-rot { animation: tilepoprot .34s cubic-bezier(.2, 1.3, .4, 1) both; }
@keyframes tilepop {
  0% { transform: translateY(-22px) scale(1.4); opacity: 0; filter: drop-shadow(0 14px 6px rgba(0,0,0,.45)); }
  45% { transform: translateY(0) scale(.92); opacity: 1; filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 3px var(--yellow)); }
  70% { transform: scale(1.05); }
  100% { transform: none; }
}
@keyframes tilepoprot {
  0% { transform: rotate(-90deg) translateX(22px) scale(1.4); opacity: 0; }
  45% { transform: rotate(-90deg) scale(.92); opacity: 1; filter: drop-shadow(0 0 6px #fff) drop-shadow(0 0 3px var(--yellow)); }
  70% { transform: rotate(-90deg) scale(1.05); }
  100% { transform: rotate(-90deg); }
}
.drawn.draw-in { animation: drawin .22s cubic-bezier(.2, 1.2, .4, 1) both; }
@keyframes drawin { 0% { transform: translate(40px, -12px); opacity: 0; } 100% { transform: none; opacity: 1; } }
.snd { display: inline-flex; gap: 3px; margin-left: auto; }
.sndbtn { border: 2px solid var(--line); background: #fff; color: var(--muted); border-radius: 8px; padding: 1px 7px; font-size: 11px; font-weight: 800; cursor: pointer; text-decoration: line-through; }
.sndbtn.on { border-color: var(--ink); color: var(--ink); text-decoration: none; background: var(--yellow); }

/* 配牌の印象 */
.haipai-pop { position: absolute; inset: 0; z-index: 25; display: grid; place-items: center; background: rgba(18, 10, 46, .35); animation: fxfadein .2s; }
.haipai-pop.out { opacity: 0; transition: opacity .2s; }
.hp-card { display: flex; gap: 3cqw; align-items: center; width: 82cqw; background: #fff; border: 3px solid var(--ink); border-radius: 18px; padding: 3cqw; box-shadow: 6px 6px 0 var(--pink); animation: slam2 .35s cubic-bezier(.3, 1.6, .5, 1); }
.hp-grade { font-family: var(--display); font-size: 22cqw; line-height: 1; width: 22cqw; text-align: center; -webkit-text-stroke: 1cqw var(--ink); paint-order: stroke fill; color: #fff; text-shadow: 1cqw 1cqw 0 var(--gc, var(--muted)); }
.g-S { --gc: #ff2e88; } .g-A { --gc: #ff8a00; } .g-B { --gc: #22b8e6; } .g-C { --gc: #8b7fb8; } .g-D { --gc: #6b6488; }
.hp-body { flex: 1; min-width: 0; }
.hp-ttl { font-family: var(--display); font-size: 4.4cqw; }
.hp-plan { font-size: 13px; line-height: 1.8; }
.haipai-pop .hp-plan { font-size: 3.2cqw; }
.hp-mini { display: inline-block; font-family: var(--display); color: #fff; background: var(--gc); border-radius: 6px; padding: 0 8px; }
.hp-lines { margin: 4px 0; padding-left: 1.1em; font-size: 13px; line-height: 1.9; }
.hp-lines b { display: inline-block; min-width: 4.5em; color: var(--pink); }
@keyframes fxfadein { from { opacity: 0; } to { opacity: 1; } }

/* コーチ欄に質問を統合（独立した枠にしない） */
.ai-box { border: 0; padding: 0 0 8px; margin: 0 0 6px; background: none; border-bottom: 1px dashed var(--line); display: block !important; }
.ai-lbl { font-size: 12px; font-weight: 800; color: var(--pink); margin-right: 2px; align-self: center; }
.coach > .coach-head { margin-bottom: 8px; font-size: 13px; }

.hp-card { position: relative; }
.hp-close {
  position: absolute; top: -14px; right: -14px; width: 40px; height: 40px; border-radius: 50%;
  border: 3px solid var(--ink); background: var(--yellow); font-size: 22px; font-weight: 800; line-height: 1; cursor: pointer;
  box-shadow: 2px 2px 0 var(--ink);
}
.hp-close:hover { background: var(--pink); color: #fff; }

/* 相手の河の読み（卓の上・名前の近く）。河や手牌と重ならない位置に置く */
.reads { position: absolute; z-index: 6; max-width: 150px; display: flex; flex-direction: column; gap: 4px; }
.rd-1 { right: 118px; bottom: 16px; align-items: flex-end; }
.rd-2 { right: 118px; top: 62px; align-items: flex-end; }
.rd-3 { left: 118px; top: 62px; align-items: flex-start; }
.rd-tags { all: unset; cursor: pointer; display: flex; flex-direction: column; gap: 3px; align-items: inherit; }
.rd-1 .rd-tags, .rd-2 .rd-tags { align-items: flex-end; }
.rtag {
  display: inline-block; white-space: nowrap; font-size: 14px; font-weight: 800; line-height: 1.2; padding: 3px 9px; border-radius: 99px;
  background: rgba(255, 255, 255, .92); color: var(--ink); border: 2px solid var(--c); box-shadow: 0 2px 0 rgba(0, 0, 0, .25);
}
.rtag.lv-danger { background: var(--ng); color: #fff; border-color: #fff; animation: glowr 1s ease-in-out infinite alternate; }
.rtag.lv-warn { background: var(--yellow); }
.rtag.lv-calm, .rtag.lv-info { background: rgba(255, 255, 255, .8); color: #555; }
@keyframes glowr { from { box-shadow: 0 0 0 0 rgba(211, 38, 43, .7); } to { box-shadow: 0 0 0 6px rgba(211, 38, 43, 0); } }
.rd-detail {
  position: relative; z-index: 7; width: 260px; background: #fff; color: var(--ink); border: 3px solid var(--c); border-radius: 12px; padding: 8px 10px;
  font-size: 13px; line-height: 1.8; box-shadow: 0 6px 16px rgba(0, 0, 0, .35); animation: pop .2s;
}
.rd-1 .rd-detail { position: absolute; bottom: 100%; right: 0; margin-bottom: 6px; }
.rd-detail b { display: block; color: var(--c); font-family: var(--display); font-weight: 400; }
.rd-detail ul { margin: 2px 0 0; padding-left: 1.1em; }
.rd-detail .lv-danger { color: var(--ng); font-weight: 800; }
.rd-detail .lv-warn { color: #9a5b00; }

/* コーチ: 手牌の上の帯（次の指針＋おすすめ）と、開閉できるサイドバー */
.play.coach-closed { grid-template-columns: 1fr !important; }
.play.coach-closed > .coach { display: none; }
.play.coach-closed .play-main { max-width: 1000px; margin: 0 auto; width: 100%; }
.coach-head { display: flex; align-items: center; justify-content: space-between; }
.side-close, .strip-toggle { border: 2px solid var(--ink); background: #fff; border-radius: 99px; padding: 2px 10px; font-size: 12px; font-weight: 800; cursor: pointer; white-space: nowrap; }
.side-close:hover, .strip-toggle:hover { background: var(--yellow); }
.strip { max-width: 900px; margin: 10px auto 0; }
.strip-row { display: flex; align-items: center; gap: 10px; background: #fff; border: 2px solid var(--ink); border-radius: 14px; padding: 6px 10px; box-shadow: 3px 3px 0 var(--ink); min-height: 64px; }
.strip-row.fb-good { background: #effff1; } .strip-row.fb-bad { background: #fff0f0; } .strip-row.fb-meh { background: #fbf6ff; }
.strip-say { display: flex; align-items: center; gap: 8px; flex: 1; min-width: 0; font-size: 14px; line-height: 1.9; }
.strip-say img { width: 46px; height: 46px; border-radius: 50%; border: 3px solid var(--c); background: var(--night); flex: none; }
.strip-say b { display: inline-block; font-family: var(--display); font-weight: 400; color: var(--c); font-size: 12px; margin-right: 8px; }
.rec-tile { display: flex; align-items: center; gap: 6px; border: 2px solid var(--ink); background: #f3fdff; border-radius: 12px; padding: 4px 10px 4px 6px; cursor: pointer; box-shadow: 3px 3px 0 var(--cyan); flex: none; }
.rec-tile:hover { transform: translateY(-2px); }
.rec-tile > span { display: flex; flex-direction: column; line-height: 1.25; text-align: left; }
.rec-tile small { font-size: 10px; font-weight: 800; color: var(--pink); }
.rec-tile b { font-size: 15px; } .rec-tile em { font-style: normal; font-size: 11px; color: var(--pink); }
.rec-tile .stars { margin: 0; }
@media (max-width: 640px) { .strip-row { flex-wrap: wrap; } .strip-say { flex-basis: 100%; } }
.tbl-outer { width: min(100%, 720px, calc(100vh - 345px)); }

.haipai-pop .hp-lines { font-size: 2.9cqw; line-height: 1.8; margin: 1cqw 0; }
.haipai-pop .hp-lines b, .haipai-pop .hp-plan b { color: var(--pink); margin-right: 1cqw; }
.haipai-pop .hp-plan { font-size: 2.9cqw; }
.haipai-pop .hp-card { max-height: 92cqw; overflow-y: auto; }
.haipai-pop .hp-lines b { min-width: 0; }

/* ===== 3列構成（2026-10-03 Aira「卓 ｜ おすすめ打牌など ｜ コーチとのチャット」） ===== */
.play { display: grid; gap: 12px; grid-template-columns: minmax(0, 1fr); grid-template-areas: "main" "info" "chat"; align-items: start; }
.play-main { grid-area: main; }
.coach-info { grid-area: info; }
.coach-chat { grid-area: chat; }
.play.no-info .coach-info, .play.no-chat .coach-chat { display: none; }
@media (min-width: 1080px) {
  .play { grid-template-columns: minmax(460px, 1.15fr) minmax(340px, 1fr); grid-template-areas: "main info" "main chat"; }
  .play.no-info { grid-template-areas: "main chat"; }
  .play.no-chat { grid-template-areas: "main info"; }
  .play .coach { position: static; max-height: none; overflow: visible; }
  .coach-chat { height: 560px; }
}
@media (min-width: 1360px) {
  .play { grid-template-columns: minmax(460px, 1.3fr) minmax(320px, .9fr) minmax(300px, .8fr); grid-template-areas: "main info chat"; }
  .play.no-info { grid-template-columns: minmax(460px, 1.45fr) minmax(320px, .8fr); grid-template-areas: "main chat"; }
  .play.no-chat { grid-template-columns: minmax(460px, 1.3fr) minmax(340px, 1fr); grid-template-areas: "main info"; }
  .play .coach { position: sticky; top: 96px; }
  .play .coach-info { max-height: calc(100vh - 112px); overflow-y: auto; }
  .coach-chat { height: calc(100vh - 112px); }
}
@media (min-width: 1080px) { .play.no-info.no-chat { grid-template-columns: minmax(0, 1fr); grid-template-areas: "main"; } }
.play.no-info.no-chat .play-main { max-width: 1000px; margin: 0 auto; width: 100%; }
main.wide { max-width: 1800px; }

.coach-head { font-family: var(--display); font-size: 15px; color: var(--ink); margin-bottom: 8px; }
.coach-head .side-close { font-family: var(--body); }
.strip-row.in-col { box-shadow: none; margin-bottom: 10px; flex-wrap: wrap; }
.strip-row.in-col .strip-say { flex-basis: 100%; }

/* チャット */
.coach-chat { display: flex; flex-direction: column; padding: 10px; }
.chat-log { flex: 1; min-height: 160px; overflow-y: auto; display: flex; flex-direction: column; gap: 10px; padding: 2px 2px 8px; }
.cm { display: flex; gap: 8px; align-items: flex-start; }
.cm.me { justify-content: flex-end; }
.cm.me .cb { background: var(--ink); color: #fff; border-radius: 14px 14px 4px 14px; padding: 6px 12px; max-width: 85%; font-size: 13px; font-weight: 800; }
.cm.bot img { width: 36px; height: 36px; border-radius: 50%; border: 2px solid var(--c); background: var(--night); flex: none; }
.cm.bot .cb { background: #fff; border: 2px solid var(--c); border-radius: 4px 14px 14px 14px; padding: 6px 10px; font-size: 13px; line-height: 1.95; max-width: calc(100% - 44px); }
.cm.bot .cb > b { display: block; font-family: var(--display); font-weight: 400; color: var(--c); font-size: 12px; line-height: 1.4; }
.cm.bot .cb > b small { font-family: var(--body); color: var(--muted); margin-left: 6px; font-size: 10px; font-weight: 800; }
.cm.tip .cb { background: #fffbe8; }
.chat-empty { color: var(--muted); }
.coach-chat .ai-box { border-top: 1px dashed var(--line); border-bottom: 0; padding: 8px 0 0; margin: 0; }
.coach-chat .ai-quick { gap: 4px; }

/* おすすめは手牌のまわりで完結させる */
#coach-top:empty { display: none; }
.my-hand { overflow: visible; padding-top: 22px; }
.my-hand .tiles, .my-hand .drawn { overflow: visible; }
.my-hand .tile.mine { position: relative; }
.my-hand .tile.mine.rec::before {
  content: 'おすすめ'; position: absolute; left: 50%; top: -19px; transform: translateX(-50%); white-space: nowrap;
  font-size: 10px; font-weight: 800; color: var(--ink); background: var(--cyan); border-radius: 99px; padding: 1px 6px; line-height: 1.4;
}
.my-hand .tile.mine.rec svg { filter: drop-shadow(0 0 4px var(--cyan)) drop-shadow(0 0 2px var(--cyan)); }
.my-hand .tile.mine.hl { transform: translateY(-8px); }
.my-hand .tile.mine.hl svg { filter: drop-shadow(0 0 5px var(--yellow)) drop-shadow(0 0 2px var(--yellow)); }

/* ===== 打牌の演出（モリモリ） ===== */
.dfx { position: absolute; left: var(--x); top: var(--y); width: 0; height: 0; z-index: 28; pointer-events: none; }
.dfx .ring { position: absolute; left: 0; top: 0; width: 12cqw; height: 12cqw; margin: -6cqw 0 0 -6cqw; border-radius: 50%;
  border: 1cqw solid var(--c); box-shadow: 0 0 2cqw var(--c), inset 0 0 1.5cqw #fff; animation: dring .55s cubic-bezier(.1, .8, .3, 1) forwards; }
.dfx .ring.r2 { animation-delay: .08s; border-width: .6cqw; }
.dfx.pw1 .ring { width: 7cqw; height: 7cqw; margin: -3.5cqw 0 0 -3.5cqw; border-width: .5cqw; }
.dfx.pw4 .ring { width: 16cqw; height: 16cqw; margin: -8cqw 0 0 -8cqw; border-width: 1.3cqw; }
.dfx .sparks i { position: absolute; left: 0; top: 0; width: 6cqw; height: .7cqw; margin-top: -.35cqw; border-radius: 99px;
  background: linear-gradient(90deg, #fff, var(--c) 40%, transparent); transform-origin: 0 50%;
  transform: rotate(var(--a)) translateX(2cqw) scaleX(.2); animation: dspark .5s cubic-bezier(.1, .9, .3, 1) forwards; }
.dfx.pw4 .sparks i { width: 9cqw; height: 1cqw; }
.dfx em { position: absolute; left: 0; top: -9cqw; transform: translate(-50%, 0); white-space: nowrap; font-style: normal;
  font-family: var(--display); font-size: 6.5cqw; color: #fff; -webkit-text-stroke: .7cqw var(--ink); paint-order: stroke fill;
  text-shadow: .6cqw .6cqw 0 var(--c); animation: dword .8s cubic-bezier(.2, 1.8, .4, 1) forwards; }
.dfx em.big { font-size: 8.5cqw; top: -11cqw; }
@keyframes dring { 0% { transform: scale(.2); opacity: 1; } 100% { transform: scale(2.2); opacity: 0; } }
@keyframes dspark { 0% { transform: rotate(var(--a)) translateX(1cqw) scaleX(.2); opacity: 1; } 60% { opacity: 1; } 100% { transform: rotate(var(--a)) translateX(calc(10cqw * var(--d))) scaleX(1); opacity: 0; } }
@keyframes dword { 0% { transform: translate(-50%, 2cqw) scale(2.4) rotate(-12deg); opacity: 0; } 22% { transform: translate(-50%, 0) scale(.9) rotate(-8deg); opacity: 1; }
  35% { transform: translate(-50%, 0) scale(1.05) rotate(-8deg); } 75% { opacity: 1; } 100% { transform: translate(-50%, -3cqw) scale(1) rotate(-8deg); opacity: 0; } }
@media (prefers-reduced-motion: reduce) { .dfx { display: none; } }

/* ===== 配牌の印象 v2（グラフでドパドパ） ===== */
.hp-card.hp-v2 { width: 92cqw; max-height: 94cqw; display: grid; grid-template-columns: 34cqw 1fr; grid-template-areas: "left right" "bottom bottom"; gap: 1.5cqw 3cqw; padding: 3cqw 3.5cqw; border-color: var(--ink); box-shadow: 1cqw 1cqw 0 var(--gc); }
.hp-v2 .hp-left { grid-area: left; display: flex; flex-direction: column; align-items: center; gap: 1cqw; }
.hp-v2 .hp-right { grid-area: right; display: flex; flex-direction: column; gap: 1cqw; }
.hp-v2 .hp-bottom { grid-area: bottom; border-top: 2px dashed var(--line); padding-top: 1.2cqw; }
.hp-v2 .hp-ttl { font-family: var(--display); font-size: 4.2cqw; align-self: flex-start; }
.hp-grade-wrap { position: relative; width: 30cqw; height: 26cqw; display: grid; place-items: center; }
.hp-v2 .hp-grade { position: relative; z-index: 1; width: auto; font-size: 25cqw; animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both; }
.g-S .hp-grade { background: linear-gradient(135deg, #ff2e88, #ffe600, #22e6ff, #c6ff3d, #ff2e88); background-size: 300% 300%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; -webkit-text-stroke: 1cqw var(--ink); animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both, rainbow 2s linear infinite; }
.hp-rays { position: absolute; inset: -10cqw; background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--gc) 45%, transparent) 0 8deg, transparent 8deg 18deg); -webkit-mask: radial-gradient(circle, #000 20%, transparent 62%); mask: radial-gradient(circle, #000 20%, transparent 62%); animation: hprays 6s linear infinite; }
.hp-v2 .speech.sm { margin: 0; }
.hp-v2 .speech.sm .say { font-size: 2.8cqw; }
.radar { width: 100%; max-height: 40cqw; overflow: visible; }
.radar .rg { fill: none; stroke: #e6dcef; stroke-width: 1; }
.radar .rl { font-family: var(--display); font-size: 12px; fill: var(--ink); }
.radar .rv { font-weight: 800; font-size: 10px; fill: var(--pink); }
.radar .rpoly { animation: radarpop .7s .15s cubic-bezier(.2, 1.6, .4, 1) both; }
.hp-meter { font-size: 2.8cqw; }
.hm-head { display: flex; align-items: baseline; justify-content: space-between; }
.hm-num { font-family: var(--display); font-size: 6cqw; color: var(--gc); line-height: 1; }
.hm-num i { font-style: normal; }
.hm-bar { position: relative; height: 2.6cqw; background: #f0e8f5; border-radius: 99px; overflow: visible; margin: .8cqw 0 .4cqw; }
.hm-bar > i { position: absolute; left: 0; top: 0; bottom: 0; width: var(--w); border-radius: 99px; background: linear-gradient(90deg, var(--cyan), var(--gc)); animation: hmgrow .8s .3s cubic-bezier(.2, 1.3, .4, 1) both; }
.hm-avg { position: absolute; top: -.8cqw; bottom: -.8cqw; left: 33.3%; width: 16.7%; border: 2px dashed var(--ink); border-radius: 6px; opacity: .55; }
.hm-legend { display: flex; justify-content: space-between; font-size: 2.2cqw; color: var(--muted); font-weight: 800; }
.hm-legend .avg { color: var(--ink); }
@keyframes hpslam { 0% { transform: scale(3.5) rotate(-18deg); opacity: 0; } 60% { transform: scale(.9) rotate(-6deg); opacity: 1; } 100% { transform: scale(1) rotate(-6deg); } }
@keyframes rainbow { to { background-position: 300% 0; } }
@keyframes hprays { to { transform: rotate(360deg); } }
@keyframes radarpop { 0% { transform: scale(0) rotate(-40deg); opacity: 0; } 100% { transform: scale(1) rotate(0); opacity: 1; } }
@keyframes hmgrow { from { width: 0; } }

/* 配牌の印象: 四隅のキャラと吹き出しにかぶらないよう中央に収める・×はカードの内側（2026-10-03 Aira） */
.haipai-pop { background: rgba(18, 10, 46, .18); }
.haipai-pop .hp-card.hp-v2 {
  width: 62cqw; max-height: 74cqw; overflow-y: auto; padding: 2.4cqw 2.6cqw;
  grid-template-columns: 1fr 1fr; grid-template-areas: "left left" "right right" "bottom bottom"; gap: 1cqw 2cqw;
}
.hp-v2 .hp-left { flex-direction: row; align-items: center; gap: 2cqw; flex-wrap: wrap; }
.hp-v2 .hp-ttl { flex-basis: 100%; font-size: 3.4cqw; padding-right: 7cqw; }
.hp-v2 .hp-grade-wrap { width: 15cqw; height: 13cqw; flex: none; }
.hp-v2 .hp-grade { font-size: 13cqw; -webkit-text-stroke: .6cqw var(--ink); text-shadow: .6cqw .6cqw 0 var(--gc); }
.hp-v2 .hp-rays { inset: -6cqw; }
.hp-v2 .hp-left .speech.sm { flex: 1; min-width: 0; }
.hp-v2 .hp-left .speech.sm img { width: 6cqw; height: 6cqw; }
.hp-v2 .speech.sm .say { font-size: 2.3cqw; line-height: 1.7; }
.hp-v2 .hp-right { flex-direction: row; align-items: center; gap: 2cqw; }
.hp-v2 .radar { width: 27cqw; max-height: 27cqw; flex: none; }
.hp-v2 .hp-meter { flex: 1; min-width: 0; font-size: 2.3cqw; }
.hp-v2 .hm-num { font-size: 5cqw; }
.hp-v2 .hm-legend { font-size: 1.8cqw; }
.hp-v2 .hp-lines, .hp-v2 .hp-plan { font-size: 2.2cqw; line-height: 1.75; }
.hp-v2 .hp-lines { margin: 0 0 .6cqw; }
.hp-close { top: 1cqw; right: 1cqw; width: 5.6cqw; height: 5.6cqw; min-width: 28px; min-height: 28px; font-size: max(14px, 3cqw); z-index: 2; }
.haipai-pop .hp-card { position: relative; }
.haipai-pop .hp-card.hp-v2 { max-height: 90cqw; }
.hp-v2 .radar { width: 30cqw; max-height: 30cqw; }
.hp-v2 .radar .rl { font-size: 17px; }
.hp-v2 .radar .rv { font-size: 14px; }
/* 配牌の印象を開いているあいだは河の読みのタグを隠す（配牌時は必ず「序盤・まだ不明」でカードにかぶるため） */
.tbl-outer:has(.haipai-pop) .reads { visibility: hidden; }

/* ヘッダーを1行に（2026-10-03 Aira） */
.site-header .inner { display: flex; align-items: center; gap: 18px; padding: 6px 16px; }
.site-header .brand { flex: none; }
.site-header .brand b { font-size: 22px; }
.site-header .nav { margin-top: 0; flex: 1; min-width: 0; }
.site-header .nav a { padding: 8px 10px; border-bottom-width: 3px; }
@media (min-width: 1360px) {
  .play .coach { top: 66px; }
  .play .coach-info { max-height: calc(100vh - 82px); }
  .coach-chat { height: calc(100vh - 82px); }
}
.tbl-outer { width: min(100%, 720px, calc(100vh - 300px)); }
.rule-sec, .yaku { scroll-margin-top: 70px; }

/* ===== 振り返り（○○目線で見る） ===== */
.rp-btns { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 6px; margin: 4px 0 12px; font-size: 13px; font-weight: 800; color: var(--muted); }
.rp-btns .btn { padding: 5px 12px; font-size: 13px; }
.replay { position: fixed; inset: 0; z-index: 70; background: rgba(18, 10, 46, .6); display: grid; place-items: center; padding: 16px; }
.replay[hidden] { display: none; }
.rp-card { position: relative; width: min(760px, 100%); max-height: calc(100vh - 32px); overflow-y: auto; background: var(--paper); border: 3px solid var(--ink); border-radius: 18px; box-shadow: 6px 6px 0 var(--pink); padding: 14px 18px 24px; }
.rp-close { position: sticky; float: right; top: 0; right: 0; width: 40px; height: 40px; }
.rp-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 48px 10px 0; }
.rp-tab { display: inline-flex; align-items: center; gap: 4px; border: 2px solid var(--line); background: #fff; border-radius: 99px; padding: 3px 12px 3px 4px; font-weight: 800; font-size: 13px; cursor: pointer; }
.rp-tab img { width: 26px; height: 26px; border-radius: 50%; background: var(--night); }
.rp-tab.on { border-color: var(--ink); background: color-mix(in srgb, var(--c) 30%, #fff); }
.rp-head { border-bottom: 3px solid var(--c); padding-bottom: 8px; margin-bottom: 8px; }
.rp-kicker { font-family: var(--dot); color: var(--pink); font-size: 12px; }
.rp-head h2 { margin: 2px 0 6px; font-size: 26px; }
.rp-sec { background: #fff; border: 1.5px solid var(--line); border-radius: 14px; padding: 10px 14px; margin-top: 12px; }
.rp-sec h3 { font-size: 16px; margin: 0 0 8px; display: flex; align-items: center; gap: 8px; }
.rp-sec h3 .no { font-family: var(--dot); color: #fff; background: var(--ink); border-radius: 6px; padding: 0 8px; font-size: 12px; }
.rp-lines { margin: 6px 0 0; padding-left: 1.2em; font-size: 14px; line-height: 1.9; }
.rp-lines b { color: var(--pink); }
.rp-chart { width: 100%; max-width: 420px; height: auto; display: block; }
.rp-chart .gl { stroke: #eee; stroke-width: 1; } .rp-chart .gt { font-size: 10px; fill: var(--muted); }
.rp-turn { border-left: 4px solid var(--line); padding: 6px 0 8px 12px; margin: 8px 0; }
.rp-turn.hot { border-left-color: var(--pink); background: #fff3f9; border-radius: 0 10px 10px 0; }
.rp-turn.fold { border-left-color: var(--ok); }
.rp-t-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 13px; font-weight: 800; }
.rp-t-head .jun { font-family: var(--display); font-weight: 400; color: var(--pink); }
.rp-t-head .arrow { color: var(--muted); }
.rp-t-head .rch { font-style: normal; background: var(--pink); color: #fff; border-radius: 6px; padding: 0 6px; margin-left: 4px; }
.rp-hand { padding: 8px; margin: 6px 0; }
.rp-hand .tile.cut svg { filter: brightness(.7) drop-shadow(0 -3px 0 var(--ng)); }
.rp-hand .tile.cut { transform: translateY(-4px); }
.rp-think { margin: 4px 0 0; padding-left: 1.2em; font-size: 13.5px; line-height: 1.95; }
.rp-think b { color: var(--pink); }
.rp-ev { font-size: 13px; color: var(--muted); margin: 4px 0 4px 16px; }
.rp-ev.me { color: var(--ink); font-weight: 800; }
.rp-ev.warn { color: var(--ng); font-weight: 800; }
.rp-yaku { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 6px 0; }
.rp-yaku span { background: var(--yellow); border-radius: 6px; padding: 0 8px; font-weight: 800; font-size: 13px; }
.rp-yaku b { font-family: var(--display); font-weight: 400; font-size: 18px; color: var(--pink); margin-left: auto; }
.rp-other { background: #f6f2ff; border-radius: 10px; padding: 6px 10px; font-size: 13.5px; }
.rp-end p { line-height: 1.9; }

.rp-ev.riichi-run { color: var(--ink); background: #fff3f9; border-radius: 10px; padding: 6px 10px; margin-left: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; }


/* ===== スマホ（760px以下）: 2026-10-04 Aira「スマホのUIも整えて」 ===== */
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  main.wide { padding: 6px 6px 90px; }
  .site-header .inner { gap: 10px; padding: 4px 10px; }
  .site-header .brand small { display: none; }
  .site-header .brand b { font-size: 18px; }
  .site-header .nav a { padding: 8px 7px; font-size: 13px; }
  .tbl-outer { width: 100%; min-width: 0; }
  .tbl { border-radius: 14px; }
  /* 卓は約0.5倍に縮むので、文字は卓の座標で大きめにしておく */
  .bubble { width: 300px; font-size: 27px; border-width: 4px; padding: 8px 14px; }
  .av-1 .bubble { bottom: 40px; } .av-2 .bubble, .av-3 .bubble { top: 30px; }
  .avatar .nm { font-size: 20px; }
  .rtag { font-size: 22px; padding: 4px 12px; }
  .reads { max-width: 230px; }
  .rd-detail { width: 420px; font-size: 22px; }
  .center .sub, .center .left, .center .dora-lbl { font-size: 18px; }
  .center .rnd { font-size: 32px; }
  .seat .seat-label { font-size: 22px; }
  /* 手牌は画面いっぱい */
  .my-area { margin-top: 6px; }
  .my-hand { padding: 20px 4px 8px; border-radius: 12px; }
  .my-hand .tile.mine { width: calc((100vw - 34px) / 14.6) !important; }
  .my-bar { gap: 4px; min-height: 36px; }
  .my-status { font-size: 12px; flex-basis: 100%; }
  .snd { margin-left: 0; flex-wrap: wrap; }
  .sndbtn { padding: 3px 8px; font-size: 12px; }
  .sheetbtn { border-color: var(--ink); color: var(--ink); text-decoration: none; }
  .act { font-size: 15px; padding: 5px 12px; }
  .act-win { font-size: 20px; }
  .strip { margin-top: 6px; }
  .strip-row { padding: 6px 8px; gap: 6px; min-height: 0; }
  .strip-say { font-size: 13px; }
  .strip-say img { width: 36px; height: 36px; }
  .rec-tile { padding: 3px 8px 3px 4px; }
  /* コーチとチャットは下から出る引き出し */
  .play .coach-info, .play .coach-chat, .play.no-info .coach-info, .play.no-chat .coach-chat {
    display: flex; flex-direction: column; position: fixed !important; left: 0; right: 0; bottom: 0; top: auto !important;
    height: 74vh !important; max-height: none !important; z-index: 45; border-radius: 18px 18px 0 0; margin: 0;
    transform: translateY(105%); transition: transform .25s cubic-bezier(.2, .9, .3, 1); box-shadow: 0 -8px 24px rgba(0, 0, 0, .3);
  }
  .play .coach-info { overflow-y: auto !important; display: block; }
  .play.m-info .coach-info, .play.m-chat .coach-chat { transform: none; }
  /* 引き出しを開いている間は配牌が隠れないよう、手牌を画面の上に出して引き出しはその下まで（2026-10-07 Aira） */
  .play.m-info .my-hand, .play.m-chat .my-hand { position: fixed; top: 0; left: 0; right: 0; z-index: 46; margin: 0; border-radius: 0 0 12px 12px; padding-top: max(20px, env(safe-area-inset-top)); box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
  .play.m-info .coach-info, .play.m-chat .coach-chat { top: var(--mh, 84px) !important; height: auto !important; border-radius: 0; }
  .coach-head { position: sticky; top: -12px; background: #fff; z-index: 2; padding: 6px 0; }
  .side-close { font-size: 13px; padding: 4px 12px; }
  /* 配牌の印象は画面いっぱいに */
  .haipai-pop { position: fixed; z-index: 60; padding: 10px; background: rgba(18, 10, 46, .55); }
  .haipai-pop .hp-card.hp-v2 { width: 100%; max-width: 420px; max-height: calc(100vh - 20px); padding: 14px; gap: 8px 10px; }
  .hp-v2 .hp-ttl { font-size: 17px; }
  .hp-v2 .hp-grade-wrap { width: 76px; height: 66px; }
  .hp-v2 .hp-grade { font-size: 62px; -webkit-text-stroke: 3px var(--ink); text-shadow: 3px 3px 0 var(--gc); }
  .hp-v2 .speech.sm .say, .hp-v2 .hp-lines, .hp-v2 .hp-plan, .hp-v2 .hp-meter { font-size: 13px; }
  .hp-v2 .speech.sm img { width: 32px; height: 32px; }
  .hp-v2 .radar { width: 150px; max-height: 150px; }
  .hp-v2 .hm-num { font-size: 26px; }
  .hp-v2 .hm-legend { font-size: 10px; }
  .hp-v2 .hm-bar { height: 10px; }
  .hp-close { width: 36px; height: 36px; font-size: 18px; }
  /* 結果・振り返り */
  .result-card { padding: 12px; }
  .r-pts { font-size: 32px; }
  .replay { padding: 6px; }
  .rp-card { padding: 10px 10px 20px; max-height: calc(100vh - 12px); }
  .rp-head h2 { font-size: 21px; }
}
.tbl-outer { overflow: clip; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  .bubble { width: 240px; font-size: 25px; }
  .center .sub, .center .left { font-size: 15px; }
  .center .dora-lbl { font-size: 13px; }
  .center .rnd { font-size: 28px; }
  .seat .seat-label { font-size: 17px; }
}

/* ===== 対局は1画面に収める（PC。2026-10-05 Aira） ===== */
body.playing .footer { display: none; }
@media (min-width: 761px) and (orientation: portrait), (min-width: 761px) and (min-height: 501px), (min-width: 1080px) {
  body.playing main.wide { padding: 8px 16px 0; }
  body.playing .play-main { display: flex; flex-direction: column; align-items: center; gap: 8px; }
  body.playing .play-main > .strip, body.playing .play-main > .my-area { width: 100%; margin-top: 0; }
  body.playing .tbl-outer { margin: 0; }
  body.playing .my-hand { padding-top: 18px; padding-bottom: 6px; }
  body.playing .my-bar { min-height: 30px; }
  body.playing .strip-row { min-height: 0; padding: 4px 10px; }
  body.playing .strip-say { line-height: 1.75; }
  body.playing .strip-say img { width: 38px; height: 38px; }
  body.playing .rec-tile .tile-md { width: 30px; height: 40px; }
}
@media (min-width: 1360px) {
  body.playing .play .coach { position: sticky; top: 63px; }
  body.playing .play .coach-info { max-height: calc(100vh - 71px); overflow-y: auto; }
  body.playing .coach-chat { height: calc(100vh - 71px); }
}

/* 目指す役の方向性: ○の数で「あと何枚」・説明は折りたたみ（2026-10-05 Aira） */
.dir { cursor: default; border-radius: 8px; padding: 4px 6px; margin: 0 -6px 2px; }
.dir:hover, .dir.open { background: #faf5ff; }
.dir .dir-text { display: none; margin-top: 2px; }
.dir:hover .dir-text, .dir.open .dir-text, .dir:focus .dir-text { display: block; }
.dir .bar { display: none; }
.dir-need { margin-left: auto; display: inline-flex; align-items: center; gap: 6px; }
.pips { display: inline-flex; gap: 3px; }
.pips i { width: 11px; height: 11px; border-radius: 50%; border: 2px solid var(--pink); background: #fff; }
.pip-n { font-family: var(--display); font-size: 13px; color: var(--pink); }
.tp-badge { font-family: var(--display); font-size: 13px; background: var(--pink); color: #fff; border-radius: 6px; padding: 0 8px; }
.h-note { font-family: var(--body); font-weight: 800; font-size: 10px; color: var(--muted); margin-left: 6px; }

/* ===== パチンコ風リーチ演出 ===== */
.pachi { position: fixed; inset: 0; z-index: 80; pointer-events: none; overflow: hidden; --tc: #ff2e3e; --tc2: #ffe600; }
.pachi.t-blue { --tc: #2f7bff; --tc2: #9fd0ff; }
.pachi.t-green { --tc: #16c46b; --tc2: #c6ff3d; }
.pachi.t-red { --tc: #ff2e3e; --tc2: #ffe600; }
.pachi.t-gold { --tc: #ffb300; --tc2: #fff3a0; }
.pachi.t-rainbow { --tc: #ff2e88; --tc2: #22e6ff; }
.pc-dim { position: absolute; inset: 0; background: radial-gradient(circle, rgba(18, 10, 46, .55), rgba(5, 2, 15, .92)); animation: pcfade .25s both; }
.pc-frame { position: absolute; inset: 0; box-shadow: inset 0 0 0 10px var(--tc), inset 0 0 60px 20px var(--tc); animation: pcblink .12s steps(2) 0s 8; }
.t-rainbow .pc-frame { box-shadow: none; border: 12px solid transparent; border-image: linear-gradient(90deg, #ff2e88, #ffe600, #22e6ff, #c6ff3d, #b07bff, #ff2e88) 1; animation: pcblink .12s steps(2) 0s 8, pchue 1s linear infinite; }
.pc-yokoku { position: absolute; left: 50%; top: 42%; transform: translate(-50%, -50%); font-family: var(--display); font-size: min(30vw, 260px); color: #fff;
  -webkit-text-stroke: 8px var(--ink); paint-order: stroke fill; text-shadow: 0 0 30px var(--tc); animation: pcyokoku .5s cubic-bezier(.2, 1.8, .4, 1) both; }
.pc-lines { position: absolute; left: 50%; top: 50%; width: 260vmax; height: 260vmax; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, color-mix(in srgb, var(--tc) 85%, #fff) 0deg 2.2deg, transparent 2.2deg 9deg);
  -webkit-mask: radial-gradient(circle, transparent 0 9%, #000 18% 100%); mask: radial-gradient(circle, transparent 0 9%, #000 18% 100%);
  opacity: 0; animation: pclines 1.1s .42s linear both; }
.t-rainbow .pc-lines { background: repeating-conic-gradient(from 0deg, #ff2e88 0deg 2deg, transparent 2deg 6deg, #ffe600 6deg 8deg, transparent 8deg 12deg, #22e6ff 12deg 14deg, transparent 14deg 18deg); }
.pc-faces { position: absolute; left: 50%; bottom: 0; transform: translateX(-50%); display: flex; align-items: flex-end; justify-content: center; width: 100%; opacity: 0; animation: pczoom 1s .45s cubic-bezier(.3, 1.2, .5, 1) both; }
.pc-face { height: min(70vh, 640px); filter: drop-shadow(0 0 24px var(--tc)); -webkit-mask: linear-gradient(#000 70%, transparent); mask: linear-gradient(#000 70%, transparent); }
.pc-faces .pc-face.f1, .pc-faces .pc-face.f2 { margin-left: -12vw; }
.pc-faces:has(.f1) .pc-face { height: min(48vh, 440px); }
.pc-line { position: absolute; left: 50%; top: 18%; transform: translateX(-50%); white-space: nowrap; font-family: var(--display); font-size: min(7vw, 56px); color: #fff;
  -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--tc); opacity: 0; animation: pcline .6s .7s cubic-bezier(.2, 1.6, .4, 1) both; }
.pc-flash { position: absolute; inset: 0; background: #fff; opacity: 0; }
.pc-big { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%) scale(0); white-space: nowrap; font-family: var(--display); font-size: min(22vw, 220px); line-height: 1;
  color: var(--tc2); -webkit-text-stroke: 10px var(--ink); paint-order: stroke fill; text-shadow: 10px 10px 0 var(--tc), 0 0 50px var(--tc); opacity: 0; }
.t-rainbow .pc-big { background: linear-gradient(90deg, #ff2e88, #ffe600, #22e6ff, #c6ff3d, #b07bff, #ff2e88); background-size: 200% 100%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; animation: rainbow 1s linear infinite; }
.pc-tier { position: absolute; left: 50%; top: 72%; transform: translateX(-50%); text-align: center; font-family: var(--display); font-size: min(9vw, 72px); color: #fff;
  -webkit-text-stroke: 4px var(--ink); paint-order: stroke fill; text-shadow: 0 0 24px var(--tc); opacity: 0; }
.pc-tier small { display: block; font-family: var(--body); font-weight: 800; font-size: 20px; -webkit-text-stroke: 0; text-shadow: 0 2px 4px #000; }
.pachi.boom .pc-flash { animation: pcflash .55s ease-out both; }
.pachi.boom .pc-big { animation: pcbig .55s cubic-bezier(.2, 1.9, .4, 1) both; }
.pachi.boom .pc-tier { animation: pcline .5s .25s cubic-bezier(.2, 1.6, .4, 1) both; }
.pachi.boom .pc-faces, .pachi.boom .pc-line { animation: pcshake .45s both; opacity: 1; }
.pachi.boom .pc-lines { opacity: .9; animation: pcspin 2s linear infinite; }
.pachi.out { opacity: 0; transition: opacity .25s; }
@keyframes pcfade { from { opacity: 0; } to { opacity: 1; } }
@keyframes pcblink { 50% { opacity: .15; } }
@keyframes pchue { to { filter: hue-rotate(360deg); } }
@keyframes pcyokoku { 0% { transform: translate(-50%, -50%) scale(3); opacity: 0; } 40% { transform: translate(-50%, -50%) scale(.9); opacity: 1; } 80% { opacity: 1; } 100% { transform: translate(-50%, -50%) scale(1.1); opacity: 0; } }
@keyframes pclines { 0% { opacity: 0; transform: translate(-50%, -50%) rotate(0); } 15% { opacity: 1; } 100% { opacity: 1; transform: translate(-50%, -50%) rotate(140deg); } }
@keyframes pcspin { to { transform: translate(-50%, -50%) rotate(360deg); } }
@keyframes pczoom { 0% { opacity: 0; transform: translateX(-50%) scale(.25); } 70% { opacity: 1; transform: translateX(-50%) scale(1.06); }
  76% { transform: translateX(calc(-50% - 10px)) scale(1.06); } 82% { transform: translateX(calc(-50% + 10px)) scale(1.06); } 100% { opacity: 1; transform: translateX(-50%) scale(1); } }
@keyframes pcline { 0% { opacity: 0; transform: translateX(-50%) scale(2.2) rotate(-8deg); } 100% { opacity: 1; transform: translateX(-50%) scale(1) rotate(-4deg); } }
@keyframes pcflash { 0% { opacity: 1; } 100% { opacity: 0; } }
@keyframes pcbig { 0% { opacity: 0; transform: translate(-50%, -50%) scale(4) rotate(-14deg); } 60% { opacity: 1; transform: translate(-50%, -50%) scale(.9) rotate(-6deg); } 100% { opacity: 1; transform: translate(-50%, -50%) scale(1) rotate(-6deg); } }
@keyframes pcshake { 0%, 100% { translate: 0 0; } 15% { translate: -18px 10px; } 30% { translate: 16px -12px; } 45% { translate: -12px 6px; } 60% { translate: 9px -5px; } 80% { translate: -4px 2px; } }
@media (prefers-reduced-motion: reduce) { .pachi .pc-lines { animation: none; } .pachi .pc-faces, .pachi .pc-line { animation: none; opacity: 1; } }

/* 方向性の説明はスルッと開く（2026-10-05 Aira「アニメーション頼む」）＋完成形の例 */
.dir .dir-text { display: grid !important; grid-template-rows: 0fr; opacity: 0; transition: grid-template-rows .28s cubic-bezier(.2, .9, .3, 1), opacity .2s, margin .28s; margin-top: 0; }
.dir:hover .dir-text, .dir.open .dir-text, .dir:focus-within .dir-text { grid-template-rows: 1fr; opacity: 1; margin-top: 4px; }
.dir-inner { overflow: hidden; min-height: 0; }
.dir-ex { background: #f4fbf7; border-radius: 10px; padding: 6px 8px; margin: 6px 0; }
.ex-lbl { font-size: 11px; font-weight: 800; color: var(--ok); margin-bottom: 4px; }
.ex-tiles { display: flex; flex-wrap: wrap; gap: 1px; align-items: flex-end; }
.ex-tiles .tile { width: 22px; height: 29px; }
.tile.ex-add svg { filter: drop-shadow(0 0 0 #16c46b) drop-shadow(0 0 2.5px #16c46b) drop-shadow(0 0 2.5px #16c46b); }
.tile.ex-add { transform: translateY(-3px); }
.tile.ex-cut svg { filter: drop-shadow(0 0 2.5px var(--ng)) drop-shadow(0 0 2px var(--ng)); }
.ex-meld { font-size: 11px; color: var(--muted); margin-left: 6px; }
.ex-legend { display: flex; flex-wrap: wrap; gap: 4px 12px; align-items: center; margin-top: 4px; font-size: 11px; font-weight: 800; }
.lg-add { color: #0f9a52; }
.lg-cut { color: var(--ng); display: inline-flex; align-items: center; gap: 2px; flex-wrap: wrap; }

/* 悩んで決める場面の短い版 */
.pachi.think .pc-lines { animation-delay: 0s; animation-duration: .9s; }
.pachi.think .pc-faces { animation-delay: 0s; animation-duration: .8s; }
.pachi.think .pc-face { height: min(56vh, 520px); }
.pachi.think .pc-line { animation-delay: .2s; }
.pc-tilebig { display: flex; align-items: center; gap: 2vw; color: #fff; }
.pc-tilebig .pc-tile { width: min(20vw, 150px); height: auto; aspect-ratio: 60 / 80; filter: drop-shadow(0 0 30px var(--tc)) drop-shadow(0 10px 0 var(--ink)); transform: rotate(8deg); }
.pc-tilebig span { font-size: min(14vw, 130px); color: var(--tc2); }

.pc-dim { background: radial-gradient(circle, rgba(18, 10, 46, .72), rgba(5, 2, 15, .95)); }

/* 配牌の印象: 絵で見せる内訳（2026-10-05 Aira） */
.hp-hand { display: flex; flex-wrap: wrap; justify-content: center; gap: 2px; padding: 8px 6px 6px; background: linear-gradient(#17614a, #0f4a38); border-radius: 10px; }
.hp-hand .tile { width: max(22px, 4.6cqw); height: auto; aspect-ratio: 60 / 80; }
.hp-hand .tile.hp-dora svg { filter: drop-shadow(0 0 3px #ffcc00) drop-shadow(0 0 3px #ffcc00); }
.hp-hand .tile.hp-dora { transform: translateY(-4px); }
.hp-hand .tile.hp-yaku svg { filter: drop-shadow(0 0 3px var(--pink)) drop-shadow(0 0 2px var(--pink)); }
.hp-hand .tile.hp-weak { opacity: .45; transform: translateY(3px); }
.hp-legend { display: flex; flex-wrap: wrap; gap: 4px 10px; justify-content: center; margin: 4px 0 6px; font-size: 11px; font-weight: 800; color: var(--muted); }
.hp-legend .lg::before { content: ''; display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 4px; vertical-align: -1px; }
.hp-legend .lg-dora::before { background: #ffcc00; } .hp-legend .lg-yaku::before { background: var(--pink); } .hp-legend .lg-weak::before { background: #ccc; }
.hp-rows { display: grid; gap: 5px; }
.hp-row { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; font-size: 13px; }
.hp-row > b { width: 4em; flex: none; color: var(--pink); font-size: 12px; }
.hp-dora-chip, .hp-yaku-chip, .hp-near, .hp-none { display: inline-flex; align-items: center; gap: 3px; border-radius: 99px; padding: 2px 10px 2px 4px; font-weight: 800; font-size: 12px; }
.hp-dora-chip { background: #fff3c2; } .hp-yaku-chip { background: #ffe3f0; }
.hp-dora-chip .tile, .hp-yaku-chip .tile { width: 16px; height: 21px; }
.hp-none { background: #f0f0f0; color: var(--muted); padding: 2px 10px; }
.hp-near { background: #f3eaff; padding: 2px 10px; }
.hp-near .pips i { width: 8px; height: 8px; border-width: 1.5px; }
.hp-stance { display: inline-flex; border: 2px solid var(--ink); border-radius: 99px; overflow: hidden; }
.hp-stance i { font-style: normal; font-weight: 800; font-size: 12px; padding: 1px 10px; color: var(--muted); background: #fff; }
.hp-stance i + i { border-left: 2px solid var(--ink); }
.hp-stance i.on.attack { background: var(--pink); color: #fff; } .hp-stance i.on.normal { background: var(--yellow); color: var(--ink); } .hp-stance i.on.defend { background: #22b8e6; color: #fff; }
.hp-plan-s { font-size: 12.5px; font-weight: 800; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) { .hp-hand .tile { width: 22px; } .hp-row { font-size: 12px; } }

/* 配牌の印象は画面全体のポップアップ（PC・スマホ共通。cqw ではなく px で組む） */
body > .haipai-pop { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 12px; background: rgba(18, 10, 46, .55); }
body > .haipai-pop .hp-card.hp-v2 {
  width: min(760px, 100%); max-height: calc(100vh - 24px); overflow-y: auto; padding: 18px 22px;
  grid-template-columns: 1fr 1.1fr; grid-template-areas: "left right" "bottom bottom"; gap: 10px 20px; box-shadow: 8px 8px 0 var(--gc);
}
body > .haipai-pop .hp-v2 .hp-left { flex-direction: column; align-items: flex-start; }
body > .haipai-pop .hp-v2 .hp-ttl { font-size: 20px; padding-right: 40px; }
body > .haipai-pop .hp-v2 .hp-grade-wrap { width: 120px; height: 104px; }
body > .haipai-pop .hp-v2 .hp-grade { font-size: 100px; -webkit-text-stroke: 4px var(--ink); text-shadow: 5px 5px 0 var(--gc); }
body > .haipai-pop .hp-v2 .hp-rays { inset: -40px; }
body > .haipai-pop .hp-v2 .speech.sm .say { font-size: 14px; }
body > .haipai-pop .hp-v2 .speech.sm img { width: 40px; height: 40px; }
body > .haipai-pop .hp-v2 .hp-right { flex-direction: column; align-items: stretch; }
body > .haipai-pop .hp-v2 .radar { width: 210px; max-height: 210px; align-self: center; }
body > .haipai-pop .hp-v2 .hp-meter { font-size: 14px; }
body > .haipai-pop .hp-v2 .hm-num { font-size: 30px; }
body > .haipai-pop .hp-v2 .hm-legend { font-size: 11px; }
body > .haipai-pop .hp-v2 .hm-bar { height: 12px; }
body > .haipai-pop .hp-hand .tile { width: 34px; }
body > .haipai-pop .hp-close { top: 10px; right: 10px; width: 40px; height: 40px; font-size: 20px; }
@media (max-width: 640px) {
  body > .haipai-pop .hp-card.hp-v2 { grid-template-columns: 1fr; grid-template-areas: "left" "right" "bottom"; padding: 14px; }
  body > .haipai-pop .hp-v2 .hp-left { flex-direction: row; flex-wrap: wrap; align-items: center; }
  body > .haipai-pop .hp-v2 .hp-ttl { flex-basis: 100%; font-size: 17px; }
  body > .haipai-pop .hp-v2 .hp-grade-wrap { width: 76px; height: 66px; }
  body > .haipai-pop .hp-v2 .hp-grade { font-size: 62px; }
  body > .haipai-pop .hp-v2 .hp-right { flex-direction: row; align-items: center; }
  body > .haipai-pop .hp-v2 .radar { width: 150px; }
  body > .haipai-pop .hp-hand .tile { width: 22px; }
}

/* おすすめの打牌: 切る理由＋切った先の可能性（2026-10-05 Aira） */
.cand .why-wrap, .cand .future { grid-column: 1 / -1; }
.cand .f-lbl { display: block; font-size: 10px; font-weight: 800; color: var(--muted); letter-spacing: .05em; margin-top: 2px; }
.cand .future { display: flex; flex-wrap: wrap; gap: 3px 4px; align-items: center; margin: 2px 0 4px; }
.cand .future .f-lbl { flex-basis: 100%; }
.fut { display: inline-flex; align-items: center; gap: 4px; border-radius: 99px; padding: 1px 8px; font-size: 11px; font-weight: 800; background: #eefaf3; color: #0f7a45; }
.fut b { color: var(--ink); }
.fut .pips i { width: 7px; height: 7px; border-width: 1.5px; }
.fut em { font-style: normal; }
.fut.back { background: #fff0f0; color: var(--ng); }
.fut.lost { background: #f0f0f0; color: var(--muted); }

/* 配牌の印象 v3: 3段に詰める（2026-10-05 Aira「PCだと間延び」） */
body > .haipai-pop .hp-card.hp-v3 {
  position: relative; width: min(640px, 100%); max-height: calc(100vh - 24px); overflow-y: auto; background: #fff; border: 3px solid var(--ink); border-radius: 18px;
  padding: 16px 18px 14px; box-shadow: 8px 8px 0 var(--gc); display: grid; grid-template-columns: 200px 1fr; grid-template-areas: "head head" "radar info" "hand hand"; gap: 10px 16px; animation: slam2 .35s cubic-bezier(.3, 1.6, .5, 1);
}
.hp-v3 .hp-head { grid-area: head; display: flex; align-items: center; gap: 14px; padding-right: 44px; }
.hp-v3 .hp-grade-wrap { position: relative; width: 84px; height: 76px; flex: none; display: grid; place-items: center; }
.hp-v3 .hp-grade { position: relative; z-index: 1; font-family: var(--display); font-size: 72px; line-height: 1; color: #fff; -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--gc); transform: rotate(-6deg); animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both; }
.hp-v3.hp-card .hp-rays { inset: -30px; }
.g-S .hp-v3 .hp-grade { background: linear-gradient(135deg, #ff2e88, #ffe600, #22e6ff, #c6ff3d, #ff2e88); background-size: 300% 300%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both, rainbow 2s linear infinite; }
.hp-v3 .hp-headtext { flex: 1; min-width: 0; }
.hp-v3 .hp-ttl { font-family: var(--display); font-size: 18px; margin-bottom: 2px; }
.hp-v3 .speech.sm { margin: 0; }
.hp-v3 .speech.sm img { width: 36px; height: 36px; }
.hp-v3 .speech.sm .say { font-size: 13.5px; line-height: 1.7; }
.hp-v3 .hp-radar { grid-area: radar; display: grid; place-items: center; }
.hp-v3 .radar { width: 190px; max-height: 190px; }
.hp-v3 .hp-info { grid-area: info; display: flex; flex-direction: column; gap: 10px; justify-content: center; min-width: 0; }
.hp-v3 .hp-meter { font-size: 13px; }
.hp-v3 .hm-num { font-size: 26px; }
.hp-v3 .hm-bar { height: 10px; }
.hp-v3 .hm-legend { font-size: 10.5px; }
.hp-v3 .hp-plan-s { font-size: 12.5px; font-weight: 800; padding-left: calc(4em + 6px); color: var(--ink); }
.hp-v3 .hp-handwrap { grid-area: hand; }
.hp-v3 .hp-hand .tile { width: 32px; }
body > .haipai-pop .hp-v3 .hp-close { top: 10px; right: 10px; width: 38px; height: 38px; font-size: 18px; }
@media (max-width: 560px) {
  body > .haipai-pop .hp-card.hp-v3 { grid-template-columns: 1fr; grid-template-areas: "head" "radar" "info" "hand"; padding: 12px; }
  .hp-v3 .radar { width: 160px; }
  .hp-v3 .hp-hand .tile { width: 22px; }
  .hp-v3 .hp-plan-s { padding-left: 0; }
}
.hp-v3 .hp-grade { width: auto; }
.hp-v3 .radar .rl { font-size: 16px; }
.hp-v3 .radar .rv { font-size: 13px; }

/* おすすめの打牌 v2: 記号と短い札で直感的に。タップで文章（2026-10-05 Aira） */
.cand.v2 { display: block; padding: 8px 10px; cursor: pointer; }
.cv-top { display: flex; align-items: center; gap: 10px; }
.cv-top > .tile { flex: none; }
.cv-main { flex: 1; min-width: 0; }
.cv-name { display: flex; align-items: baseline; gap: 6px; }
.cv-name b { font-size: 16px; }
.cv-name .rd { font-size: 11px; }
.cv-name .stars { margin-left: auto; font-size: 14px; }
.cv-metrics { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 2px; align-items: center; }
.cv-m { display: inline-flex; align-items: center; gap: 5px; font-size: 12px; }
.cv-m > small { font-size: 10px; font-weight: 800; color: var(--muted); }
.cv-uk b { font-family: var(--display); font-weight: 400; font-size: 14px; color: var(--ink); }
.ukbar { display: inline-block; width: 70px; height: 8px; border-radius: 99px; background: #eee; overflow: hidden; }
.ukbar i { display: block; height: 100%; border-radius: 99px; background: linear-gradient(90deg, var(--cyan), #16c46b); }
.cv-cut { flex: none; border: 2px solid var(--ink); background: var(--yellow); border-radius: 10px; padding: 4px 12px; font-weight: 800; font-size: 13px; cursor: pointer; box-shadow: 2px 2px 0 var(--ink); }
.cv-cut:active { transform: translate(1px, 1px); box-shadow: 1px 1px 0 var(--ink); }
.cv-tags, .cv-fut { display: flex; flex-wrap: wrap; gap: 3px 4px; margin-top: 6px; align-items: center; }
.cv-fut > small { font-size: 10px; font-weight: 800; color: var(--muted); margin-right: 2px; }
.tg { font-size: 11px; font-weight: 800; border-radius: 6px; padding: 1px 7px; background: #f2f2f2; color: #555; }
.tg.g { background: #e3f8ec; color: #0f7a45; } .tg.b { background: #ffe5e5; color: var(--ng); } .tg.w { background: #fff4d6; color: #a06000; }
.fm { font-size: 11px; font-weight: 800; border-radius: 99px; padding: 1px 8px; }
.fm.keep { background: #e3f8ec; color: #0f7a45; } .fm.back { background: #ffe5e5; color: var(--ng); } .fm.lost { background: #eee; color: #999; text-decoration: line-through; }
.cv-detail { display: grid; grid-template-rows: 0fr; opacity: 0; transition: grid-template-rows .28s cubic-bezier(.2, .9, .3, 1), opacity .2s; }
.cand.v2.open .cv-detail { grid-template-rows: 1fr; opacity: 1; margin-top: 6px; }
.cv-inner { overflow: hidden; min-height: 0; border-top: 1px dashed var(--line); }
.cand.v2.open { box-shadow: 3px 3px 0 var(--pink); }
.cv-legend { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 2px; }

/* 配牌の印象: ? の解説・近い役の説明・As-Is → To-Be（2026-10-05 Aira） */
.qhelp { position: relative; display: inline-grid; place-items: center; width: 16px; height: 16px; border-radius: 50%; background: var(--ink); color: #fff; font-size: 11px; font-weight: 800; cursor: help; vertical-align: 1px; margin-left: 2px; font-family: var(--body); }
.qtip { display: none; position: absolute; z-index: 5; left: 50%; top: calc(100% + 8px); transform: translateX(-50%); width: 280px; background: var(--night); color: #fff; border-radius: 10px; padding: 8px 10px;
  font-size: 12px; font-weight: 500; line-height: 1.7; text-align: left; box-shadow: 0 6px 18px rgba(0, 0, 0, .3); white-space: normal; letter-spacing: 0; }
.qtip b { color: var(--yellow); }
.qtip small { color: var(--cyan); }
.qtip rt { color: var(--yellow); }
@media (hover: hover) { .qhelp:hover .qtip, .hp-near:hover .qtip { display: block; } }
.qhelp.open .qtip { display: block; }
.hp-near { position: relative; border: 2px solid transparent; cursor: pointer; font: inherit; font-weight: 800; font-size: 12px; }
.hp-near:hover { border-color: #b07bff; }
.hp-near.on { border-color: var(--ink); background: #e9dcff; }
.hp-near .qtip { font-weight: 500; }
.hp-simbox { display: grid; grid-template-rows: 0fr; opacity: 0; transition: grid-template-rows .3s cubic-bezier(.2, .9, .3, 1), opacity .2s; }
.hp-simbox.open { grid-template-rows: 1fr; opacity: 1; }
.hp-simbox .sim-inner { overflow: hidden; min-height: 0; }
.sim { background: #f8f4ff; border: 2px dashed #b07bff; border-radius: 12px; padding: 8px 10px; margin: 2px 0 4px; }
.sim-row { display: flex; align-items: center; gap: 8px; }
.sim-lbl { flex: none; width: 66px; font-weight: 800; font-size: 12px; color: var(--ng); line-height: 1.2; }
.sim-lbl.to { color: #0f9a52; }
.sim-lbl small { display: block; font-family: var(--dot); font-size: 10px; color: var(--muted); }
.sim-tiles { display: flex; flex-wrap: wrap; gap: 1px; }
.sim-tiles .tile { width: 26px; height: 35px; }
.sim-arrow { font-size: 11px; font-weight: 800; color: var(--muted); padding: 2px 0 2px 74px; }
.sim-cap { margin: 6px 0 0; font-size: 12.5px; font-weight: 800; }
.sim-cap .tref .tile { width: 15px; height: 20px; }

body > .haipai-pop .hp-card.hp-v3 { grid-template-areas: "head head" "radar info" "sim sim" "hand hand"; }
.hp-v3 .hp-simbox { grid-area: sim; }
.hp-v3 .hp-simbox:not(.open) { margin-top: -10px; }
@media (max-width: 560px) { body > .haipai-pop .hp-card.hp-v3 { grid-template-areas: "head" "radar" "info" "sim" "hand"; } .sim-tiles .tile { width: 21px; height: 28px; } .sim-lbl { width: 52px; } .sim-arrow { padding-left: 60px; } }

.hp-v3 .hp-row > b { width: 5.4em; white-space: nowrap; }
.hp-v3 .hp-plan-s { padding-left: calc(5.4em + 6px); }

/* 打牌候補の簡易解説（ホバー／タップ） */
.hastip { position: relative; cursor: help; text-decoration: underline dotted rgba(0, 0, 0, .35) 1.5px; text-underline-offset: 2px; }
.hastip .qtip { left: 0; transform: none; width: 250px; top: calc(100% + 6px); z-index: 20; }
@media (hover: hover) { .hastip:hover > .qtip { display: block; } }
.hastip.open > .qtip { display: block; }
.coach-info { overflow-x: visible; }
.cv-fut .hastip:nth-last-child(-n+2) .qtip, .cv-tags .hastip:nth-last-child(-n+2) .qtip { left: auto; right: 0; }

/* ワンチャン狙い（2026-10-05 Aira） */
.longshots h4 { color: #b06a00; }
.dir.longshot { background: linear-gradient(90deg, #fff8e1, #fff); }
.dir.longshot .dir-head b { color: #b06a00; }
.ls-han { background: var(--yellow); border-radius: 6px; padding: 0 6px; color: var(--ink) !important; font-weight: 800; }
.hp-near.ls { background: linear-gradient(90deg, #fff1b8, #ffe0f0); }
.ls-mark { font-style: normal; font-size: 9px; font-weight: 800; background: var(--pink); color: #fff; border-radius: 4px; padding: 0 4px; margin-right: 4px; }

/* 「○○を切ると」の吹き出し（手牌の上） */
.hand-pop { position: fixed; z-index: 48; min-width: 200px; max-width: 300px; background: #fff; border: 2.5px solid var(--ink); border-radius: 12px; padding: 7px 10px; box-shadow: 4px 4px 0 var(--cyan);
  font-size: 12px; pointer-events: none; animation: pop .15s; }
.hand-pop::after { content: ''; position: absolute; left: var(--ax, 50%); bottom: -9px; width: 14px; height: 14px; margin-left: -7px; background: #fff; border-right: 2.5px solid var(--ink); border-bottom: 2.5px solid var(--ink); transform: rotate(45deg); }
.hand-pop .hp-ttl2 { font-weight: 800; font-size: 13px; margin-bottom: 2px; }
.hand-pop .hp-line { display: flex; flex-wrap: wrap; align-items: center; gap: 3px 6px; margin-top: 3px; }
.hand-pop small { font-size: 10px; font-weight: 800; color: var(--muted); }
.hand-pop .uk { font-family: var(--display); font-weight: 400; font-size: 14px; }
.hand-pop .pips i { width: 9px; height: 9px; }

/* 解説の吹き出しは1つの共通の吹き出しで出す（CSSの .qtip 自体は表示しない） */
.qtip { display: none !important; }
.tip-pop { position: fixed; z-index: 90; background: var(--night); color: #fff; border-radius: 10px; padding: 8px 11px; font-size: 12.5px; line-height: 1.75;
  box-shadow: 0 6px 18px rgba(0, 0, 0, .3); pointer-events: none; animation: pop .12s; }
.tip-pop[hidden] { display: none; }
.tip-pop b { color: var(--yellow); } .tip-pop small { color: var(--cyan); } .tip-pop rt { color: var(--yellow); }
.tip-pop .tref .tile { width: 15px; height: 20px; }

.bubble.still { animation: none; }

/* 解説の吹き出し: 要点1行＋箇条書き＋例 */
.tip-pop .t-lead { font-weight: 800; font-size: 13px; color: var(--yellow); padding-bottom: 4px; margin-bottom: 4px; border-bottom: 1px solid rgba(255, 255, 255, .2); }
.tip-pop .t-pts { margin: 0; padding-left: 1.1em; }
.tip-pop .t-pts li { margin: 1px 0; }
.tip-pop .t-pts li::marker { color: var(--pink); }
.tip-pop .t-pts b { color: var(--cyan); }
.tip-pop .t-ex { margin-top: 5px; background: rgba(255, 255, 255, .1); border-radius: 6px; padding: 3px 7px; font-size: 11.5px; }

/* 牌が置かれた瞬間にピカッと光る（2026-10-05 Aira「牌も置かれた瞬間ビッて光るとか」） */
.tile.pop svg, .tile.pop-rot svg { animation: tileflash .45s ease-out both; }
@keyframes tileflash { 0%, 30% { filter: brightness(2.4) drop-shadow(0 0 8px #fff) drop-shadow(0 0 4px var(--yellow)); } 100% { filter: drop-shadow(0 0 4px var(--yellow)) drop-shadow(0 0 2px var(--yellow)); } }
/* ドラ切り「ドバーン！」 */
.dfx.dora .dburst { position: absolute; left: 0; top: 0; width: 120cqw; height: 120cqw; transform: translate(-50%, -50%);
  background: repeating-conic-gradient(from 0deg, rgba(255, 204, 0, .9) 0deg 5deg, transparent 5deg 14deg);
  -webkit-mask: radial-gradient(circle, transparent 0 4%, #000 8% 26%, transparent 52%); mask: radial-gradient(circle, transparent 0 4%, #000 8% 26%, transparent 52%);
  animation: dburst 1.2s ease-out forwards; }
.dfx.dora .ring { border-color: #ffcc00; box-shadow: 0 0 3cqw #ffcc00, inset 0 0 1.5cqw #fff; width: 18cqw; height: 18cqw; margin: -9cqw 0 0 -9cqw; }
.dfx.dora .ring.r3 { animation-delay: .16s; border-width: .5cqw; }
.dfx.dora .sparks i { background: linear-gradient(90deg, #fff, #ffcc00 40%, transparent); width: 11cqw; height: 1.1cqw; }
.dfx em.doban { font-size: 13cqw; top: -17cqw; color: #ffe600; -webkit-text-stroke: 1.1cqw var(--ink); text-shadow: 1cqw 1cqw 0 #ff2e88, 0 0 4cqw #ffcc00; animation: dword 1.2s cubic-bezier(.2, 1.8, .4, 1) forwards; }
.dfx .dsub { position: absolute; left: 0; top: -4cqw; transform: translateX(-50%); white-space: nowrap; font-family: var(--display); font-weight: 400; font-size: 5cqw; color: #fff;
  -webkit-text-stroke: .6cqw var(--ink); paint-order: stroke fill; animation: dword 1.2s .12s cubic-bezier(.2, 1.8, .4, 1) both; }
@keyframes dburst { 0% { opacity: 0; transform: translate(-50%, -50%) rotate(0) scale(.3); } 20% { opacity: 1; } 100% { opacity: 0; transform: translate(-50%, -50%) rotate(50deg) scale(1.2); } }
.dfx .dsub { top: 2cqw; }

/* 配牌の印象: 下に「この配牌で対局開始！」 */
body > .haipai-pop .hp-card.hp-v3 { grid-template-areas: "head head" "radar info" "sim sim" "hand hand" "go go"; }
.hp-v3 .hp-head { padding-right: 0; }
.hp-v3 .hp-go { grid-area: go; display: flex; justify-content: center; }
.hp-start { font-family: var(--display); font-weight: 400; font-size: 18px; padding: 10px 28px; animation: glowstart 1.2s ease-in-out infinite alternate; }
@keyframes glowstart { from { box-shadow: 3px 3px 0 var(--ink), 0 0 0 0 rgba(255, 46, 136, .5); } to { box-shadow: 3px 3px 0 var(--ink), 0 0 0 10px rgba(255, 46, 136, 0); } }
@media (max-width: 560px) { body > .haipai-pop .hp-card.hp-v3 { grid-template-areas: "head" "radar" "info" "sim" "hand" "go"; } .hp-start { width: 100%; } }

/* 配牌の印象 v4: 上から順に確認する5つの手順（2026-10-05 Aira） */
body > .haipai-pop .hp-card.hp-v4 { position: relative; width: min(620px, 100%); max-height: calc(100vh - 24px); overflow-y: auto; background: #fff; border: 3px solid var(--ink); border-radius: 18px;
  padding: 14px 18px; box-shadow: 8px 8px 0 var(--gc); animation: slam2 .35s cubic-bezier(.3, 1.6, .5, 1); }
.hp-v4 .hp-head { display: flex; align-items: center; gap: 12px; }
.hp-v4 .hp-grade-wrap { position: relative; width: 78px; height: 70px; flex: none; display: grid; place-items: center; }
.hp-v4 .hp-grade { position: relative; z-index: 1; width: auto; font-family: var(--display); font-size: 66px; line-height: 1; color: #fff; -webkit-text-stroke: 3px var(--ink); paint-order: stroke fill; text-shadow: 4px 4px 0 var(--gc); transform: rotate(-6deg); animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both; }
.g-S .hp-v4 .hp-grade { background: linear-gradient(135deg, #ff2e88, #ffe600, #22e6ff, #c6ff3d, #ff2e88); background-size: 300% 300%; -webkit-background-clip: text; background-clip: text; color: transparent; text-shadow: none; animation: hpslam .5s cubic-bezier(.2, 1.8, .4, 1) both, rainbow 2s linear infinite; }
.hp-v4 .hp-rays { position: absolute; inset: -28px; }
.hp-v4 .hp-headtext { flex: 1; min-width: 0; }
.hp-v4 .hp-ttl { font-family: var(--display); font-size: 17px; margin-bottom: 3px; }
.hp-v4 .hp-ttl small { font-family: var(--body); font-weight: 800; font-size: 11px; color: var(--pink); margin-left: 6px; }
.hp-v4 .speech.sm { margin: 0; } .hp-v4 .speech.sm img { width: 34px; height: 34px; } .hp-v4 .speech.sm .say { font-size: 13px; line-height: 1.6; }
.hp-v4 .hp-radar { flex: none; width: 130px; }
.hp-v4 .radar { width: 130px; max-height: 130px; }
.hp-v4 .radar .rl { font-size: 15px; } .hp-v4 .radar .rv { font-size: 12px; }
.hp-steps { list-style: none; margin: 10px 0 0; padding: 0; display: grid; gap: 6px; }
.hp-step { display: grid; grid-template-columns: 28px 1fr; gap: 10px; align-items: start; padding: 8px 10px; border: 2px solid var(--line); border-radius: 12px; background: #fff;
  opacity: 0; transform: translateY(8px); animation: stepin .35s var(--d, 0s) cubic-bezier(.2, 1.2, .4, 1) forwards; }
@keyframes stepin { to { opacity: 1; transform: none; } }
.st-no { width: 26px; height: 26px; border-radius: 50%; background: var(--gc); color: #fff; display: grid; place-items: center; font-family: var(--display); font-size: 14px; box-shadow: 2px 2px 0 var(--ink); }
.st-q { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 4px; }
.st-q b { font-family: var(--display); font-weight: 400; font-size: 15px; }
.st-q span:not(.qhelp) { font-size: 12px; font-weight: 800; color: var(--muted); }
.st-a .hp-row > b { display: none; }
.hp-v4 .hp-hand .tile { width: 30px; }
.hp-v4 .hp-legend { justify-content: flex-start; margin: 4px 0 0; }
.hp-v4 .hp-meter { font-size: 13px; }
.hp-v4 .hm-head { justify-content: flex-start; gap: 10px; align-items: baseline; }
.hp-v4 .hm-num { font-size: 24px; }
.hm-judge { font-weight: 800; font-size: 13px; color: var(--gc); }
.hp-v4 .hm-bar { height: 9px; }
.hp-v4 .hm-legend { font-size: 10.5px; }
.hp-v4 .hp-plan-s { padding-left: 0; font-size: 12.5px; }
.hp-v4 .hp-go { display: flex; justify-content: center; margin-top: 12px; opacity: 0; animation: stepin .35s 1.2s forwards; }
@media (max-width: 560px) {
  .hp-v4 .hp-head { flex-wrap: wrap; } .hp-v4 .hp-radar { width: 100%; display: grid; place-items: center; }
  .hp-v4 .hp-hand .tile { width: 21px; } .hp-start { width: 100%; }
}
/* v4: 古い版の flex / grid 指定を打ち消し、各手順は「問い｜答え」の横並びで1画面に収める */
body > .haipai-pop .hp-card.hp-v4 { display: block; }
.hp-v4 .st-body { display: grid; grid-template-columns: 128px 1fr; gap: 10px; align-items: center; min-width: 0; }
.hp-v4 .st-q { flex-direction: column; align-items: flex-start; gap: 1px; margin: 0; }
.hp-v4 .st-q span:not(.qhelp) { font-size: 11px; line-height: 1.4; }
.hp-v4 .st-q .qhelp { margin: 0; }
.hp-v4 .st-q b { display: inline-flex; align-items: center; gap: 4px; }
.hp-v4 .st-a { min-width: 0; }
.hp-v4 .st-a .hp-row { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 6px; align-items: center; }
.hp-v4 .hp-step { padding: 7px 10px; align-items: center; }
.hp-v4 .hp-hand { justify-content: flex-start; padding: 6px; }
.hp-v4 .hp-simbox { grid-column: 1 / -1; }
@media (max-width: 560px) {
  .hp-v4 .st-body { grid-template-columns: 1fr; gap: 4px; }
  .hp-v4 .st-q { flex-direction: row; align-items: baseline; gap: 6px; }
}
body > .haipai-pop .hp-v4 .hp-hand { flex-wrap: nowrap; gap: 1px; }
body > .haipai-pop .hp-v4 .hp-hand .tile { width: auto; flex: 1 1 0; min-width: 0; max-width: 32px; }
/* 手牌の上の帯: 目指す役の札（2026-10-05 Aira） */
.strip-dirs { display: flex; align-items: center; gap: 6px; flex: 1; min-width: 0; flex-wrap: wrap; }
.strip-dirs > small { font-family: var(--display); font-size: 12px; color: var(--pink); margin-right: 2px; }
.sd { display: inline-flex; flex-direction: column; align-items: flex-start; gap: 1px; border: 2px solid var(--line); background: #fff; border-radius: 10px; padding: 4px 10px; cursor: pointer; font: inherit; font-weight: 800; font-size: 13px; line-height: 1.2; transition: transform .12s, border-color .12s; }
.sd:hover { border-color: #b07bff; transform: translateY(-1px); }
.sd.on { border-color: var(--ink); background: #ffe9f4; box-shadow: 2px 2px 0 var(--pink); }
.sd-sub { font-size: 10px; color: var(--muted); font-weight: 800; }
.sd .pips { display: inline-flex; gap: 2px; }
.sd .pips i { width: 7px; height: 7px; border-radius: 50%; border: 1.5px solid #b07bff; display: block; }
.sd-none { font-size: 12px; color: var(--muted); font-weight: 800; }
/* 帯: 選んだ役の完成形の例（2段目） */
.strip-row { flex-wrap: wrap; }
.strip-ex { flex: 1 0 100%; min-width: 0; }
.strip-ex .dir-ex { margin: 0; padding: 5px 8px; }
.strip-ex .ex-lbl { display: flex; align-items: center; gap: 4px; }
.strip-ex .ex-tiles .tile { width: 26px; height: 35px; }
/* データとアドバイスの一番上: 目指す役のカード（2026-10-05 Aira） */
#coach-top .target-card { border: 2px solid var(--ink); border-radius: 14px; padding: 10px 12px; box-shadow: 3px 3px 0 var(--pink); background: #fff; margin: 0 0 10px; }
#coach-top .target-card h4 { margin: 0 0 6px; }
#coach-top .target-card .strip-dirs > small { display: none; }
#coach-top .tc-rec { display: flex; justify-content: flex-end; margin-top: 8px; }
#coach-top .strip-ex { margin-top: 8px; }
#coach-top .strip-ex .ex-tiles .tile { width: 24px; height: 32px; }
.strip-say .sa-yaku { font-style: normal; font-weight: 800; color: var(--pink); }
/* ===== 列は「隠す」ではなく「たたむ」: 細い帯になって、押すと開く（2026-10-05 Aira） ===== */
.side-close .sc-open { display: none; }
.play-settings { display: flex; flex-wrap: wrap; gap: 4px; padding-top: 8px; margin-top: 8px; border-top: 1px dashed var(--line); }
.play-settings .sndbtn { padding: 3px 10px; font-size: 12px; }
@media (min-width: 761px) and (orientation: portrait), (min-width: 761px) and (min-height: 501px), (min-width: 1080px) {
  .play.no-info .coach-info, .play.no-chat .coach-chat { display: block; }
  .play.no-info .coach-info > :not(.coach-head), .play.no-chat .coach-chat > :not(.coach-head):not(.play-settings) { display: none !important; }
  .play.no-info .coach-info .sc-fold, .play.no-chat .coach-chat .sc-fold { display: none; }
  .play.no-info .coach-info .sc-open, .play.no-chat .coach-chat .sc-open { display: inline; }
  .play.no-info .coach-info, .play.no-chat .coach-chat { cursor: pointer; height: auto; }
  .play.no-info .coach-info:hover, .play.no-chat .coach-chat:hover { background: #fff8fc; }
  .play.no-chat .coach-chat .play-settings { border-top: 0; margin-top: 0; }
  .play.no-info .coach-info .coach-head, .play.no-chat .coach-chat .coach-head { margin: 0; }
}
@media (min-width: 761px) and (max-width: 1079px) and (orientation: portrait), (min-width: 761px) and (max-width: 1079px) and (min-height: 501px) {
  .play.no-info, .play.no-chat, .play.no-info.no-chat { grid-template-areas: "main" "info" "chat"; }
}
@media (min-width: 1080px) and (max-width: 1359px) {
  .play.no-info, .play.no-chat, .play.no-info.no-chat { grid-template-columns: minmax(460px, 1.15fr) minmax(340px, 1fr); grid-template-areas: "main info" "main chat"; }
  .play.no-info.no-chat .play-main { max-width: none; }
}
@media (min-width: 1360px) {
  .play.no-info { grid-template-columns: minmax(460px, 1.6fr) 52px minmax(300px, .8fr); grid-template-areas: "main info chat"; }
  .play.no-chat { grid-template-columns: minmax(460px, 1.4fr) minmax(340px, 1fr) 52px; grid-template-areas: "main info chat"; }
  .play.no-info.no-chat { grid-template-columns: minmax(0, 1fr) 52px 52px; grid-template-areas: "main info chat"; }
  .play.no-info.no-chat .play-main { max-width: none; }
  /* たたんだ列は縦書きの細い帯 */
  .play.no-info .coach-info, .play.no-chat .coach-chat { height: calc(100vh - 112px); padding: 12px 4px; display: flex; flex-direction: column; align-items: center; gap: 10px; overflow: hidden; }
  .play.no-info .coach-info .coach-head, .play.no-chat .coach-chat .coach-head { writing-mode: vertical-rl; flex-direction: row; justify-content: flex-start; align-items: center; gap: 10px; font-size: 14px; }
  .play.no-info .coach-info .side-close, .play.no-chat .coach-chat .side-close { writing-mode: vertical-rl; padding: 8px 2px; }
  .play.no-chat .coach-chat .play-settings { flex-direction: column; margin-top: auto; padding: 0; }
  .play.no-chat .coach-chat .play-settings .sndbtn { padding: 4px 2px; font-size: 11px; writing-mode: vertical-rl; }
}
#coach-top .tc-body { display: flex; align-items: center; gap: 10px; }
#coach-top .tc-body .strip-dirs { flex: 1; }
#coach-top .tc-body .rec-tile { margin-left: auto; }
@media (min-width: 1360px) { .play.no-info.no-chat .play-main { max-width: 860px; margin: 0 auto; width: 100%; } }
/* ===== たたむ／開くアニメーション（2026-10-05 Aira「畳むときアニメーションが欲しい」） =====
   列の幅を登録済みの変数（長さ）にして、変数ごと transition させる（grid の列幅がなめらかに変わる） */
@property --wi { syntax: '<length>'; inherits: true; initial-value: 0px; }
@property --wc { syntax: '<length>'; inherits: true; initial-value: 0px; }
@media (min-width: 1360px) {
  .play, .play.no-info, .play.no-chat, .play.no-info.no-chat {
    --wi: 29vw; --wc: 25vw;
    grid-template-columns: minmax(420px, 1fr) var(--wi) var(--wc); grid-template-areas: "main info chat";
    transition: --wi .4s cubic-bezier(.3, 1.2, .4, 1), --wc .4s cubic-bezier(.3, 1.2, .4, 1);
  }
  .play.no-info { --wi: 52px; }
  .play.no-chat { --wc: 52px; }
  .play .coach { min-width: 0; }
}
@keyframes colIn { from { opacity: 0; transform: translateX(18px); } to { opacity: 1; transform: none; } }
@keyframes railIn { from { opacity: 0; transform: translateY(-10px) scale(.9); } to { opacity: 1; transform: none; } }
@media (min-width: 761px) and (orientation: portrait), (min-width: 761px) and (min-height: 501px), (min-width: 1080px) {
  /* 開いたとき: 中身が少し遅れてふわっと入る（たたんでいる間は display:none なので、開くたびに再生される） */
  .play .coach-info > :not(.coach-head), .play .coach-chat > :not(.coach-head) { animation: colIn .35s .15s cubic-bezier(.2, .9, .3, 1) both; }
  /* たたんだとき: 縦書きの帯が出てくる */
  .play.no-info .coach-info .coach-head, .play.no-chat .coach-chat .coach-head { animation: railIn .35s .1s cubic-bezier(.2, 1.4, .4, 1) both; }
  .play.no-chat .coach-chat .play-settings { animation: railIn .35s .18s cubic-bezier(.2, 1.4, .4, 1) both; }
}
/* データとアドバイスのメニュー（2026-10-05 Aira「目指す役・おすすめの打牌 ／ 配牌の印象 ／ 方針 を切り替えて確認」） */
.coach-tabs { display: flex; gap: 4px; margin: 0 0 10px; border-bottom: 2px solid var(--ink); }
.ctab { flex: 1 1 auto; border: 2px solid var(--ink); border-bottom: 0; background: #f6f1ff; border-radius: 10px 10px 0 0; padding: 6px 8px; font: inherit; font-weight: 800; font-size: 12px; cursor: pointer; color: var(--muted); margin-bottom: -2px; line-height: 1.3; }
.ctab:hover { color: var(--ink); background: #fff; }
.ctab.on { background: #fff; color: var(--pink); border-bottom: 2px solid #fff; }
.coach-info:not([data-ctab="play"]) #coach-top { display: none; }
/* 列の中の配牌の印象（モーダルと同じ中身。毎巡描き直すのでアニメーションはしない） */
.hp-card.hp-v4.hp-inline { position: static; width: auto; max-height: none; overflow: visible; border: 0; box-shadow: none; padding: 0; animation: none; background: transparent; }
.hp-inline .hp-step, .hp-inline .hp-grade { animation: none !important; opacity: 1; transform: none; }
.hp-inline .hp-grade { transform: rotate(-6deg); font-size: 52px; }
.hp-inline .hp-grade-wrap { width: 60px; height: 56px; }
.hp-inline .hp-radar, .hp-inline .radar { width: 110px; }
.hp-inline .hp-head { flex-wrap: wrap; }
.hp-inline .hp-headtext { flex: 1 1 160px; }
.hp-inline .st-body { grid-template-columns: 92px 1fr; gap: 8px; }
.hp-inline .hp-step { padding: 6px 8px; gap: 8px; grid-template-columns: 24px 1fr; }
.hp-inline .st-no { width: 22px; height: 22px; font-size: 12px; }
.hp-inline .hp-hand { flex-wrap: wrap; }
.hp-inline .hp-hand .tile { width: 22px !important; flex: none !important; }
.hp-card.hp-v4.hp-inline { display: block; }
#coach > .hp-inline { grid-column: 1 / -1; }
/* タブはカードの外（上）。フォルダのつまみのように、選んだタブとカードがつながって見える（2026-10-05 Aira） */
.info-col { grid-area: info; min-width: 0; display: flex; flex-direction: column; }
.info-col > .coach-tabs { display: flex; gap: 4px; margin: 0 0 -2px; padding: 0 10px; border: 0; position: relative; z-index: 2; }
.info-col > .coach-tabs .ctab { border: 2px solid var(--ink); border-bottom: 0; border-radius: 12px 12px 0 0; background: #ece4ff; padding: 7px 10px 6px; margin: 0; font-size: 12px; }
.info-col > .coach-tabs .ctab.on { background: #fff; color: var(--pink); padding-bottom: 8px; box-shadow: 0 2px 0 #fff; }
.info-col > .coach-tabs .ctab:not(.on):hover { background: #f6f1ff; }
.info-col > .coach-info { border-top-left-radius: 0; flex: 1 1 auto; min-height: 0; }
.coach-tabs.m-only { display: none; }
.play.no-info .info-col > .coach-tabs { display: none; }
.play.no-info .info-col > .coach-info { border-top-left-radius: var(--radius); }
@media (min-width: 1360px) {
  body.playing .play .info-col { position: sticky; top: 63px; align-self: start; }
  body.playing .play .info-col > .coach-info { position: static; max-height: calc(100vh - 71px - 32px); }
  body.playing .play.no-info .info-col > .coach-info { max-height: none; }
}
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  .info-col > .coach-tabs { display: none; }
  .coach-tabs.m-only { display: flex; }
}
/* タブが列の名前の代わり: 開いているときはカードの中の見出しを出さず、左上も丸角に戻す（2026-10-05 Aira） */
.info-col > .coach-info { border-top-left-radius: var(--radius); }
.info-col > .coach-tabs .tab-fold { margin-left: auto; align-self: center; margin-bottom: 4px; }
@media (min-width: 761px) and (orientation: portrait), (min-width: 761px) and (min-height: 501px), (min-width: 1080px) {
  .play:not(.no-info) .info-col > .coach-info > .coach-head { display: none; }
}
/* コーチとチャットも見出しを外し、タブと同じ高さの段に「たたむ」。2つのカードの上端と高さをそろえる（2026-10-05 Aira） */
.chat-col { grid-area: chat; min-width: 0; display: flex; flex-direction: column; }
.info-col > .coach-tabs, .chat-col > .col-top { height: 34px; flex: none; align-items: flex-end; }
.chat-col > .col-top { display: flex; justify-content: flex-end; align-items: center; padding: 0 4px; margin-bottom: -2px; }
.chat-col > .col-top .tab-fold, .info-col > .coach-tabs .tab-fold { margin-bottom: 0; align-self: center; }
.chat-col > .coach-chat { flex: 1 1 auto; min-height: 0; }
.play.no-chat .chat-col > .col-top { display: none; }
@media (min-width: 761px) and (orientation: portrait), (min-width: 761px) and (min-height: 501px), (min-width: 1080px) {
  .play:not(.no-chat) .chat-col > .coach-chat > .coach-head { display: none; }
}
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) { .chat-col > .col-top { display: none; } }
@media (min-width: 1360px) {
  body.playing .play .chat-col { position: sticky; top: 63px; align-self: start; }
  body.playing .play .chat-col > .coach-chat { position: static; height: calc(100vh - 71px - 32px); }
  /* データとアドバイスも、中身が短くてもチャットと同じ高さに */
  body.playing .play .info-col > .coach-info { height: calc(100vh - 71px - 32px); max-height: none; }
  /* たたんだ帯は上端から下端まで */
  body.playing .play.no-info .info-col > .coach-info, body.playing .play.no-chat .chat-col > .coach-chat { height: calc(100vh - 71px); }
}
/* 左の列（卓・手牌・おすすめの帯）も右の2列と同じ高さの箱にして、おすすめの帯の下端を右のカードとそろえる（2026-10-05 Aira「左下のおすすめもいい感じに幅をとって」） */
@media (min-width: 1360px) {
  body.playing .play .play-main { height: calc(100vh - 71px); display: flex; flex-direction: column; align-items: center; position: sticky; top: 63px; align-self: start; }
  body.playing .play .play-main > .my-area, body.playing .play .play-main > .strip { width: 100%; }
  body.playing .play .play-main > .strip { margin-top: auto; }
}
/* 広いPCで対局中は上のバーを消し、左の列の一番上（タブと同じ段）にロゴだけ置く。3列の上端と下端をそろえる（2026-10-05 Aira「ほかのメニューにここから飛ぶことは滅多にない」） */
.main-top { display: none; }
@media (min-width: 1360px) {
  body.playing .site-header { display: none; }
  body.playing .main-top { display: flex; align-items: flex-end; width: 100%; height: 24px; flex: none; padding: 0 4px; }
  .mt-logo { display: flex; align-items: baseline; gap: 8px; text-decoration: none; color: var(--ink); }
  .mt-logo b { font-family: var(--display); font-weight: 400; font-size: 21px; line-height: 1; }
  .mt-logo b em { font-style: normal; color: var(--pink); }
  .mt-logo small { font-family: var(--dot); font-size: 11px; color: var(--muted); }
  .mt-logo:hover b em { color: var(--ink); }
  body.playing .play .play-main, body.playing .play .info-col, body.playing .play .chat-col { top: 8px; }
  body.playing .play .play-main { height: calc(100vh - 16px); }
  body.playing .play .info-col > .coach-info, body.playing .play .chat-col > .coach-chat { height: calc(100vh - 16px - 32px); }
  body.playing .play.no-info .info-col > .coach-info, body.playing .play.no-chat .chat-col > .coach-chat { height: calc(100vh - 16px); }
}
/* おすすめの帯は縦に伸ばして、卓と手牌の下の残りを埋める（2026-10-05 Aira） */
@media (min-width: 1360px) {
  body.playing .play .play-main > .strip { flex: 1 1 auto; margin-top: 0; display: flex; flex-direction: column; min-height: 0; }
  body.playing .play .play-main > .strip > .strip-row { flex: 1 1 auto; }
}
@media (min-width: 1360px) {
  /* 下端の見た目を隣のカードとそろえる（影の太さ・角の丸みを同じに。2026-10-05 Aira「下の部分が隣と揃ってない」） */
  body.playing .play .play-main > .strip > .strip-row { box-shadow: 4px 4px 0 var(--ink); border-radius: var(--radius); }
}
/* 卓の上の判断パネル（ポン・チー・ロン・ツモ・リーチ。2026-10-05 Aira） */
.tbl-acts { position: absolute; left: 50%; bottom: 17%; transform: translateX(-50%); z-index: 6; width: max-content; max-width: 92%; pointer-events: none; }
.tbl-acts:empty { display: none; }
.ta-box { pointer-events: auto; display: flex; flex-direction: column; align-items: center; gap: 8px; background: rgba(18, 10, 46, .82); border: 2px solid #fff; border-radius: 16px; padding: 10px 14px; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); animation: pop .2s; }
.ta-q { color: #fff; font-weight: 800; font-size: 14px; text-align: center; }
.ta-q rt { color: var(--yellow); }
.ta-box .acts { justify-content: center; }
/* 相手の手牌の列はアバターの側に寄せる（角に置いたアバターが、どちらの列の人か分かるように。2026-10-05 Aira「誰がどれなのか分かりづらい」）
   席の座標ではアバターは列の左端の先にあるので、列を左寄せにしてアバターのすぐ隣から並べる */
.seat-1 .opp-hand, .seat-2 .opp-hand, .seat-3 .opp-hand { justify-content: flex-start; padding-left: 128px; }
/* 目指せる役: テンパイまで届く見込み（%） */
.sd-pct { font-style: normal; font-weight: 800; font-size: 11px; color: var(--pink); margin-left: 6px; }
.sd-pct.calc { color: var(--muted); }
.sd-sub { display: inline-flex; align-items: center; }
.target-card h4 .h-note b { color: var(--pink); }

/* ===== セオリー図鑑（2026-10-05 Aira「最低限のセオリーを覚えられるのが欲しい」） ===== */
/* 対局中のスタンプ: 画面の真ん中にハンコがドンと押される */
.th-stamp { position: fixed; left: 50%; top: 42%; z-index: 90; transform: translate(-50%, -50%); display: flex; flex-direction: column; align-items: center; gap: 6px; pointer-events: none;
  animation: thIn .45s cubic-bezier(.2, 1.8, .4, 1) both, thOut .35s 1.9s ease-in forwards; }
.ths-ring { width: 128px; height: 128px; border-radius: 50%; border: 7px solid var(--pink); background: rgba(255, 255, 255, .94); color: var(--pink); display: grid; place-items: center; align-content: center;
  transform: rotate(-12deg); box-shadow: 0 0 0 4px #fff, 0 10px 30px rgba(0, 0, 0, .35); font-family: var(--display); }
.ths-ring small { font-size: 15px; line-height: 1; } .ths-ring b { font-size: 46px; line-height: 1; font-weight: 400; }
.ths-t { background: var(--ink); color: #fff; font-weight: 800; font-size: 16px; padding: 6px 16px; border-radius: 99px; box-shadow: 0 4px 0 var(--pink); white-space: nowrap; }
.ths-get { font-family: var(--display); font-size: 34px; color: var(--yellow); -webkit-text-stroke: 2px var(--ink); paint-order: stroke fill; text-shadow: 3px 3px 0 var(--ink); }
.th-stamp.lv2 .ths-ring { border-color: var(--yellow); color: var(--ink); background: linear-gradient(135deg, #fff8c4, #fff); }
@keyframes thIn { from { opacity: 0; transform: translate(-50%, -50%) scale(2.4); } to { opacity: 1; transform: translate(-50%, -50%) scale(1); } }
@keyframes thOut { to { opacity: 0; transform: translate(-50%, -60%) scale(.9); } }
.cb small.sm-th { background: var(--pink); color: #fff; border-radius: 99px; padding: 0 8px; margin-left: 6px; font-size: 10px; }
/* 図鑑ページ */
.th-count { font-family: var(--body); font-size: 18px; color: var(--pink); margin-left: 8px; }
.th-lv { margin: 22px 0 10px; font-size: 18px; }
.th-lv.locked { color: var(--muted); }
.th-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; }
.th-card { position: relative; background: #fff; border: 2px solid var(--ink); border-radius: 14px; padding: 12px 14px; box-shadow: 4px 4px 0 var(--line); }
.th-card.got { box-shadow: 4px 4px 0 var(--pink); }
.th-card.locked { background: #f4f1fa; border-style: dashed; color: var(--muted); box-shadow: none; }
.th-card h3 { margin: 2px 0 4px; font-size: 16px; padding-right: 54px; }
.thc-no { font-family: var(--display); color: var(--pink); font-size: 13px; }
.th-card.locked .thc-no { color: var(--muted); }
.thc-short { margin: 0 0 6px; font-weight: 800; font-size: 13px; line-height: 1.7; }
.th-card details { font-size: 13px; line-height: 1.8; }
.th-card summary { cursor: pointer; color: var(--muted); font-weight: 800; font-size: 12px; }
.thc-how { margin: 6px 0 0; font-size: 12px; color: var(--muted); }
.thc-how b { display: inline-block; background: #f6f1ff; color: var(--ink); border-radius: 6px; padding: 0 6px; margin-right: 6px; }
.thc-stamp { position: absolute; right: 10px; top: 10px; width: 50px; height: 50px; border-radius: 50%; border: 3px solid var(--pink); color: var(--pink); display: grid; place-items: center;
  font-family: var(--display); font-size: 13px; transform: rotate(-14deg); background: #fff0f7; }
/* 和了のたびの「何点？」クイズ（2026-10-05 Aira） */
.quiz-card .qz-head { display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; margin-bottom: 6px; }
.qz-lv { font-family: var(--display); color: #fff; background: var(--pink); border-radius: 99px; padding: 2px 12px; font-size: 14px; }
.qz-sub { font-size: 12px; font-weight: 800; color: var(--muted); }
.qz-q { font-family: var(--display); font-size: 22px; text-align: center; margin: 12px 0 10px; }
.qz-choices { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.qz-c { font-size: 18px; font-weight: 800; padding: 10px 8px; background: #fff; }
.qz-c:hover:not(.done) { background: var(--yellow); }
.qz-c.done { cursor: default; opacity: .55; }
.qz-c.right { opacity: 1; background: #d9f7e6; border-color: #0f9a52; color: #0f7a45; animation: pop .25s; }
.qz-c.wrong { opacity: 1; background: #ffe5e5; border-color: var(--ng); color: var(--ng); }
.qz-why { margin-top: 12px; background: #f8f4ff; border-radius: 12px; padding: 10px 12px; font-size: 13px; line-height: 1.8; }
.qz-why b.ok { color: #0f9a52; font-size: 16px; } .qz-why b.ng { color: var(--ng); font-size: 16px; }
.qz-up { margin-top: 6px; font-family: var(--display); color: var(--pink); font-size: 16px; }
.qz-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.qz-ctx { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 8px; }
.qz-ctx span { background: #f6f1ff; border: 1px solid var(--line); border-radius: 99px; padding: 1px 10px; font-size: 12px; font-weight: 800; }
/* 集めたあとのセオリーをまた守れたとき: 卓の上に小さなバッジ（毎回） */
.th-mini { position: absolute; left: 50%; top: calc(22% + var(--i, 0) * 44px); z-index: 7; transform: translateX(-50%); display: flex; align-items: center; gap: 8px; white-space: nowrap; pointer-events: none;
  background: #fff; border: 3px solid var(--pink); border-radius: 99px; padding: 5px 14px 5px 6px; font-weight: 800; font-size: 13px; box-shadow: 0 4px 0 var(--ink);
  animation: thMini 1.5s cubic-bezier(.2, 1.6, .4, 1) both; }
.th-mini b { background: var(--pink); color: #fff; border-radius: 99px; padding: 1px 10px; font-family: var(--display); font-weight: 400; }
.th-mini em { font-style: normal; font-family: var(--display); color: var(--pink); font-size: 16px; }
@keyframes thMini { 0% { opacity: 0; transform: translateX(-50%) scale(.3) rotate(-8deg); } 15% { opacity: 1; transform: translateX(-50%) scale(1.12) rotate(2deg); } 25% { transform: translateX(-50%) scale(1); }
  80% { opacity: 1; transform: translateX(-50%) translateY(0); } 100% { opacity: 0; transform: translateX(-50%) translateY(-14px); } }
/* 両方たたんだとき: 2本とも細い帯に（まとめ指定 .play.no-info.no-chat が片方ずつの 52px より強く効いて、広いまま残っていた。2026-10-06 Aira「2つ畳むとダサくなる」） */
@media (min-width: 1360px) {
  .play.no-info.no-chat { --wi: 52px; --wc: 52px; }
}

/* ===== 対局前の読み込み画面（2026-10-06） ===== */
.loading-screen { min-height: 60vh; display: grid; place-items: center; }
.ld-card { width: min(420px, 100%); background: #fff; border: 2px solid var(--ink); border-radius: 18px; padding: 22px 20px; box-shadow: 6px 6px 0 var(--pink); text-align: center; }
.ld-faces { display: flex; justify-content: center; gap: 8px; margin-bottom: 10px; }
.ld-faces img { width: 56px; height: 56px; border-radius: 50%; border: 3px solid var(--ink); background: var(--night); animation: ldBob 1s ease-in-out infinite alternate; }
.ld-faces img:nth-child(2) { animation-delay: .2s; } .ld-faces img:nth-child(3) { animation-delay: .4s; }
@keyframes ldBob { to { transform: translateY(-6px); } }
.ld-ttl { font-family: var(--display); font-size: 22px; margin-bottom: 10px; }
.ld-bar { height: 12px; border-radius: 99px; background: #eee6ff; border: 2px solid var(--ink); overflow: hidden; }
.ld-bar i { display: block; height: 100%; background: linear-gradient(90deg, var(--cyan), var(--pink)); transition: width .2s; }
.ld-note { margin: 8px 0 14px; font-size: 13px; font-weight: 800; color: var(--muted); min-height: 1.4em; }

/* ===== 戦績（2026-10-06） ===== */
.st-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin: 14px 0; }
.st-tile { background: #fff; border: 2px solid var(--ink); border-radius: 14px; padding: 10px 12px; box-shadow: 3px 3px 0 var(--line); display: flex; flex-direction: column; gap: 2px; }
.st-tile small { font-weight: 800; color: var(--muted); font-size: 12px; }
.st-tile b { font-family: var(--display); font-weight: 400; font-size: 28px; color: var(--ink); }
.st-tile span { font-size: 11px; color: var(--muted); font-weight: 800; }
.st-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 12px; margin-bottom: 14px; }
.st-bar { display: grid; grid-template-columns: 40px 1fr 32px; gap: 8px; align-items: center; margin: 6px 0; font-weight: 800; }
.st-bar i { height: 14px; border-radius: 99px; background: #eee6ff; position: relative; overflow: hidden; }
.st-bar i::after { content: ''; position: absolute; inset: 0; width: var(--w); background: linear-gradient(90deg, var(--pink), #ff8ac0); border-radius: 99px; }
.st-yaku { margin: 0; padding-left: 20px; } .st-yaku li { display: flex; justify-content: space-between; padding: 3px 0; border-bottom: 1px dashed var(--line); }
.st-games { display: grid; gap: 8px; }
.st-game { background: #fff; border: 2px solid var(--ink); border-radius: 12px; padding: 8px 12px; }
.st-game summary { display: flex; gap: 14px; align-items: center; cursor: pointer; font-weight: 800; flex-wrap: wrap; }
.st-game .rk { border-radius: 99px; padding: 0 10px; background: #eee; } .st-game .rk.r1 { background: var(--yellow); } .st-game .rk.r4 { background: #ffe5e5; }
.st-hands { list-style: none; margin: 8px 0 0; padding: 0; display: grid; gap: 4px; }
.st-hands li { display: grid; grid-template-columns: 90px 1fr auto; gap: 10px; align-items: center; font-size: 13px; padding: 4px 6px; border-radius: 8px; }
.st-hands li.win { background: #effff1; } .st-hands li.deal { background: #fff0f0; }
.st-hands .rd { font-weight: 800; color: var(--muted); }
.st-rp { padding: 2px 10px; font-size: 12px; }
/* 対局の画面以外では、配牌の印象のモーダルや対局中の演出を隠す（対局に戻るとまた出る。2026-10-06） */
body:not(.playing) > .haipai-pop, body:not(.playing) > .th-stamp { display: none !important; }

/* ===== 対局の始め方: モード選び（2026-10-06） ===== */
.mode-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 14px 0 12px; }
.mode-card { text-align: left; display: flex; flex-direction: column; gap: 3px; background: #fff; border: 2px solid var(--ink); border-radius: 14px; padding: 12px 12px 10px; cursor: pointer; font: inherit; box-shadow: 3px 3px 0 var(--line); transition: transform .12s; }
.mode-card:hover { transform: translateY(-2px); }
.mode-card b { font-family: var(--display); font-weight: 400; font-size: 18px; }
.mode-card small { font-weight: 800; font-size: 12px; color: var(--pink); }
.mode-card > span { font-size: 12px; line-height: 1.6; color: var(--muted); font-weight: 700; }
.mode-card.on { box-shadow: 4px 4px 0 var(--pink); background: #fff3f9; outline: 3px solid var(--pink); outline-offset: -1px; }
.mode-card.m-dopa b { background: linear-gradient(90deg, var(--pink), #ff8a00); -webkit-background-clip: text; background-clip: text; color: transparent; }
.mode-snd { display: inline-flex; align-items: center; gap: 4px; margin-top: 4px; font-style: normal; font-size: 11px; font-weight: 800; color: var(--ink); background: var(--yellow); border-radius: 99px; padding: 1px 8px 1px 6px; align-self: flex-start; }
.snd-warn { display: flex; gap: 10px; align-items: flex-start; margin-top: 12px; background: #fff8d6; border: 2px solid var(--ink); border-radius: 12px; padding: 10px 12px; font-size: 13px; line-height: 1.7; }
.snd-warn > svg { flex: none; margin-top: 2px; color: var(--pink); }
.snd-warn b { display: block; font-size: 14px; }

/* ===== 配牌の印象: 五角形を大きくして、5項目の根拠を並べる（2026-10-06 Aira「五角形がPCだとちっちゃい」「何をもって判断してるか分からない」） ===== */
.hp-bal { margin-top: 10px; border: 2px solid var(--line); border-radius: 12px; padding: 8px 10px; }
.hb-ttl { font-family: var(--display); font-size: 15px; } .hb-ttl small { font-family: var(--body); font-weight: 800; font-size: 11px; color: var(--muted); margin-left: 6px; }
.hp-v4 .hp-bal .hp-radar { width: 210px; margin: 0 auto; flex: none; }
.hp-v4 .hp-bal .radar { width: 210px; max-height: 210px; }
.hp-v4 .hp-bal .radar .rl { font-size: 16px; } .hp-v4 .hp-bal .radar .rv { font-size: 13px; }
/* PC: 左に ランク・セリフ・五角形と根拠、右に 5つの手順 */
@media (min-width: 900px) {
  body > .haipai-pop .hp-card.hp-v4 { width: min(940px, 100%); display: grid; grid-template-columns: 330px 1fr; grid-template-areas: "head steps" "bal steps" "go go"; gap: 0 18px; align-items: start; }
  .hp-v4 .hp-head { grid-area: head; }
  .hp-v4 .hp-bal { grid-area: bal; }
  body > .haipai-pop .hp-v4 .hp-steps { grid-area: steps; margin-top: 0; }
  .hp-v4 .hp-go { grid-area: go; }
  body > .haipai-pop .hp-v4 .hp-bal .hp-radar, body > .haipai-pop .hp-v4 .hp-bal .radar { width: 250px; max-height: 250px; }
}
/* 列の中（データとアドバイスの「配牌の印象」）は縦に並べる */
.hp-inline .hp-bal .hp-radar, .hp-inline .hp-bal .radar { width: 190px; max-height: 190px; }

/* ===== 配牌の印象 v5: 手順＝五角形の5項目。ホバーで両方の色が変わる・左右の高さを Flex でそろえる（2026-10-06 Aira） ===== */
.hp-v4 .hp-look { margin-top: 10px; }
.hp-v4 .hp-look .hp-hand { margin: 0; }
.hp-chip { display: inline-flex; align-items: center; gap: 3px; font-size: 12.5px; font-weight: 800; background: #f6f2fb; border: 2px solid var(--line); border-radius: 99px; padding: 2px 10px; }
.hp-chip b { font-size: 16px; color: var(--gc); }
.hp-chip .tile { width: 20px; }
.st-v { font-style: normal; font-family: var(--body); font-weight: 800; font-size: 12px; min-width: 34px; text-align: center; border-radius: 6px; padding: 0 5px; margin-left: 4px;
  background: linear-gradient(90deg, color-mix(in srgb, var(--gc) 35%, #fff) var(--v), #f2eef9 var(--v)); }
.hp-plan-box { margin-top: 6px; padding: 8px 10px; border: 2px dashed var(--gc); border-radius: 12px; background: color-mix(in srgb, var(--gc) 7%, #fff); display: grid; grid-template-columns: 128px 1fr; gap: 10px; align-items: center;
  opacity: 0; transform: translateY(8px); animation: stepin .35s var(--d, 0s) cubic-bezier(.2, 1.2, .4, 1) forwards; }
.hp-inline .hp-plan-box { animation: none; opacity: 1; transform: none; grid-template-columns: 92px 1fr; }
.hp-plan-box .st-q { flex-direction: column; align-items: flex-start; gap: 1px; margin: 0; }
.hp-plan-box .st-q b { display: inline-flex; align-items: center; gap: 4px; }
.hp-plan-box .hp-row { margin: 0; display: flex; flex-wrap: wrap; gap: 4px 8px; align-items: center; }
/* ホバー連動（手順 ⇄ 五角形の項目） */
.hp-step, .radar .rax text, .radar .rdot { transition: background .15s, border-color .15s, fill .15s, r .15s; }
.radar .rax { cursor: default; }
.radar .rhit { fill: transparent; stroke: none; transition: fill .15s; }
.hp-step[data-ax] { cursor: default; }
.hp-card :is(.hp-step, .rax, .rdot)[data-ax] { --hl: 0; }
.hp-card:has([data-ax="0"]:hover) .hp-step[data-ax="0"], .hp-card:has([data-ax="0"]:hover) .rax[data-ax="0"], .hp-card:has([data-ax="0"]:hover) .rdot[data-ax="0"] { --hl: 1; }
.hp-card:has([data-ax="1"]:hover) .hp-step[data-ax="1"], .hp-card:has([data-ax="1"]:hover) .rax[data-ax="1"], .hp-card:has([data-ax="1"]:hover) .rdot[data-ax="1"] { --hl: 1; }
.hp-card:has([data-ax="2"]:hover) .hp-step[data-ax="2"], .hp-card:has([data-ax="2"]:hover) .rax[data-ax="2"], .hp-card:has([data-ax="2"]:hover) .rdot[data-ax="2"] { --hl: 1; }
.hp-card:has([data-ax="3"]:hover) .hp-step[data-ax="3"], .hp-card:has([data-ax="3"]:hover) .rax[data-ax="3"], .hp-card:has([data-ax="3"]:hover) .rdot[data-ax="3"] { --hl: 1; }
.hp-card:has([data-ax="4"]:hover) .hp-step[data-ax="4"], .hp-card:has([data-ax="4"]:hover) .rax[data-ax="4"], .hp-card:has([data-ax="4"]:hover) .rdot[data-ax="4"] { --hl: 1; }
.hp-step[data-ax] { border-color: color-mix(in srgb, var(--gc) calc(var(--hl) * 100%), var(--line)); background: color-mix(in srgb, var(--gc) calc(var(--hl) * 10%), #fff); }
.radar .rax .rhit { fill: color-mix(in srgb, var(--gc) calc(var(--hl) * 22%), transparent); }
.radar .rax .rl { fill: color-mix(in srgb, var(--gc) calc(var(--hl) * 100%), var(--ink)); }
.radar .rdot { r: calc(4.5px + var(--hl) * 2.5px); }
/* PC: 左（ランク・配牌・五角形）と右（5つの手順＋作戦）を Flex で横に並べ、下端をそろえる */
.hp-v4 .hp-lcol, .hp-v4 .hp-rcol { min-width: 0; }
@media (min-width: 900px) {
  body > .haipai-pop .hp-card.hp-v4 { width: min(960px, 100%); display: flex; flex-direction: column; }
  body > .haipai-pop .hp-v4 .hp-main { display: flex; gap: 18px; align-items: stretch; }
  body > .haipai-pop .hp-v4 .hp-lcol { flex: 0 0 340px; display: flex; flex-direction: column; }
  body > .haipai-pop .hp-v4 .hp-bal { flex: 1; display: flex; flex-direction: column; }
  body > .haipai-pop .hp-v4 .hp-bal .hp-radar { flex: 1; display: grid; place-items: center; }
  body > .haipai-pop .hp-v4 .hp-rcol { flex: 1; display: flex; flex-direction: column; }
  body > .haipai-pop .hp-v4 .hp-steps { flex: 1; display: flex; flex-direction: column; gap: 6px; margin: 0; }
  body > .haipai-pop .hp-v4 .hp-step { flex: 1 1 auto; }
  body > .haipai-pop .hp-v4 .hp-look .hp-hand .tile { max-width: 24px; }
  body > .haipai-pop .hp-v4 .hp-go { align-self: stretch; }
}
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  body > .haipai-pop .hp-v4 :is(.hp-main, .hp-lcol, .hp-rcol) { display: contents; }
  body > .haipai-pop .hp-v4 .hp-head { order: 1; }
  body > .haipai-pop .hp-v4 .hp-look { order: 2; }
  body > .haipai-pop .hp-v4 .hp-steps { order: 3; }
  body > .haipai-pop .hp-v4 .hp-plan-box { order: 4; grid-template-columns: 1fr; gap: 4px; }
  body > .haipai-pop .hp-v4 .hp-bal { order: 5; }
  body > .haipai-pop .hp-v4 .hp-go { order: 6; }
  .hp-plan-box .st-q { flex-direction: row; align-items: baseline; gap: 6px; }
}

/* ===== スマホの使い勝手（2026-10-06 Aira「スマホ画面を確認しておいて」） ===== */
.side-close .sc-close { display: none; }
.hero .tiles-deco { display: flex; flex-wrap: wrap; gap: 2px; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  /* メニュー: 右端をぼかして「まだ続きがある」と分かるように */
  .site-header .nav { -webkit-mask-image: linear-gradient(90deg, #000 82%, transparent); mask-image: linear-gradient(90deg, #000 82%, transparent); padding-right: 24px; }
  /* 引き出しの閉じるボタンは「閉じる」 */
  .side-close .sc-fold, .side-close .sc-open { display: none !important; }
  .side-close .sc-close { display: inline; }
  /* 対局の始め方: 顔は小さく、開始ボタンは画面の下に貼りつける */
  .play-setup figure img { width: 72px; height: 72px; }
  .play-setup figcaption { font-size: 13px; }
  .play-setup h1 { font-size: 24px; margin: 4px 0; }
  .play-setup .lead { font-size: 13px; }
  .play-setup > p:last-child { position: sticky; bottom: 0; z-index: 5; background: linear-gradient(transparent, var(--paper) 30%); padding: 14px 0 10px; margin-bottom: 0 !important; }
  .play-setup #play-start { flex: 1; }
  /* 手牌の下: 音のボタンとデータ・チャット */
  .my-bar { justify-content: space-between; }
  .my-bar .snd { margin-left: 0; }
  /* 配牌の印象: 「上から順に確認する5つの手順」を先に、バランス（五角形）はその後。開始ボタンはカードの下に貼りつける */
  body > .haipai-pop .hp-card.hp-v4 { display: flex; flex-direction: column; padding-bottom: 0; }
  body > .haipai-pop .hp-v4 .hp-head { order: 1; }
  body > .haipai-pop .hp-v4 .hp-steps { order: 2; }
  body > .haipai-pop .hp-v4 .hp-bal { order: 3; }
  body > .haipai-pop .hp-v4 .hp-go { order: 4; position: sticky; bottom: 0; background: #fff; margin: 10px 0 0; padding: 10px 0 12px; border-top: 2px solid var(--line); }
  body > .haipai-pop .hp-v4 .hp-bal .hp-radar, body > .haipai-pop .hp-v4 .hp-bal .radar { width: 200px; max-height: 200px; }
}
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  .play-setup > p:last-child { background: linear-gradient(transparent, var(--paper) 18px); gap: 4px !important; }
  .play-setup #play-start { flex: 1 1 100%; white-space: nowrap; }
  .play-setup #play-reset-tips { flex: 1 1 100%; border: 0; box-shadow: none; background: transparent; font-size: 12px; padding: 2px; text-decoration: underline; color: var(--muted); }
}

/* ===== 自分の机にゆとり・チャットの新しい吹き出しはポンと出す（2026-10-06 Aira「牌の下が窮屈」「おすすめがはみ出る」「ポンって出てくる演出」） ===== */
body.playing .my-hand { padding-top: 30px; padding-bottom: 16px; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) { body.playing .my-hand { padding-top: 26px; padding-bottom: 12px; } }
.strip:empty { display: none; }
.cm-new { animation: cmpop .42s cubic-bezier(.2, 1.7, .4, 1) both; transform-origin: 0 0; }
.cm-new .cb { animation: cmflash 1.2s ease-out .1s both; }
@keyframes cmpop { 0% { opacity: 0; transform: scale(.6) translateY(10px); } 100% { opacity: 1; transform: none; } }
@keyframes cmflash { 0% { box-shadow: 0 0 0 0 color-mix(in srgb, var(--c) 60%, transparent); } 100% { box-shadow: 0 0 0 10px transparent; } }
.cm.flow.fbk-good .cb { background: #effff1; } .cm.flow.fbk-bad .cb { background: #fff0f0; } .cm.flow.fbk-meh .cb { background: #fbf6ff; }
.cm.flow .cb > b small { color: var(--c); }

/* ===== 盤面を中央に: データとアドバイス ｜ 盤面 ｜ コーチとチャット（2026-10-06 Aira「盤面を中央にすればいいのか」。広いPCだけ） ===== */
@media (min-width: 1360px) {
  .play, .play.no-info, .play.no-chat, .play.no-info.no-chat { grid-template-columns: var(--wi) minmax(420px, 1fr) var(--wc); grid-template-areas: "info main chat"; }
  /* 左に移ったデータの列は、開くとき左からふわっと入る */
  .play .coach-info > :not(.coach-head) { animation-name: colInL; }
}
@keyframes colInL { from { opacity: 0; transform: translateX(-18px); } to { opacity: 1; transform: none; } }

/* ===== チャットを本当のチャットっぽく（2026-10-06 Aira） ===== */
/* 入力中の「…」 */
.cb-typing { display: inline-flex; gap: 4px; align-items: center; padding: 4px 2px; }
.cm.bot .cb.cb-typing { padding: 10px 14px; animation: fxfadein .15s; }
.cb-typing i { width: 7px; height: 7px; border-radius: 50%; background: var(--c, var(--muted)); opacity: .35; animation: typingDot 1s infinite ease-in-out; }
.cb-typing i:nth-child(2) { animation-delay: .15s; } .cb-typing i:nth-child(3) { animation-delay: .3s; }
@keyframes typingDot { 0%, 60%, 100% { transform: translateY(0); opacity: .35; } 30% { transform: translateY(-4px); opacity: 1; } }
.typing-row img { animation: fxfadein .15s; }
/* 局と巡目の区切り */
.cm-at { display: flex; justify-content: center; margin: 2px 0 -2px; }
.cm-at span { font-size: 10.5px; font-weight: 800; color: var(--muted); background: #f3eef9; border-radius: 99px; padding: 1px 10px; }
/* 同じキャラの連投は顔と名前を省いて詰める */
.chat-log .cm.cm-cont { margin-top: -6px; }
.cm.bot.cm-cont > img { visibility: hidden; height: 0; }
.cm.bot.cm-cont .cb { border-radius: 14px; }
/* 自分の質問もポンと */
.cm.me.cm-new { animation: cmpop .35s cubic-bezier(.2, 1.7, .4, 1) both; transform-origin: 100% 0; }
/* スタンプ: 吹き出しなしで、キャラの絵＋ひとこと（白ふちのステッカー風） */
.cm.stamp .stp { position: relative; width: 132px; display: grid; justify-items: center; }
.cm.stamp .stp img { width: 120px; height: 120px; object-fit: contain; border: 0; border-radius: 0; background: none;
  filter: drop-shadow(2px 0 0 #fff) drop-shadow(-2px 0 0 #fff) drop-shadow(0 2px 0 #fff) drop-shadow(0 -2px 0 #fff) drop-shadow(3px 3px 0 color-mix(in srgb, var(--c) 60%, transparent)); }
.cm.stamp .stp b { margin-top: -18px; font-family: var(--display); font-weight: 400; font-size: 17px; color: #fff; -webkit-text-stroke: 4px var(--c); paint-order: stroke fill; transform: rotate(-6deg); white-space: nowrap; }
.cm.stamp.cm-new .stp { animation: stampIn .55s cubic-bezier(.2, 1.8, .4, 1) both; }
@keyframes stampIn { 0% { opacity: 0; transform: scale(.2) rotate(-12deg); } 60% { opacity: 1; transform: scale(1.12) rotate(3deg); } 100% { transform: none; } }

/* ===== 配牌の印象: ランクの文字を二回り大きく（2026-10-06 Aira「評価がもう一回り、2回りあるといい。バランスが悪い」） ===== */
.hp-v4 .hp-grade-wrap { width: 112px; height: 100px; }
.hp-v4 .hp-grade { font-size: 100px; -webkit-text-stroke: 4px var(--ink); text-shadow: 5px 5px 0 var(--gc); }
.hp-v4 .hp-rays { inset: -36px; }
.hp-inline .hp-grade-wrap { width: 88px; height: 80px; }
.hp-inline .hp-grade { font-size: 78px; }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  .hp-v4 .hp-grade-wrap { width: 96px; height: 86px; }
  .hp-v4 .hp-grade { font-size: 86px; }
  .hp-inline .hp-grade-wrap { width: 80px; height: 72px; } .hp-inline .hp-grade { font-size: 70px; }
}

/* ===== 配牌の印象: 見出しをランクの上に・顔は吹き出しの中（名前の横）に入れて吹き出しを広く・しっぽは付けない（ランクを指して見えるため）（2026-10-06 Aira「配牌の印象はランクの上に」「アイコン＋吹き出しで形が崩れてる」） ===== */
.hp-v4 .hp-ttl-top { margin: 0 0 4px; text-align: left; align-self: stretch; }
.hp-v4 .hp-head { align-items: center; gap: 12px; }
.hp-say { position: relative; background: #fff; border: 2.5px solid var(--c); border-radius: 16px; padding: 8px 12px 9px; box-shadow: 3px 3px 0 color-mix(in srgb, var(--c) 35%, transparent); }
.hs-who { display: flex; align-items: center; gap: 6px; margin-bottom: 2px; }
.hs-who img { width: 30px; height: 30px; border-radius: 50%; border: 2px solid var(--c); background: var(--night); object-fit: cover; }
.hs-who b { font-family: var(--display); font-weight: 400; font-size: 13px; color: var(--c); }
.hs-text { font-size: 14px; font-weight: 700; line-height: 1.75; }
@media (min-width: 900px) { body > .haipai-pop .hp-v4 .hp-lcol { flex-basis: 360px; } }
@media (max-width: 760px), (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  body > .haipai-pop .hp-v4 .hp-ttl-top { order: 0; }
  .hp-v4 .hp-head { flex-wrap: nowrap; }
  .hs-text { font-size: 13px; }
}

/* セオリーの「ほかの道」（博打・遠回りでも高い手・押す・ダマ。2026-10-06 Aira） */
.cb small.sm-alt { background: var(--ink); color: var(--yellow); border-radius: 99px; padding: 0 8px; margin-left: 6px; font-size: 10px; }
.cm.alt .cb { border-style: dashed; background: #fffdf2; }
/* 相手の河の読みが変わったときの一言（2026-10-06 Aira） */
.cm.read .cb { background: #f4fbff; }
/* チャットのセオリー番号（押すと理由。2026-10-06 Aira） */
.th-link { display: inline; font: inherit; font-weight: 800; color: var(--pink); background: #fff0f7; border: 0; border-bottom: 2px dotted var(--pink); border-radius: 4px; padding: 0 3px; cursor: pointer; }
.th-link:hover, .th-link.on { background: var(--pink); color: #fff; }
.th-link i { font-style: normal; font-size: 10px; margin-left: 4px; background: var(--pink); color: #fff; border-radius: 99px; padding: 0 6px; vertical-align: 1px; }
.th-link:hover i, .th-link.on i { background: #fff; color: var(--pink); }
.th-why { margin-top: 6px; padding: 6px 9px; background: #fff7fb; border: 1.5px dashed var(--pink); border-radius: 10px; font-size: 12.5px; line-height: 1.8; animation: fxfadein .2s; }
.th-why b { display: block; color: var(--pink); font-size: 11px; }
.th-why small { display: block; margin-top: 2px; color: var(--muted); font-weight: 800; font-size: 11px; }

/* ===== 目指せる役: 王道 ｜ 博打なら（2026-10-06 Aira「王道はこれ、他にもこんな博打的な手配もあるよ」） ===== */
.sd-gamble { margin-top: 6px; padding-top: 6px; border-top: 1px dashed var(--line); }
.sd-gamble > small { color: var(--ink); background: var(--yellow); border-radius: 99px; padding: 0 8px; }
.sd.gamble { border-style: dashed; background: #fffdf2; }
.sd.gamble.on { background: var(--yellow); }
.sd.gamble .g-han { font-style: normal; font-weight: 800; font-size: 11px; color: var(--pink); margin-left: 6px; }

/* ===== チャットの最初: 配牌の印象のまとめ（押すとデータの「配牌の印象」。2026-10-06 Aira） ===== */
.hpc { display: flex; gap: 10px; align-items: center; margin: 2px 0 6px; }
.hpc-g { flex: none; font-family: var(--display); font-size: 40px; line-height: 1; color: #fff; -webkit-text-stroke: 2.5px var(--ink); paint-order: stroke fill; text-shadow: 3px 3px 0 var(--pink); transform: rotate(-6deg); }
.hpc-g.g-A { text-shadow: 3px 3px 0 #ff8a00; } .hpc-g.g-B { text-shadow: 3px 3px 0 #22b8e6; } .hpc-g.g-C { text-shadow: 3px 3px 0 #8b7fb8; } .hpc-g.g-D { text-shadow: 3px 3px 0 #6b6488; }
.hpc-t { min-width: 0; }
.hpc-plan { font-size: 12px; color: var(--muted); font-weight: 700; line-height: 1.6; margin-top: 2px; }
.hpc-plan em { font-style: normal; font-weight: 800; color: #fff; background: var(--ink); border-radius: 99px; padding: 0 7px; margin-right: 5px; font-size: 11px; }
.hpc-open { display: block; width: 100%; border: 2px solid var(--ink); background: var(--yellow); border-radius: 99px; font: inherit; font-weight: 800; font-size: 12px; padding: 4px 10px; cursor: pointer; box-shadow: 2px 2px 0 var(--ink); }
.hpc-open:hover { background: #fff; }
/* カードの中は 王道 → 博打なら を縦に2段。見出しも出す */
#coach-top .tc-body { flex-direction: column; align-items: stretch; gap: 0; }
#coach-top .target-card .strip-dirs { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
#coach-top .target-card .strip-dirs > small { display: inline-block; flex: 0 0 auto; font-family: var(--body); font-weight: 800; font-size: 12px; line-height: 1.6; letter-spacing: 0; -webkit-text-stroke: 0; border-radius: 99px; padding: 0 8px; background: var(--pink); color: #fff; }
#coach-top .target-card .sd-gamble > small { background: var(--yellow); color: var(--ink); }
/* 手牌の下の帯（スマホ・データの列をたたんでいるとき）でも 王道 → 博打なら の2段に */
.strip-row .strip-dirs.sd-gamble { flex-basis: 100%; }
.strip-row .strip-dirs > small { font-family: var(--body); font-weight: 800; }

/* ===== 流儀: 堅実派／博打派（2026-10-06 Aira「堅実に進めたい人と博打を打ちたい人」） ===== */
.style-sw { display: flex; align-items: center; gap: 0; margin: 0 0 6px; flex-basis: 100%; }
.style-sw > small { font-family: var(--body); font-weight: 800; font-size: 11px; color: var(--muted); margin-right: 8px; }
.style-sw button { font: inherit; font-weight: 800; font-size: 12px; padding: 3px 12px; border: 2px solid var(--ink); background: #fff; color: var(--muted); cursor: pointer; }
.style-sw button:first-of-type { border-radius: 99px 0 0 99px; }
.style-sw button:last-of-type { border-radius: 0 99px 99px 0; border-left: 0; }
.style-sw button.on[data-style="steady"] { background: var(--cyan); color: var(--ink); }
.style-sw button.on[data-style="gamble"] { background: var(--yellow); color: var(--ink); }
.hpc-plan em.gb { background: var(--yellow); color: var(--ink); }
/* 博打派のときは博打の段が上。王道の段の線は下側へ */
.style-sw + .sd-gamble { margin-top: 0; padding-top: 0; border-top: 0; }
.sd-gamble + .strip-dirs { margin-top: 6px; padding-top: 6px; border-top: 1px dashed var(--line); }

/* ===== 方針タブ: 流儀ごとの一打をキャラのカードで（2026-10-06 Aira「方針タブが寂しくなっちゃった」） ===== */
.pol-cards { display: grid; gap: 8px; }
.pol-card { display: grid; grid-template-columns: 44px 1fr auto; gap: 10px; align-items: center; background: #fff; border: 2px solid var(--c); border-radius: 14px; padding: 8px 10px; box-shadow: 3px 3px 0 color-mix(in srgb, var(--c) 35%, transparent); }
.pol-card.mine { background: color-mix(in srgb, var(--c) 8%, #fff); }
.pc-face { width: 44px; height: 44px; border-radius: 50%; border: 2px solid var(--c); background: var(--night); object-fit: cover; align-self: start; }
.pc-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.pc-head b { font-family: var(--display); font-weight: 400; font-size: 16px; color: var(--c); }
.pc-head small { font-size: 11px; font-weight: 800; color: var(--muted); }
.pc-mine { font-style: normal; font-size: 10px; font-weight: 800; background: var(--c); color: #fff; border-radius: 99px; padding: 0 8px; margin-left: auto; }
.pc-style { margin-left: auto; font: inherit; font-size: 10.5px; font-weight: 800; border: 1.5px solid var(--c); color: var(--c); background: #fff; border-radius: 99px; padding: 0 8px; cursor: pointer; }
.pc-style:hover { background: var(--c); color: #fff; }
.pc-text { font-size: 13px; line-height: 1.8; margin-top: 2px; }
.pc-note { display: block; color: var(--muted); font-size: 11px; line-height: 1.6; }
.pc-tile { display: grid; justify-items: center; gap: 2px; border: 0; background: none; cursor: pointer; padding: 0; }
.pc-tile .pc-cut { font-style: normal; font-size: 11px; font-weight: 800; background: var(--yellow); border: 2px solid var(--ink); border-radius: 99px; padding: 0 8px; box-shadow: 2px 2px 0 var(--ink); }
.pc-tile:hover .tile { transform: translateY(-3px); }

/* 札の翻（堅実・博打共通）。%の前に小さく */
.sd .sd-han { font-style: normal; font-weight: 800; font-size: 10.5px; color: var(--ink); background: #f3eef9; border-radius: 6px; padding: 0 5px; margin: 0 4px 0 6px; }
.sd.gamble .g-han { display: none; }
.pc-tile .tile { width: 34px; }

/* ===== スマホ横持ち（2026-10-07 Aira「雀魂みたいに横画面で。縦だと牌が小さくて見えない」「データとチャットはPC版みたいに横に」「雀卓は横幅に広がって」） =====
   横向きで高さが低い画面（＝スマホを横にしたとき）。文字の大きさなどは上の「スマホ（760px以下）」の決まりに乗せ、並びだけ横向き専用にする:
   画面いっぱいの緑のマットの上に  データとアドバイス ｜ 卓 ｜ コーチとチャット  を並べ、自分の手牌はマットの下いっぱいに。
   列はたたまない（play.js の infoOn / chatOn）。卓の大きさは play.js の fitTable が画面の高さから決める */
@media (orientation: landscape) and (max-height: 500px) and (max-width: 1079px) {
  /* ノッチの横（セーフエリア）までマットの色にする（index.html の viewport-fit=cover と組み） */
  html:has(body.playing), body.playing { background: var(--mat-dark); }
  body.playing .site-header, body.playing .main-top, body.playing #coach-strip { display: none; }
  body.playing main.wide { max-width: none; padding: 0; }
  body.playing .play, body.playing .play.no-info, body.playing .play.no-chat, body.playing .play.no-info.no-chat {
    height: 100vh; height: 100dvh; overflow: hidden; gap: 0 8px; align-items: stretch;
    padding: 6px max(8px, env(safe-area-inset-right)) 0 max(8px, env(safe-area-inset-left));
    background: radial-gradient(ellipse 55% 80% at 50% 40%, #1d7a5c 0%, var(--mat) 50%, var(--mat-dark) 100%);
    grid-template-columns: minmax(0, 1.1fr) auto minmax(0, 1fr); grid-template-rows: minmax(0, 1fr) auto;
    grid-template-areas: "info tbl chat" "hand hand hand";
  }
  body.playing .play-main, body.playing .my-area { display: contents; }
  /* 卓: 枠と影を消して、マットと一続きに見せる。手前の端（自分の席の手前は空いている）に手牌を少しかぶせる */
  body.playing .tbl-outer { grid-area: tbl; align-self: start; justify-self: center; margin: 0 0 calc(var(--s, .5) * -64px); min-width: 0; }
  body.playing .tbl { background: transparent; box-shadow: none; }
  /* 右の人（ミコ）の顔・吹き出し・河の読みは、手牌がかぶる分（卓の座標で64）だけ上に */
  body.playing .av-1 { bottom: 74px; } body.playing .av-1 .bubble { bottom: 30px; } body.playing .rd-1 { bottom: 76px; }
  /* 自分の手牌: マットの下いっぱい */
  body.playing .my-hand {
    grid-area: hand; position: relative; z-index: 8; justify-content: center; width: 100%; margin: 0 0 max(6px, env(safe-area-inset-bottom));
    padding: 16px 10px 8px; border-radius: 14px; background: rgba(6, 40, 30, .55); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, .12);
  }
  body.playing .my-hand .tiles { flex: 0 1 auto; }
  body.playing .my-hand .tile.mine { width: min(calc((100vw - 48px) / 15.4), 10.5vh) !important; }
  body.playing .my-hand .tile.mine.rec::before { top: -17px; }
  /* 左右の列: 引き出しではなく、マットの上のカード（PCの列と同じ中身） */
  body.playing .info-col { grid-area: info; }
  body.playing .chat-col { grid-area: chat; }
  body.playing .info-col, body.playing .chat-col { display: flex; flex-direction: column; min-height: 0; padding-bottom: 6px; }
  .play .coach-info, .play .coach-chat, .play.no-info .coach-info, .play.no-chat .coach-chat {
    position: static !important; transform: none; transition: none; height: auto !important; max-height: none !important; width: auto;
    flex: 1 1 auto; min-height: 0; margin: 0; padding: 8px; border-radius: 14px; box-shadow: 3px 3px 0 rgba(0, 0, 0, .35); z-index: auto;
  }
  .play .coach-info { overflow-y: auto !important; display: block; font-size: 12px; }
  .play .coach-chat { display: flex; flex-direction: column; overflow: hidden; }
  .play .coach-info > .coach-head, .play .coach-chat > .coach-head { display: none; }
  .chat-log { min-height: 0; }
  /* 質問のボタンは1行で横にスクロール（チャットの流れを広く） */
  .coach-chat .ai-quick { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  .coach-chat .ai-quick .qbtn { flex: none; }
  .coach-chat .play-settings { padding-top: 4px; margin-top: 4px; }
  .info-col > .coach-tabs .ctab { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
  /* チャットの列の上: ホームへ戻るロゴ（上のメニューを消しているので） */
  body.playing .chat-col > .col-top { display: flex; align-items: center; height: 26px; margin: 0 0 4px; padding: 0 2px; }
  body.playing .chat-col > .col-top .tab-fold { display: none; }
  body.playing .chat-col .col-home { display: inline-block; text-decoration: none; }
  .col-home b { font-family: var(--display); font-weight: 400; font-size: 13px; color: #fff; white-space: nowrap; }
  .col-home b em { font-style: normal; color: var(--pink); }
  body.playing .info-col > .coach-tabs.m-only, body.playing .coach-tabs.m-only { display: flex; }
  .coach-tabs .ctab { font-size: 11px; padding: 5px 6px; }
  /* 配牌の印象・結果は画面の高さに収めて、中でスクロール。カードの影まで画面に入れる */
  body > .haipai-pop { padding: 8px 16px 16px 10px; }
  body > .haipai-pop .hp-card.hp-v4 { max-height: calc(100vh - 24px); max-height: calc(100dvh - 24px); overflow-y: auto; padding-top: 10px; }
  body > .haipai-pop .hp-card.hp-v4 .hp-go { align-self: stretch; margin: 8px 0 0; padding: 8px 0 10px; }
  body > .haipai-pop .hp-card.hp-v4 .hp-start { padding: 8px 28px; font-size: 17px; }
  .overlay { padding: 8px 16px 16px 10px; place-items: start center; }
  .result-card { margin: auto 0; }
  .cutin { height: 200px; } .cutin .cut-img { height: 240px; } .cutin .cut-text { font-size: 90px; top: 30px; }
  /* データは出しっぱなし（左の列）、チャットはたたんでおいて、右上のボタンで卓の上に浮かせて読む（2026-10-07 Aira） */
  body.playing .play, body.playing .play.no-info, body.playing .play.no-chat, body.playing .play.no-info.no-chat { grid-template-columns: minmax(0, 1fr) auto minmax(158px, .38fr); overflow: clip; }
  body.playing .chat-col { position: relative; padding-bottom: 0; }
  body.playing .play:not(.l-chat) .coach-chat { display: none; }
  body.playing .play.l-chat .coach-chat {
    position: absolute !important; top: 32px !important; right: 0; bottom: 6px; left: auto; width: min(360px, 46vw); z-index: 40;
    box-shadow: 0 10px 28px rgba(0, 0, 0, .45), 3px 3px 0 rgba(0, 0, 0, .35);
  }
  body.playing .chat-col > .col-top { justify-content: space-between; gap: 6px; height: 28px; }
  body.playing .land-chat-btn { min-width: 76px; justify-content: center; }
  body.playing .land-chat-btn {
    display: inline-flex; align-items: center; gap: 4px; position: relative; flex: none; font: inherit; font-weight: 800; font-size: 12px; line-height: 1;
    padding: 6px 12px; border-radius: 99px; border: 2px solid var(--ink); background: #fff; color: var(--ink); box-shadow: 2px 2px 0 rgba(0, 0, 0, .35); cursor: pointer;
  }
  body.playing .land-chat-btn .lc-fold, body.playing .play.l-chat .land-chat-btn .lc-open { display: none; }
  body.playing .play.l-chat .land-chat-btn .lc-fold { display: inline; }
  body.playing .play.l-chat .land-chat-btn { background: var(--yellow); }
  body.playing .land-chat-btn .lc-new { display: none; position: absolute; top: -3px; right: -3px; width: 10px; height: 10px; border-radius: 50%; background: var(--pink); border: 2px solid #fff; }
  body.playing .play.l-chat-new:not(.l-chat) .land-chat-btn .lc-new { display: block; }
}
/* セーフエリア（iPhoneを横にしたときのノッチ側）: viewport-fit=cover にしたので、対局以外の画面は中身をノッチから逃がす。上のバーの色は端まで伸ばす */
body:not(.playing) { padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
body:not(.playing) .site-header { margin-left: calc(-1 * env(safe-area-inset-left)); margin-right: calc(-1 * env(safe-area-inset-right)); padding-left: env(safe-area-inset-left); padding-right: env(safe-area-inset-right); }
/* チャットの列の上のロゴは横持ち専用（PCは左上・上のバーにロゴがあるので出さない） */
.col-home, .land-chat-btn { display: none; }
/* スマホ縦持ちの対局中も上のバーを消して、卓を上に詰める。ホームへはロゴだけの細い段から（2026-10-07 Aira「ヘッダが出てる分下に下がってる」。広いPCと同じ考え方） */
@media (max-width: 760px) and (orientation: portrait), (max-width: 760px) and (min-height: 501px) {
  body.playing .site-header { display: none; }
  body.playing .main-top { display: flex; align-items: center; height: 26px; padding: max(2px, env(safe-area-inset-top)) 4px 0; }
  body.playing .mt-logo { display: flex; align-items: baseline; gap: 6px; text-decoration: none; color: var(--ink); }
  body.playing .mt-logo b { font-family: var(--display); font-weight: 400; font-size: 17px; line-height: 1; }
  body.playing .mt-logo b em { font-style: normal; color: var(--pink); }
  body.playing .mt-logo small { font-family: var(--dot); font-size: 10px; color: var(--muted); }
}

/* ================= トップ（2026-10-07 作り直し: キービジュアル・こんな人に・楽しいところ・遊び方動画・PV） ================= */
main.home { padding-top: 0; }
.kv { position: relative; margin: 0 calc(50% - 50vw) 0; min-height: min(78vh, 640px); display: flex; align-items: center; overflow: hidden; background: var(--night); color: #fff; }
.kv-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 70% 40%; animation: kv-zoom 18s ease-in-out infinite alternate; }
.kv::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(18, 10, 46, .92) 0%, rgba(18, 10, 46, .7) 32%, rgba(18, 10, 46, 0) 60%); }
@keyframes kv-zoom { from { transform: scale(1); } to { transform: scale(1.06); } }
.kv-in { position: relative; z-index: 1; width: 100%; max-width: 1040px; margin: 0 auto; padding: 48px 24px; }
.kv-kicker { display: inline-block; margin: 0; font-weight: 800; font-size: 14px; color: var(--ink); background: var(--yellow); padding: 2px 12px; border-radius: 99px; transform: rotate(-2deg); }
.kv-title { font-family: var(--display); font-weight: 400; font-size: clamp(48px, 8vw, 96px); line-height: 1.05; margin: 14px 0 0; text-shadow: 4px 4px 0 var(--pink); }
.kv-title em { font-style: normal; color: var(--yellow); }
.kv-lead { font-size: clamp(16px, 2vw, 21px); font-weight: 800; line-height: 1.7; margin: 16px 0 0; color: #fff; }
.kv-lead b { color: var(--cyan); }
.kv-btns { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.kv-btns .btn { text-decoration: none; display: inline-block; }
.kv-ghost { background: rgba(255, 255, 255, .12); color: #fff; border-color: #fff; font-weight: 800; padding: 12px 22px; box-shadow: 4px 4px 0 var(--cyan); }
.kv-note { margin: 12px 0 0; font-size: 13px; color: #d9d4ff; }
.tile-river { margin: 0 calc(50% - 50vw); background: var(--pink); padding: 8px 0; overflow: hidden; border-block: 3px solid var(--ink); }
.tile-river > div { display: flex; width: max-content; gap: 2px; animation: river 40s linear infinite; }
.tile-river .tile-row { display: flex; gap: 2px; flex-wrap: nowrap; }
@keyframes river { to { transform: translateX(-50%); } }
@media (prefers-reduced-motion: reduce) { .kv-img, .tile-river > div { animation: none; } }
.hm-sec { margin-top: 56px; }
.hm-h { font-family: var(--display); font-weight: 400; font-size: clamp(24px, 3.4vw, 34px); line-height: 1.3; margin: 0 0 20px; }
.hm-h small { display: block; font-family: var(--dot); font-size: 13px; color: var(--pink); letter-spacing: .08em; }
.who { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.who-i { display: flex; align-items: center; gap: 10px; background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); padding: 12px; box-shadow: 4px 4px 0 var(--c, var(--pink)); }
.who-miko { --c: #ff2e88; } .who-luna { --c: #b07bff; } .who-shion { --c: #22d6b0; }
.who-i img { width: 64px; height: 64px; border-radius: 50%; border: 3px solid var(--c); background: var(--night); flex: none; }
.who-i p { margin: 0; font-weight: 800; font-size: 14px; line-height: 1.6; }
.hm-text { font-size: 16px; line-height: 2; margin: 22px 0 0; }
.hm-text .hl { background: linear-gradient(transparent 55%, var(--yellow) 55%); }
.feats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 18px; }
.feat { background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); overflow: hidden; box-shadow: 5px 5px 0 var(--ink); }
.feat-img { aspect-ratio: 16 / 10; overflow: hidden; background: var(--mat-dark); border-bottom: 2px solid var(--ink); }
.feat-img img { width: 100%; height: 100%; object-fit: cover; object-position: top left; transition: transform .3s; }
.feat:hover .feat-img img { transform: scale(1.04); }
.feat-t { padding: 14px 16px 16px; position: relative; }
.feat-n { font-family: var(--display); font-size: 40px; line-height: 1; color: var(--pink); position: absolute; right: 14px; top: -26px; text-shadow: 2px 2px 0 var(--ink); }
.feat h3 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 20px; }
.feat p { margin: 6px 0 0; font-size: 14px; color: var(--muted); }
.movie { border: 3px solid var(--ink); border-radius: var(--radius); overflow: hidden; background: #000; box-shadow: 6px 6px 0 var(--cyan); aspect-ratio: 16 / 9; }
.movie video { width: 100%; height: 100%; display: block; }
.hm-cta { margin: 16px 0 0; text-align: center; }
.hm-cta .btn { text-decoration: none; display: inline-block; }
.pv { display: grid; grid-template-columns: 1.4fr 1fr; gap: 20px; align-items: center; background: var(--night); color: #fff; border-radius: var(--radius); padding: 18px; box-shadow: 6px 6px 0 var(--pink); }
.pv-play { position: relative; display: block; width: 100%; padding: 0; border: 0; border-radius: 10px; overflow: hidden; cursor: pointer; aspect-ratio: 16 / 9; background: #000; }
.pv-play img { width: 100%; height: 100%; object-fit: cover; display: block; }
.pv-btn { position: absolute; left: 50%; top: 50%; width: 72px; height: 72px; margin: -36px 0 0 -36px; border-radius: 50%; background: var(--pink); border: 3px solid #fff; box-shadow: 0 6px 20px rgba(0, 0, 0, .4); transition: transform .15s; }
.pv-btn::after { content: ""; position: absolute; left: 28px; top: 21px; border-style: solid; border-width: 13px 0 13px 22px; border-color: transparent transparent transparent #fff; }
.pv-play:hover .pv-btn { transform: scale(1.1); }
.pv-frame { aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; }
.pv-frame iframe { width: 100%; height: 100%; border: 0; display: block; }
.pv-kicker { margin: 0; font-family: var(--dot); color: var(--yellow); font-size: 13px; }
.pv-t h3 { margin: 4px 0 0; font-family: var(--display); font-weight: 400; font-size: 26px; line-height: 1.3; }
.pv-t p { color: #d9d4ff; font-size: 14px; margin: 8px 0 12px; }
.pv-t a { color: var(--cyan); font-weight: 800; }
.pv-list { display: grid; gap: 20px; }
.rules-pv { margin: 20px 0 28px; }
.rules-pv-h { margin: 0; font-weight: 800; color: var(--pink); }
.hm-end { margin: 64px 0 0; text-align: center; padding: 32px 16px; border-radius: var(--radius); background: var(--yellow); border: 2px solid var(--ink); box-shadow: 5px 5px 0 var(--ink); }
.hm-end .faces { display: flex; justify-content: center; gap: 8px; }
.hm-end .faces img { width: 72px; height: 72px; border-radius: 50%; border: 3px solid var(--ink); background: var(--night); }
.hm-end p { font-family: var(--display); font-size: 24px; margin: 10px 0 14px; }
.hm-end .btn { text-decoration: none; display: inline-block; }
@media (max-width: 760px) {
  .kv { min-height: 560px; align-items: flex-end; }
  .kv-img { object-position: 62% 30%; }
  .kv::after { background: linear-gradient(0deg, rgba(18, 10, 46, .95) 0%, rgba(18, 10, 46, .8) 45%, rgba(18, 10, 46, 0) 75%); }
  .kv-in { padding: 24px 18px 28px; }
  .who { grid-template-columns: 1fr; }
  .feats { grid-template-columns: 1fr; }
  .pv { grid-template-columns: 1fr; }
  .hm-sec { margin-top: 44px; }
}

/* ================= 遊び方 ================= */
.ht-movie { margin: 8px 0 28px; }
.ht-steps { list-style: none; margin: 0; padding: 0; display: grid; gap: 22px; }
.ht-step { background: #fff; border: 2px solid var(--ink); border-radius: var(--radius); padding: 18px; box-shadow: 4px 4px 0 var(--ink); }
.ht-head { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.ht-n { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--pink); color: #fff; font-family: var(--display); font-size: 20px; border: 2px solid var(--ink); }
.ht-head h2 { margin: 0; font-family: var(--display); font-weight: 400; font-size: 22px; line-height: 1.3; }
.ht-body { display: grid; grid-template-columns: 1.15fr 1fr; gap: 18px; align-items: start; }
.ht-body.no-img { grid-template-columns: 1fr; }
.ht-img { border: 2px solid var(--ink); border-radius: 10px; overflow: hidden; background: var(--mat-dark); }
.ht-img img { width: 100%; display: block; }
.ht-text { font-size: 15px; line-height: 1.9; }
.ht-text ul { margin: 6px 0; padding-left: 1.2em; }
.ht-say { display: flex; gap: 10px; align-items: flex-start; margin-top: 12px; }
.ht-say img { width: 48px; height: 48px; border-radius: 50%; border: 2px solid var(--ink); background: var(--night); flex: none; }
.ht-say p { margin: 0; background: var(--paper); border: 2px solid var(--line); border-radius: 12px; padding: 8px 12px; font-weight: 800; font-size: 14px; }
@media (max-width: 760px) { .ht-body { grid-template-columns: 1fr; } .ht-head h2 { font-size: 19px; } }
.hm-yt, .ht-yt a { font-weight: 800; color: var(--pink); margin-left: 12px; }
.ht-yt { margin: -18px 0 24px; text-align: right; }
