/* 解放オプション期待値計算 — サイバー／ダークテーマ
   色の役割: シアン=結果・主役 ／ バイオレット=ヒント・注記 ／ ライム=操作 ／ アンバー=注意 */
:root {
  --bg: #111a30;
  --bg-2: #162238;
  --surface: rgba(30, 43, 70, .9);
  --surface-2: rgba(42, 58, 92, .8);
  --blk: rgba(40, 55, 90, .82);
  --input: #182540;
  --fg: #f2f6fc;
  --fg-2: #d3dced;
  --muted: #9aa9c2;
  --faint: #6b7a96;
  --line: rgba(145, 180, 245, .26);
  --line-2: rgba(145, 180, 245, .16);
  --line-3: rgba(145, 180, 245, .45);
  --cyan: #38d9f5;   --cyan-soft: rgba(56, 217, 245, .12);  --cyan-line: rgba(56, 217, 245, .38);  --cyan-ink: #8ae9fb;
  --violet: #9d8cff; --violet-soft: rgba(157, 140, 255, .13); --violet-line: rgba(157, 140, 255, .4); --violet-ink: #c3b8ff;
  --lime: #b3f05a;   --lime-soft: rgba(179, 240, 90, .12);   --lime-line: rgba(179, 240, 90, .38);  --lime-ink: #cdf78a;
  --amber: #f5b342;  --amber-soft: rgba(245, 179, 66, .13);  --amber-line: rgba(245, 179, 66, .4);  --amber-ink: #ffd07a;
  --blue: #5b9cf6;
  --ring: rgba(179, 240, 90, .35);
  --shadow: 0 0 0 1px rgba(56, 217, 245, .04), 0 20px 50px -30px rgba(0, 0, 0, .9);
  --glow-cyan: 0 0 18px rgba(56, 217, 245, .35);
  --sans: "Geist", "Noto Sans JP", -apple-system, BlinkMacSystemFont, "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif;
  --mono: "Geist Mono", "SFMono-Regular", Consolas, Menlo, monospace;
  --disp: "Orbitron", "Geist", sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; color-scheme: dark; }
body {
  margin: 0; position: relative; min-height: 100vh;
  background:
    radial-gradient(900px 500px at 10% -10%, rgba(56, 217, 245, .2), transparent 65%),
    radial-gradient(800px 500px at 100% 0%, rgba(157, 140, 255, .22), transparent 65%),
    radial-gradient(700px 400px at 50% 110%, rgba(179, 240, 90, .1), transparent 65%),
    var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  padding-inline: 16px;
  padding-block: 0 40px;
  overflow-x: hidden;
}
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none;
  background-image:
    linear-gradient(rgba(56, 217, 245, .07) 1px, transparent 1px),
    linear-gradient(90deg, rgba(56, 217, 245, .07) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(ellipse at 50% 0%, #000 20%, transparent 75%);
  animation: grid-drift 40s linear infinite;
}
@keyframes grid-drift { to { background-position: 48px 48px; } }
@keyframes rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }
@keyframes pulse { 0% { text-shadow: 0 0 0 rgba(56, 217, 245, 0); } 35% { text-shadow: 0 0 22px rgba(56, 217, 245, .75); } 100% { text-shadow: var(--glow-cyan); } }
@keyframes blink { 50% { opacity: .35; } }
@keyframes flicker { 0%, 100% { opacity: 1; } 92% { opacity: 1; } 93% { opacity: .55; } 94% { opacity: 1; } 97% { opacity: .7; } }
@keyframes pop { 0% { transform: scale(.96); opacity: 0; } 100% { transform: none; opacity: 1; } }
@keyframes scan { from { transform: translateX(-100%); } to { transform: translateX(100%); } }

a { color: inherit; }
h1, h2 { margin: 0; font-weight: 600; letter-spacing: -0.01em; }
button, input, select { font-family: inherit; }
::selection { background: rgba(56, 217, 245, .35); }
.wrap { max-width: 1040px; margin: 0 auto; position: relative; z-index: 1; }

