/* ポニー馬主会 PWA ― 採用デザイン（カバーストーリー＋出走予定はダーク） */
:root {
  --bg: #faf9f7;
  --card: #ffffff;
  --chip: #efece7;
  --line: #e3dfd8;
  --line2: #f0ede8;
  --text: #1a1a1a;
  --sub: #5c5a55;
  --hint: #8b877f;
  --accent: #b4532a;       /* テラコッタ */
  --dark: #101112;
  --dark-text: #f2f2f0;
  --dark-sub: #c9cbcd;
  --dark-accent: #e0703f;
  --safe-top: env(safe-area-inset-top, 0px);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
  --tab-h: 58px;
}
* { box-sizing: border-box; -webkit-tap-highlight-color: transparent; }
html, body { margin: 0; background: var(--bg); color: var(--text); }
body {
  font-family: -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Noto Sans JP", "Yu Gothic UI", sans-serif;
  font-size: 15px; line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  overscroll-behavior-y: none;
}
a { color: inherit; text-decoration: none; }
button, select, input { font: inherit; color: inherit; }
button { cursor: pointer; }
.num { font-variant-numeric: tabular-nums; font-feature-settings: "tnum"; letter-spacing: -0.01em; }

#app { max-width: 560px; margin: 0 auto; min-height: 100vh; position: relative; }
#view { padding-top: var(--safe-top); padding-bottom: calc(var(--tab-h) + var(--safe-bottom) + 24px); }
.boot, .empty { text-align: center; color: var(--sub); padding: 60px 16px; font-size: 14px; }

/* ---------- タブバー ---------- */
#tabbar {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 30;
  background: rgba(250, 249, 247, 0.96); backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
  border-top: 1px solid var(--line);
  padding-bottom: var(--safe-bottom);
}
#tabbar .in { max-width: 560px; margin: 0 auto; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); }
#tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 7px 0 6px; font-size: 10px; color: var(--sub); min-height: var(--tab-h); justify-content: center; }
#tabbar a.on { color: var(--accent); font-weight: 700; }
#tabbar svg { width: 24px; height: 24px; }