/* ---------- header ---------- */
.top { padding-block: 20px 14px; animation: rise .5s ease-out both; }
.top .home { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 10px; font-size: 12.5px; font-weight: 500; color: var(--muted); text-decoration: none; transition: color .15s, transform .2s; }
.top .home:hover { color: var(--cyan-ink); transform: translateX(-3px); }
.top .ttl-row { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 6px 16px; }
.top .credit { margin: 0; font-size: 12.5px; color: var(--fg-2); }
.top .credit a { color: var(--cyan-ink); font-weight: 600; text-decoration: none; border-bottom: 1px solid var(--cyan-line); transition: color .15s, border-color .15s, text-shadow .15s; }
.top .credit a:hover { color: var(--cyan); border-color: var(--cyan); text-shadow: var(--glow-cyan); }
.top h1 { font-family: var(--disp); font-size: 18px; letter-spacing: .06em; display: flex; align-items: center; gap: 12px; text-shadow: var(--glow-cyan); animation: flicker 7s linear infinite; }
.top h1 .dot { width: 10px; height: 10px; border-radius: 2px; background: var(--cyan); box-shadow: 0 0 12px var(--cyan), 0 0 0 4px var(--cyan-soft); transform: rotate(45deg); animation: blink 2.4s ease-in-out infinite; }

/* ---------- switches ---------- */
.bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; padding-bottom: 16px; animation: rise .5s .08s ease-out both; }
.sw { display: flex; align-items: center; gap: 8px; }
.sw .k, .field .lbl, .field label { font-family: var(--disp); font-size: 10.5px; font-weight: 500; letter-spacing: .14em; color: var(--muted); }
.seg { display: inline-flex; flex-wrap: wrap; padding: 3px; border-radius: 10px; background: rgba(6, 10, 20, .7); border: 1px solid var(--line); }
.seg button {
  appearance: none; border: 0; background: transparent; color: var(--muted);
  font-size: 13px; font-weight: 500; padding: 6px 14px; border-radius: 7px; cursor: pointer;
  display: inline-flex; align-items: center; gap: 6px; position: relative;
  transition: background .2s, color .2s, box-shadow .2s;
}
.seg button:hover { color: var(--fg); }
.seg button[aria-pressed="true"] { background: var(--cyan-soft); color: var(--cyan-ink); box-shadow: inset 0 0 0 1px var(--cyan-line), var(--glow-cyan); }
.seg button:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--ring); }
.bar .ghost { margin-left: auto; }
.ghost {
  appearance: none; background: transparent; border: 1px solid var(--line-3); color: var(--fg-2);
  font-size: 12.5px; font-weight: 500; padding: 6px 12px; border-radius: 8px; cursor: pointer;
  transition: background .2s, border-color .2s, color .2s, box-shadow .2s;
}
.ghost:hover { border-color: var(--lime-line); color: var(--lime-ink); box-shadow: 0 0 14px rgba(179, 240, 90, .2); }
.ghost:focus-visible { outline: none; box-shadow: 0 0 0 2px var(--ring); }

/* 相場入力 */
.pin { display: inline-flex; align-items: center; background: var(--input); border: 1px solid var(--line-3); border-radius: 10px; overflow: hidden; transition: border-color .2s, box-shadow .2s; }
.pin:focus-within { border-color: var(--lime); box-shadow: 0 0 0 3px var(--ring), 0 0 18px rgba(179, 240, 90, .25); }
.pin input { appearance: none; width: 110px; border: 0; background: transparent; color: var(--fg); font-family: var(--mono); font-size: 15px; font-weight: 600; padding: 7px 10px; text-align: right; font-variant-numeric: tabular-nums; }
.pin input:focus { outline: none; }
.pin input::-webkit-outer-spin-button, .pin input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }
.pin input::placeholder { color: var(--faint); }
.pin .unit { font-size: 12px; color: var(--muted); padding: 0 10px 0 4px; border-left: 1px solid var(--line-2); align-self: stretch; display: flex; align-items: center; white-space: nowrap; }