/* ---------- 共通 ---------- */
.hd { padding: 18px 16px 6px; display: flex; justify-content: space-between; align-items: center; gap: 10px; }
.hd .meta { font-size: 12px; color: var(--sub); background: none; border: none; padding: 0; text-align: left; }
.hd h1 { margin: 2px 0 0; font-size: 26px; font-weight: 700; line-height: 1.25; display: flex; align-items: center; gap: 4px; }
.hd h1 .mascot { width: 44px; height: 44px; margin: -8px 0 -6px; flex: 0 0 44px; }
.hd .actions { display: flex; gap: 8px; flex: 0 0 auto; }
.icon-btn { position: relative; width: 44px; height: 44px; border-radius: 50%; border: none; background: var(--chip); display: inline-flex; align-items: center; justify-content: center; }
.icon-btn svg { width: 21px; height: 21px; }
.icon-btn .dot { position: absolute; top: 9px; right: 10px; width: 8px; height: 8px; border-radius: 50%; background: var(--accent); }
.pill-btn { height: 44px; border-radius: 22px; border: none; background: var(--chip); padding: 0 14px; font-size: 13px; white-space: nowrap; max-width: 130px; overflow: hidden; text-overflow: ellipsis; }
.sec { margin-top: 32px; }
.sec-h { display: flex; justify-content: space-between; align-items: baseline; padding: 0 16px; margin-bottom: 10px; }
.sec-h h2 { margin: 0; font-size: 20px; font-weight: 700; }
.sec-h a, .link { font-size: 13px; color: var(--accent); padding: 8px 0; }
.more { display: block; width: 100%; text-align: center; font-size: 13px; color: var(--accent); background: none; border: none; padding: 14px 0; }
.hscroll { display: flex; gap: 12px; overflow-x: auto; padding: 0 16px 4px; scroll-snap-type: x proximity; scroll-padding-inline: 16px; scrollbar-width: none; }
.hscroll::-webkit-scrollbar { display: none; }
.hscroll > * { scroll-snap-align: start; }
.chip { display: inline-flex; align-items: center; min-height: 36px; padding: 0 12px; border-radius: 999px; background: var(--chip); font-size: 13px; border: none; white-space: nowrap; }
.chip.on { background: var(--text); color: var(--bg); font-weight: 700; }
.tag { font-size: 11px; font-weight: 700; border-radius: 6px; padding: 2px 7px; display: inline-block; line-height: 1.4; }
.tag-dark { background: var(--dark-accent); color: var(--dark); }
.badge { font-size: 10px; font-weight: 700; background: #fff; color: var(--text); border-radius: 999px; padding: 3px 8px; }

/* 写真（無い時は落ち着いた色の面） */
.ph { position: relative; overflow: hidden; background: var(--tone, #c4c0b4); }
.ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ph .ini { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; color: rgba(255,255,255,0.85); font-weight: 700; font-size: 22px; }

/* ---------- ホーム ---------- */
.metrics { margin: 18px 16px 0; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); text-align: center; }
.metrics > div + div { border-left: 1px solid var(--line); }
.metrics .v { font-weight: 700; font-size: 26px; line-height: 1.2; }
.metrics .v small { font-size: 14px; color: var(--sub); font-weight: 600; }
.metrics .l { font-size: 11px; color: var(--sub); }
.metrics .hot { color: var(--accent); }

.dark-band { margin-top: 32px; background: var(--dark); color: var(--dark-text); padding: 22px 0 24px; }
.dark-band .sec-h a { color: var(--dark-accent); }
.race-card { flex: 0 0 290px; height: 220px; border-radius: 20px; position: relative; overflow: hidden; color: var(--dark-text); }
.race-card .when { position: absolute; top: 12px; left: 12px; font-weight: 700; font-size: 12px; background: rgba(16,17,18,0.72); border-radius: 8px; padding: 5px 9px; z-index: 1; }
.race-card .cap { position: absolute; left: 0; right: 0; bottom: 0; background: rgba(16,17,18,0.86); padding: 12px 14px; z-index: 1; }
.race-card .cap .t { display: flex; justify-content: space-between; align-items: center; gap: 8px; font-size: 18px; font-weight: 700; }
.race-card .cap .s { font-size: 12px; color: var(--dark-sub); margin-top: 3px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dark-empty { padding: 4px 16px 0; color: var(--dark-sub); font-size: 13px; }

.hcard { flex: 0 0 140px; min-width: 0; }
.hgrid3 { padding: 0 16px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.hgrid3 .hcard .ph { height: auto; aspect-ratio: 3 / 4; }
.hcard .ph { height: 180px; border-radius: 16px; }
.hcard .ph .badge { position: absolute; left: 8px; bottom: 8px; z-index: 1; }
.hcard .n { font-size: 14px; font-weight: 700; margin-top: 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.hcard .s { font-size: 12px; color: var(--sub); }

.list { padding: 0 16px; }
.news { display: grid; grid-template-columns: 1fr 84px; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); width: 100%; text-align: left; background: none; border-left: 0; border-right: 0; border-top: 0; }
.news .m { font-size: 12px; color: var(--sub); }
.news .h { font-size: 16px; font-weight: 700; margin: 3px 0 4px; }
.news .b { font-size: 13px; line-height: 1.6; color: #3d3b37; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; white-space: pre-line; }
.news.open .b { -webkit-line-clamp: unset; display: block; }
.news .ph { width: 84px; height: 84px; border-radius: 14px; }

.res { display: flex; align-items: center; gap: 14px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.res .rk { font-weight: 700; font-size: 20px; width: 36px; height: 36px; flex: 0 0 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; }
.res .t { flex: 1; min-width: 0; }
.res .t b { display: block; font-size: 15px; }
.res .t span { font-size: 12px; color: var(--sub); }

.panel { margin: 32px 16px 0; background: var(--card); border-radius: 20px; padding: 6px 16px; }
.panel h2 { margin: 10px 0 2px; font-size: 16px; font-weight: 700; }
.rank-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.rank-row .no { font-weight: 700; color: var(--accent); width: 14px; }
.rank-row .ph { width: 40px; height: 40px; border-radius: 12px; flex: 0 0 40px; }
.rank-row .n { flex: 1; font-weight: 700; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rank-row .p { font-weight: 600; font-size: 14px; }

.club-links { padding: 0 16px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.club-links a { display: flex; justify-content: space-between; align-items: center; min-height: 48px; padding: 0 14px; background: var(--card); border-radius: 14px; font-size: 14px; font-weight: 700; }
.club-links a span:last-child { color: var(--accent); font-weight: 400; }

/* 着順: 1着=黄 / 2着=青 / 3着=オレンジ（丸）、4〜9着=黒、10着以降=グレー */
.rk.r1 { background: #f5c518; color: #1a1a1a; }
.rk.r2 { background: #2f6fd6; color: #ffffff; }
.rk.r3 { background: #ec7a22; color: #ffffff; }
.rk.rmid { color: var(--text); }
/* 成績画面: 着順色の札・棒グラフ・成績の数字 */
.pill { display: inline-block; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 1px 8px; }
.pill.r1, .bar i.r1, .lg.r1 { background: #f5c518; color: #1a1a1a; }
.pill.r2, .bar i.r2, .lg.r2 { background: #2f6fd6; color: #ffffff; }
.pill.r3, .bar i.r3, .lg.r3 { background: #ec7a22; color: #ffffff; }
.legend-h { display: flex; justify-content: space-between; align-items: center; margin-right: 24px; }
.legend { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; }
.legend .lg { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-left: 6px; }
.rec { font-size: 13px; color: var(--sub); white-space: nowrap; }
.rec .t1 { color: #a07c00; } .rec .t2 { color: #2f6fd6; } .rec .t3 { color: #d0661a; }
.rk.rlow { color: #9a968f; }
/* クラブの勝負服カラー● */
.cdot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 4px; vertical-align: 0; box-shadow: inset 0 0 0 1px rgba(0,0,0,0.22); }

/* ---------- 出資馬一覧 ---------- */
.filters { display: flex; gap: 8px; overflow-x: auto; padding: 12px 16px 4px; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }
.toolbar { display: flex; justify-content: space-between; align-items: center; padding: 6px 16px 12px; font-size: 13px; color: var(--sub); }
.toolbar select { border: none; background: transparent; font-weight: 700; color: var(--text); padding: 8px 2px; font-size: 13px; }
.seg { display: flex; background: var(--chip); border-radius: 10px; padding: 3px; }
.seg button { width: 40px; height: 32px; border: none; border-radius: 8px; background: transparent; display: flex; align-items: center; justify-content: center; }
.seg button.on { background: #fff; }
.seg svg { width: 16px; height: 16px; }
.grid2 { padding: 0 16px; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
.gcard .ph { aspect-ratio: 3 / 4; border-radius: 16px; }
.gcard .ph .badge { position: absolute; left: 8px; top: 8px; z-index: 1; }
.gcard .ph .nx { position: absolute; left: 8px; right: 8px; bottom: 8px; z-index: 1; font-size: 11px; font-weight: 700; color: var(--dark-text); background: rgba(16,17,18,0.86); border-radius: 10px; padding: 6px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.gcard .s { font-size: 11px; color: var(--sub); margin-top: 8px; }
.gcard .n { font-size: 15px; font-weight: 700; margin-top: 1px; }
.owners { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 6px; }
.owners span { font-size: 11px; background: var(--chip); border-radius: 6px; padding: 2px 6px; }
.owners span.me { background: var(--accent); color: #fff; }
.lrow { display: grid; grid-template-columns: 56px 1fr auto; gap: 12px; align-items: center; padding: 10px 0; border-bottom: 1px solid var(--line); }
.lrow .ph { width: 56px; height: 56px; border-radius: 12px; }
.lrow .n { font-weight: 700; }
.lrow .s { font-size: 12px; color: var(--sub); }
.lrow .x { font-size: 12px; color: var(--sub); text-align: right; }

/* ---------- 馬詳細 ---------- */
.d-hero { position: relative; height: 360px; }
.d-hero { background: var(--dark); }
.d-hero .car { position: absolute; inset: 0; display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; }
.d-hero .car::-webkit-scrollbar { display: none; }
.d-hero .slide { position: relative; flex: 0 0 100%; scroll-snap-align: start; }
.d-hero .ph { position: absolute; inset: 0; }
.d-hero .cap { position: absolute; left: 16px; bottom: 50px; z-index: 1; max-width: 70%; font-size: 11px; color: #fff; background: rgba(16,17,18,0.55); border-radius: 8px; padding: 4px 8px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.d-hero .dots { position: absolute; right: 16px; bottom: 54px; z-index: 2; display: flex; gap: 5px; }
.d-hero .dots i { width: 6px; height: 6px; border-radius: 3px; background: rgba(255,255,255,0.5); }
.d-hero .dots i.on { background: #fff; width: 14px; }
.d-hero .top { position: absolute; top: calc(12px + var(--safe-top)); left: 16px; right: 16px; display: flex; justify-content: space-between; z-index: 2; }
.glass { width: 40px; height: 40px; border-radius: 50%; border: none; background: rgba(0,0,0,0.38); display: inline-flex; align-items: center; justify-content: center; color: #fff; }
.glass svg { width: 20px; height: 20px; }
.d-body { position: relative; margin-top: -36px; background: var(--bg); border-radius: 24px 24px 0 0; padding: 20px 16px 0; z-index: 1; }
.d-body .s { font-size: 12px; color: var(--sub); }
.d-body h1 { margin: 4px 0 2px; font-size: 28px; font-weight: 700; line-height: 1.25; }
.d-chips { display: flex; gap: 8px; align-items: center; margin-top: 14px; flex-wrap: wrap; }
.d-chips label { display: flex; align-items: center; gap: 6px; background: var(--chip); border-radius: 999px; padding: 0 6px 0 12px; min-height: 36px; font-size: 13px; }
.d-chips select { border: none; background: transparent; font-weight: 700; padding: 6px 4px; font-size: 13px; }
.d-msg { font-size: 12px; margin-top: 6px; min-height: 16px; }
.next-card { display: block; margin: 18px 16px 0; background: var(--dark); color: var(--dark-text); border-radius: 18px; padding: 14px 16px; }
.next-card .k { display: flex; justify-content: space-between; font-size: 12px; font-weight: 700; }
.next-card .k span:first-child { color: var(--dark-accent); }
.next-card .k span:last-child { color: var(--dark-sub); }
.next-card .t { font-size: 18px; font-weight: 700; margin-top: 4px; }
.next-card .s { font-size: 12px; color: var(--dark-sub); margin-top: 2px; }
.tabs { position: sticky; top: 0; z-index: 5; background: var(--bg); margin-top: 22px; padding: var(--safe-top) 16px 0; border-bottom: 1px solid var(--line); display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); text-align: center; }
.tabs button { border: none; background: none; padding: 12px 0; font-size: 14px; color: var(--sub); }
.tabs button.on { color: var(--accent); font-weight: 700; box-shadow: inset 0 -2px 0 var(--accent); }
.tl { padding: 6px 16px 0; }
.tl article { display: grid; grid-template-columns: 14px 1fr; gap: 12px; padding-top: 18px; }
.tl .rail { display: flex; flex-direction: column; align-items: center; }
.tl .rail i { width: 9px; height: 9px; border-radius: 50%; margin-top: 5px; background: #c9c4bb; }
.tl article:first-child .rail i { background: var(--accent); }
.tl .rail b { flex: 1; width: 1px; background: var(--line); margin-top: 4px; }
.tl .m { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--sub); }
.tl .m strong { color: var(--text); }
.tl p { margin: 6px 0 8px; font-size: 14px; line-height: 1.8; white-space: pre-line; word-break: break-word; }
.kv { margin: 16px 16px 0; background: var(--card); border-radius: 20px; padding: 4px 16px; }
.kv > div { display: grid; grid-template-columns: 110px 1fr; gap: 10px; padding: 11px 0; border-bottom: 1px solid var(--line2); font-size: 14px; }
.kv > div:last-child { border-bottom: none; }
.kv > div span:first-child { color: var(--sub); }
.btns { display: flex; gap: 8px; margin: 14px 16px 0; }
.btns a { flex: 1; text-align: center; font-size: 13px; font-weight: 700; border-radius: 12px; padding: 13px 0; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-plain { background: var(--chip); color: var(--text); }
.races { padding: 0 16px; }
.race-row { display: grid; grid-template-columns: 44px 1fr; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.race-row .rk { font-weight: 700; font-size: 18px; width: 36px; height: 36px; display: inline-flex; align-items: center; justify-content: center; border-radius: 50%; justify-self: center; }
.race-row .n { font-weight: 700; font-size: 14px; }
.race-row .s { font-size: 12px; color: var(--sub); }
.kuchi { margin: 16px 16px 0; background: var(--card); border-radius: 20px; padding: 6px 16px; }
.kuchi .sum { font-size: 14px; padding: 10px 0; border-bottom: 1px solid var(--line2); }
.kuchi .row { display: grid; grid-template-columns: 44px 1fr; gap: 10px; padding: 10px 0; border-bottom: 1px solid var(--line2); font-size: 13px; }
.kuchi .row:last-child { border-bottom: none; }
.kuchi .row.mine { background: #fbf1ec; margin: 0 -16px; padding: 10px 16px; }

/* ---------- その他画面 ---------- */
.group-h { margin: 26px 32px 8px; font-size: 13px; font-weight: 500; color: var(--sub); }
.group { margin: 0 16px; background: var(--card); border-radius: 16px; overflow: hidden; }
.group > * { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 14px 16px; border-bottom: 1px solid var(--line2); width: 100%; background: none; border-left: 0; border-right: 0; border-top: 0; text-align: left; font-size: 15px; }
.group > *:last-child { border-bottom: none; }
.group small { display: block; font-size: 12px; color: var(--sub); margin-top: 2px; }
.dark-panel { margin: 14px 16px 0; background: var(--dark); color: var(--dark-text); border-radius: 20px; padding: 18px; }
.dark-panel p { margin: 10px 0 0; font-size: 12px; line-height: 1.7; color: var(--dark-sub); }
.stat3 { margin: 14px 16px 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; }
.stat3 > div, .stat3 > a { background: var(--card); border-radius: 16px; padding: 12px; text-align: center; display: block; border: 2px solid transparent; }
.stat3 > a.sel { border-color: var(--text); }
.chev { color: var(--hint); margin-left: 6px; }
a.chip { text-decoration: none; }
.stat3 .v { font-size: 24px; font-weight: 700; }
.stat3 .l { font-size: 11px; color: var(--sub); }
.bar { display: flex; height: 8px; border-radius: 4px; overflow: hidden; background: var(--line2); margin-top: 8px; }
.bar i { display: block; height: 100%; }

/* ---------- シート・トースト ---------- */
.sheet { position: fixed; inset: 0; z-index: 60; background: rgba(16,17,18,0.45); display: flex; align-items: flex-end; justify-content: center; }
.sheet[hidden] { display: none; }
.sheet .box { width: 100%; max-width: 560px; max-height: 82vh; overflow: auto; background: var(--bg); border-radius: 22px 22px 0 0; padding: 10px 16px calc(20px + var(--safe-bottom)); }
.sheet .grab { width: 40px; height: 5px; border-radius: 3px; background: var(--line); margin: 0 auto 12px; }
.sheet h2 { margin: 4px 0 4px; font-size: 18px; }
.sheet p { margin: 0 0 12px; font-size: 13px; color: var(--sub); }
.pick { display: flex; align-items: center; gap: 12px; width: 100%; padding: 12px; border: none; border-radius: 14px; background: var(--card); margin-bottom: 8px; text-align: left; font-size: 15px; }
.pick .av { width: 36px; height: 36px; border-radius: 50%; background: var(--chip); display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 13px; flex: 0 0 36px; }
.pick.on { box-shadow: inset 0 0 0 2px var(--accent); }
.toast { position: fixed; left: 50%; transform: translateX(-50%); bottom: calc(var(--tab-h) + var(--safe-bottom) + 14px); z-index: 70; background: var(--dark); color: var(--dark-text); font-size: 13px; padding: 10px 16px; border-radius: 12px; max-width: 90vw; }
.toast[hidden] { display: none; }
.login { padding: calc(80px + var(--safe-top)) 24px 0; max-width: 360px; margin: 0 auto; text-align: center; }
.login h1 { font-size: 24px; margin: 0 0 6px; }
.login p { color: var(--sub); font-size: 13px; margin: 0 0 22px; }
.login input { width: 100%; height: 50px; border-radius: 14px; border: 1px solid var(--line); background: #fff; padding: 0 14px; font-size: 16px; margin-bottom: 12px; }
.login button { width: 100%; height: 50px; border-radius: 14px; border: none; background: var(--accent); color: #fff; font-weight: 700; font-size: 15px; }
.login .err { color: #b3261e; font-size: 13px; min-height: 20px; margin-top: 8px; }

/* ---------- PC（マウス操作）向け: 横スクロールしにくいので折り返す・矢印で送る ---------- */
.car-btn { display: none; }
@media (hover: hover) and (pointer: fine) {
  .filters { flex-wrap: wrap; overflow-x: visible; }
  .hscroll { flex-wrap: wrap; overflow-x: visible; scroll-snap-type: none; }
  .race-card { flex: 1 1 260px; }
  .hcard { flex: 0 0 calc((100% - 24px) / 3); }
  .car-btn { display: inline-flex; position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; }
  .car-btn.prev { left: 12px; } .car-btn.next { right: 12px; }
  .car-btn.prev svg { transform: none; } .car-btn.next svg { transform: scaleX(-1); }
}

/* スイッチ（通知設定） */
.sw { position: relative; width: 52px; height: 32px; flex: 0 0 52px; display: inline-block; }
.sw input { position: absolute; inset: 0; opacity: 0; margin: 0; cursor: pointer; z-index: 1; }
.sw i { position: absolute; inset: 0; border-radius: 16px; background: #d6d1c8; transition: background .15s; }
.sw i::after { content: ''; position: absolute; top: 3px; left: 3px; width: 26px; height: 26px; border-radius: 50%; background: #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.2); transition: left .15s; }
.sw.on i { background: var(--accent); }
.sw.on i::after { left: 23px; }
.dark-panel .sw.on i { background: var(--dark-accent); }
.group label { cursor: pointer; }
.group input[type=radio] { width: 20px; height: 20px; accent-color: var(--accent); }
.sw-btn { border: none; padding: 0; background: none; cursor: pointer; }
.sw-btn:disabled { opacity: 0.6; }

/* タップでその馬の画面へ移れる馬名（リンク表示） */
.hname { color: var(--accent); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; text-decoration-color: rgba(180, 83, 42, 0.45); }
.race-card .hname { color: var(--dark-text); text-decoration-color: rgba(242, 242, 240, 0.6); }