/* ---------- result bar ---------- */
.dbar {
  position: sticky; top: 0; z-index: 20;
  display: grid; grid-template-columns: auto 1fr 1fr 1.3fr; align-items: center; gap: 10px 28px;
  padding: 12px 18px; margin-bottom: 18px; border-radius: 14px;
  background: linear-gradient(180deg, rgba(20, 30, 54, .96), rgba(16, 24, 44, .96));
  border: 1px solid var(--cyan-line); box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .9), 0 0 0 1px rgba(56, 217, 245, .06);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  animation: rise .5s .16s ease-out both; overflow: hidden;
}
.dbar.stuck { border-radius: 0 0 14px 14px; box-shadow: 0 16px 40px -18px rgba(0, 0, 0, 1), 0 0 24px rgba(56, 217, 245, .12); }
.dbar::before { content: ""; position: absolute; left: 0; top: 0; height: 2px; width: 0; opacity: 0; background: linear-gradient(90deg, var(--cyan), var(--lime)); box-shadow: 0 0 10px var(--cyan); pointer-events: none; }
.dbar.busy::before { animation: busy .5s ease-out; }
@keyframes busy { 0% { width: 0; opacity: 1; } 80% { width: 100%; opacity: 1; } 100% { width: 100%; opacity: 0; } }
.dbar .mode { display: flex; flex-direction: column; gap: 4px; }
.dbar .k { font-family: var(--disp); font-size: 10px; font-weight: 500; letter-spacing: .16em; color: var(--muted); white-space: nowrap; }
.dbar .tag { align-self: flex-start; font-size: 12px; font-weight: 600; color: var(--cyan-ink); padding: 2px 10px; border-radius: 999px; border: 1px solid var(--cyan-line); background: var(--cyan-soft); white-space: nowrap; }
.dbar .tag.warn { color: var(--amber-ink); border-color: var(--amber-line); background: var(--amber-soft); }
.dbar .st { display: flex; align-items: baseline; gap: 10px; min-width: 0; }
.dbar .l { flex: none; font-size: 12px; font-weight: 600; color: var(--fg-2); padding: 2px 8px; border-radius: 999px; background: rgba(10, 16, 32, .5); border: 1px solid var(--line-3); }
.dbar .num { display: flex; align-items: baseline; gap: 6px; min-width: 0; flex-wrap: wrap; }
.dbar .v { font-family: var(--mono); font-size: 24px; font-weight: 600; line-height: 1.1; letter-spacing: -0.03em; font-variant-numeric: tabular-nums; }
.kk { font-family: var(--mono); font-size: 13px; font-weight: 500; color: var(--fg-2); }
.dbar .max .l { color: #06131a; background: var(--cyan); border-color: var(--cyan); box-shadow: 0 0 12px rgba(56, 217, 245, .5); }
.dbar .max .v { font-size: 30px; color: var(--cyan); text-shadow: var(--glow-cyan); }
.dbar .max .kk { color: var(--cyan-ink); }
.dbar .v.pulse { animation: pulse .6s ease-out; }

/* ---------- layout / card ---------- */
.layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 20px; }
.stack { display: grid; gap: 16px; min-width: 0; }
.card {
  position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; box-shadow: var(--shadow);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  animation: rise .55s .12s ease-out both;
}
.card::after {
  content: ""; position: absolute; inset: 6px; border-radius: 10px; pointer-events: none;
  background:
    linear-gradient(var(--cyan-line), var(--cyan-line)) top left / 14px 1px no-repeat,
    linear-gradient(var(--cyan-line), var(--cyan-line)) top left / 1px 14px no-repeat,
    linear-gradient(var(--cyan-line), var(--cyan-line)) bottom right / 14px 1px no-repeat,
    linear-gradient(var(--cyan-line), var(--cyan-line)) bottom right / 1px 14px no-repeat;
  opacity: .8;
}
.card .h { font-family: var(--disp); font-size: 12px; letter-spacing: .14em; color: var(--cyan-ink); padding: 14px 16px 0; }

.sel-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 14px 24px; padding: 16px 16px 4px; }
.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.selwrap { position: relative; }
.selwrap::after { content: ""; position: absolute; right: 12px; top: 50%; width: 8px; height: 8px; border-right: 2px solid var(--lime); border-bottom: 2px solid var(--lime); transform: translateY(-70%) rotate(45deg); pointer-events: none; transition: transform .2s; }
.selwrap:hover::after { transform: translateY(-40%) rotate(45deg); }
select {
  appearance: none; -webkit-appearance: none; width: 100%; min-width: 220px;
  background: var(--input); color: var(--fg); border: 1px solid var(--line-3); border-radius: 10px;
  font-size: 14px; font-weight: 500; padding: 9px 34px 9px 12px; cursor: pointer;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, .4);
  transition: border-color .2s, box-shadow .2s, background .2s;
}
select:hover { border-color: rgba(179, 240, 90, .6); }
select:focus-visible { outline: none; border-color: var(--lime); box-shadow: inset 0 1px 2px rgba(0,0,0,.4), 0 0 0 3px var(--ring), 0 0 18px rgba(179, 240, 90, .25); background: #0a1222; }
select option { background: #0f1830; color: var(--fg); }

/* スロット（1〜4OP目） */
.slots { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 12px 16px 16px; }
.slot { --tone: var(--cyan); position: relative; background: var(--blk); border: 1px solid var(--line-3); border-left: 3px solid var(--tone); border-radius: 12px; padding: 12px 14px 14px; box-shadow: inset 0 1px 0 rgba(255,255,255,.04); transition: border-color .25s, box-shadow .25s, transform .25s; overflow: hidden; animation: pop .35s ease-out both; }
.slot:nth-child(1) { --tone: var(--cyan); }
.slot:nth-child(2) { --tone: var(--blue); animation-delay: .05s; }
.slot:nth-child(3) { --tone: var(--violet); animation-delay: .1s; }
.slot:nth-child(4) { --tone: var(--lime); animation-delay: .15s; }
.slot::before { content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none; background: linear-gradient(135deg, color-mix(in srgb, var(--tone) 10%, transparent), transparent 45%); }
.slot > * { position: relative; }
.slot.on { box-shadow: inset 0 1px 0 rgba(255,255,255,.04), 0 0 0 1px color-mix(in srgb, var(--tone) 40%, transparent), 0 0 22px color-mix(in srgb, var(--tone) 22%, transparent); transform: translateY(-1px); }
.slot.on::after { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: linear-gradient(90deg, transparent, var(--tone), transparent); animation: scan 1.6s linear infinite; opacity: .8; }
.slot .head { display: flex; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.slot .no { font-family: var(--disp); font-size: 11px; letter-spacing: .14em; color: var(--tone); text-shadow: 0 0 10px color-mix(in srgb, var(--tone) 50%, transparent); }
.slot .rate { font-family: var(--mono); font-size: 13px; font-weight: 600; color: var(--faint); padding: 2px 10px; border-radius: 999px; border: 1px solid var(--line-2); background: rgba(10, 16, 32, .5); transition: color .2s, border-color .2s, background .2s; }
.slot.on .rate { color: color-mix(in srgb, var(--tone) 85%, #fff); border-color: color-mix(in srgb, var(--tone) 45%, transparent); background: color-mix(in srgb, var(--tone) 12%, transparent); }
.slot select { min-width: 0; }
.slot .val { margin-top: 8px; font-size: 12px; color: var(--muted); min-height: 1.6em; }
.slot .val b { color: var(--fg); font-family: var(--mono); font-weight: 600; }

.hint { display: flex; gap: 10px; align-items: flex-start; margin: 0 16px 16px; padding: 10px 12px; border-radius: 10px; font-size: 12.5px; color: var(--violet-ink); background: var(--violet-soft); border: 1px solid var(--violet-line); }
.hint .ico { flex: none; width: 18px; height: 18px; border-radius: 50%; display: grid; place-items: center; font-family: var(--disp); font-size: 11px; color: #0b0b1e; background: var(--violet); box-shadow: 0 0 10px var(--violet); }

/* ---------- 計算内訳 ---------- */
.chain { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 12px 16px 4px; min-height: 52px; }
.chain .chip { display: inline-flex; flex-direction: column; gap: 1px; padding: 6px 12px; border-radius: 10px; border: 1px solid var(--line-3); background: rgba(10, 16, 32, .5); animation: pop .3s ease-out both; }
.chain .chip .t { font-size: 11px; color: var(--muted); }
.chain .chip .p { font-family: var(--mono); font-size: 15px; font-weight: 600; color: var(--cyan-ink); }
.chain .op { font-family: var(--mono); font-size: 18px; font-weight: 600; color: var(--lime); text-shadow: 0 0 10px rgba(179, 240, 90, .5); }
.chain .eq { display: inline-flex; flex-direction: column; padding: 6px 14px; border-radius: 10px; border: 1px solid var(--cyan-line); background: var(--cyan-soft); box-shadow: var(--glow-cyan); animation: pop .3s .1s ease-out both; }
.chain .eq .t { font-size: 11px; color: var(--cyan-ink); }
.chain .eq .p { font-family: var(--mono); font-size: 17px; font-weight: 600; color: var(--cyan); }
.chain .empty { font-size: 13px; color: var(--muted); }
.formula { display: grid; gap: 4px; padding: 8px 16px 12px; font-size: 12.5px; color: var(--fg-2); }
.formula b { color: var(--lime-ink); font-weight: 600; margin-right: 6px; }
.odds { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; padding: 0 16px 16px; }
.odds .o { padding: 10px 12px; border-radius: 10px; border: 1px solid var(--line-2); background: rgba(10, 16, 32, .45); animation: pop .3s ease-out both; }
.odds .o .t { font-size: 11px; color: var(--muted); letter-spacing: .04em; }
.odds .o .p { font-family: var(--mono); font-size: 16px; font-weight: 600; color: var(--fg); }
.odds .o .p small { font-size: 11px; color: var(--muted); font-weight: 500; margin-left: 4px; }
.odds .o.hi .p { color: var(--lime-ink); }

/* ---------- 確率表 ---------- */
.ref { border: 1px solid var(--line); border-radius: 14px; background: var(--surface); animation: rise .55s .2s ease-out both; overflow: hidden; }
.ref summary { display: flex; align-items: center; gap: 10px; padding: 12px 16px; cursor: pointer; list-style: none; font-size: 13px; font-weight: 600; color: var(--fg); transition: background .2s; }
.ref summary::-webkit-details-marker { display: none; }
.ref summary:hover { background: rgba(157, 140, 255, .06); }
.ref summary .dot { width: 8px; height: 8px; border-radius: 2px; transform: rotate(45deg); background: var(--violet); box-shadow: 0 0 10px var(--violet); }
.ref summary .sub { margin-left: auto; font-family: var(--mono); font-size: 12px; font-weight: 500; color: var(--violet-ink); }
.ref[open] summary { border-bottom: 1px solid var(--line-2); }
.tables { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 12px 16px; }
.tbl { border: 1px solid var(--line-2); border-radius: 10px; overflow: hidden; background: rgba(10, 16, 32, .4); }
.tbl h3 { margin: 0; padding: 8px 12px; font-family: var(--disp); font-size: 11px; letter-spacing: .14em; color: var(--cyan-ink); background: rgba(56, 217, 245, .08); border-bottom: 1px solid var(--line-2); }
.tbl table { width: 100%; border-collapse: collapse; font-size: 12px; }
.tbl th { text-align: left; font-weight: 500; color: var(--muted); padding: 5px 10px; border-bottom: 1px solid var(--line-2); font-size: 11px; }
.tbl th.n { text-align: right; }
.tbl td { padding: 4px 10px; border-bottom: 1px solid rgba(145, 180, 245, .08); color: var(--fg-2); }
.tbl td.n { font-family: var(--mono); text-align: right; font-variant-numeric: tabular-nums; white-space: nowrap; }
.tbl td.n.act { color: var(--cyan); font-weight: 600; }
.tbl tr.sel td { background: var(--cyan-soft); color: var(--fg); }
.tbl tr:last-child td { border-bottom: 0; }
.ref .note { margin: 0; padding: 0 16px 14px; font-size: 12px; color: var(--muted); }

footer { margin-top: 28px; text-align: center; font-size: 12px; color: var(--faint); }

/* ---------- ページ遷移（ワープ） ---------- */
.warp { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; pointer-events: none; opacity: 0; background: radial-gradient(circle at 50% 50%, rgba(56, 217, 245, .25), var(--bg) 70%); transition: opacity .25s; }
.warp .ring { position: absolute; width: 12vmax; height: 12vmax; border-radius: 50%; border: 2px solid var(--cyan); box-shadow: 0 0 24px var(--cyan); opacity: 0; }
.warp .ring:nth-child(2) { border-color: var(--violet); box-shadow: 0 0 24px var(--violet); }
.warp .ring:nth-child(3) { border-color: var(--lime); box-shadow: 0 0 24px var(--lime); }
.warp .txt { font-family: var(--disp); font-size: 13px; letter-spacing: .5em; color: var(--cyan-ink); text-shadow: var(--glow-cyan); opacity: 0; }
.warp-out .warp { opacity: 1; pointer-events: auto; }
.warp-out .warp .ring { animation: ring-out .65s ease-out forwards; }
.warp-out .warp .ring:nth-child(2) { animation-delay: .1s; }
.warp-out .warp .ring:nth-child(3) { animation-delay: .2s; }
.warp-out .warp .txt { animation: blink .5s ease-in-out infinite, rise .3s ease-out both; }
.warp-out .wrap { animation: zoom-away .65s ease-in forwards; }
@keyframes ring-out { from { transform: scale(.2); opacity: 1; } to { transform: scale(12); opacity: 0; } }
@keyframes zoom-away { to { transform: scale(1.06); opacity: 0; filter: blur(6px); } }
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 220ms ease-in both fade-out; }
::view-transition-new(root) { animation: 320ms ease-out both fade-in; }
@keyframes fade-out { to { opacity: 0; } }
@keyframes fade-in { from { opacity: 0; transform: scale(.985); } }

/* ---------- responsive ---------- */
@media (max-width: 900px) {
  .dbar { grid-template-columns: 1fr 1fr; gap: 8px 16px; padding: 10px 14px; margin: 0 -16px 14px; border-radius: 0; border-left: 0; border-right: 0; }
  .dbar.stuck { border-radius: 0; }
  .dbar .mode { grid-column: 1 / -1; flex-direction: row; align-items: center; gap: 10px; }
  .dbar .st { flex-direction: column; align-items: flex-start; gap: 2px; }
  .dbar .v { font-size: 20px; }
  .dbar .max { grid-column: 1 / -1; }
  .dbar .max .v { font-size: 26px; }
  .slots, .tables { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .top { padding-block: 18px 12px; }
  .bar .ghost { margin-left: 0; }
  .bar .price { width: 100%; }
  .pin { flex: 1; }
  .pin input { width: 100%; }
  .sel-row { padding: 12px 12px 4px; }
  .sel-row .field { width: 100%; }
  select { min-width: 0; }
  .slots { padding: 10px 12px 12px; gap: 10px; }
  .slot { padding: 10px 12px 12px; }
  .hint { margin: 0 12px 12px; }
  .chain, .formula, .odds { padding-left: 12px; padding-right: 12px; }
  .tables { padding: 10px 12px; }
}

[hidden] { display: none !important; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .top, .bar, .card, .ref, .slot, .dbar { opacity: 1; transform: none; }
}
