.fx-seesaw { --fx-angle: -16deg; --fx-p: 0; display: grid; gap: 14px; }
.fx-seesaw:has(#fx-seesaw-lottery:checked) { --fx-angle: -15deg; --fx-p: 0.02; }
.fx-seesaw:has(#fx-seesaw-six:checked) { --fx-angle: -10deg; --fx-p: 0.1666667; }
.fx-seesaw:has(#fx-seesaw-odd:checked), .fx-seesaw:has(#fx-seesaw-even:checked) { --fx-angle: 0deg; --fx-p: 0.5; }
.fx-seesaw:has(#fx-seesaw-rain:checked) { --fx-angle: 10deg; --fx-p: 0.75; }
.fx-seesaw:has(#fx-seesaw-birthday:checked) { --fx-angle: 16deg; --fx-p: 1; }
.fx-seesaw .fx-steps { margin: 0; padding-left: 24px; }
.fx-seesaw .fx-steps li + li { margin-top: 6px; }
.fx-seesaw .fx-goal, .fx-seesaw .fx-assumptions { margin: 0; color: var(--fx-ink); line-height: 1.45; }
.fx-seesaw .fx-assumptions { font-size: 14px; }
.fx-seesaw .fx-controls { min-width: 0; margin: 0; padding: 0; border: 0; }
.fx-seesaw .fx-controls legend { padding: 0; margin-bottom: 10px; font-weight: 800; }
.fx-seesaw .fx-options { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.fx-seesaw .fx-btn { display: flex; align-items: center; justify-content: flex-start; box-sizing: border-box; min-width: 0; min-height: 44px; padding: 10px 12px; border: 2px solid var(--fx-muted); border-radius: 10px; background: var(--fx-paper); color: var(--fx-ink); font-size: 14px; line-height: 1.3; text-align: left; cursor: pointer; }
.fx-seesaw .fx-btn:has(input:checked) { background: var(--fx-sky-pale); color: var(--fx-ink); border-color: var(--fx-ink); }
.fx-seesaw .fx-btn:has(input:focus-visible) { outline: 3px solid var(--fx-grape); outline-offset: 3px; }
.fx-seesaw .fx-scene { position: relative; box-sizing: border-box; height: 440px; min-width: 0; color: var(--fx-ink); }
.fx-seesaw .fx-down { position: absolute; top: 12px; left: 8px; right: 8px; margin: 0; text-align: center; font-size: 14px; font-weight: 800; }
.fx-seesaw .fx-badge { position: absolute; top: 42px; left: 12px; right: 12px; max-width: 280px; margin: 0 auto; padding: 5px; border: 2px solid var(--fx-muted); border-radius: 8px; background: var(--fx-paper); font-size: 13px; font-weight: 800; text-align: center; }
.fx-seesaw:has(#fx-seesaw-odd:checked) .fx-badge, .fx-seesaw:has(#fx-seesaw-even:checked) .fx-badge { background: var(--fx-mint); border-color: var(--fx-ink); }
.fx-seesaw .fx-world { position: absolute; top: 80px; left: 0; right: 0; height: 235px; max-width: 560px; margin: 0 auto; perspective: 800px; }
.fx-seesaw .fx-pivot { position: absolute; top: 150px; left: 50%; width: 72px; height: 68px; margin-left: -36px; background: var(--fx-sun); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.fx-seesaw .fx-pivot-label { position: absolute; top: 220px; left: 0; right: 0; text-align: center; font-size: 12px; }
.fx-seesaw .fx-beam { position: absolute; top: 134px; left: 18%; width: 64%; height: 18px; transform-style: preserve-3d; transform: rotateZ(var(--fx-angle)) rotateY(-8deg) rotateX(-12deg); transition: transform 0.6s; }
.fx-seesaw .fx-timber { position: absolute; box-sizing: border-box; border: 2px solid var(--fx-ink); }
.fx-seesaw .fx-front { top: 0; left: 0; width: 100%; height: 18px; background: var(--fx-sun); transform: translateZ(8px); }
.fx-seesaw .fx-front::after { content: ""; position: absolute; top: 6px; left: 10%; right: 10%; border-top: 1px solid var(--fx-muted); }
.fx-seesaw .fx-top { top: -8px; left: 0; width: 100%; height: 16px; background: var(--fx-sun-pale); transform: rotateX(90deg); }
.fx-seesaw .fx-end { top: 0; left: calc(100% - 8px); width: 16px; height: 18px; background: var(--fx-sun); transform: rotateY(90deg); }
.fx-seesaw .fx-seat { position: absolute; bottom: 18px; box-sizing: border-box; width: 48%; height: 100px; display: grid; grid-template-rows: auto minmax(0, 1fr); gap: 4px; padding: 5px 3px; border: 2px solid var(--fx-ink); border-radius: 7px; font-size: 12px; line-height: 1.15; text-align: center; transform: translateZ(10px); background: var(--fx-paper); }
.fx-seesaw .fx-left-seat { left: -6%; background: var(--fx-sun-pale); }
.fx-seesaw .fx-right-seat { right: -6%; background: var(--fx-sky-pale); }
.fx-seesaw:has(#fx-seesaw-empty:checked) .fx-right-seat { border-style: dashed; background: var(--fx-paper); }
.fx-seesaw .fx-coin { box-sizing: border-box; display: grid; place-items: center; align-self: center; justify-self: center; width: 32px; height: 32px; border: 2px solid var(--fx-ink); border-radius: 50%; background: var(--fx-sun); font-size: 18px; font-weight: 800; }
.fx-seesaw .fx-pieces { display: grid; min-width: 0; }
.fx-seesaw .fx-state { grid-area: 1 / 1; visibility: hidden; }
.fx-seesaw .fx-pieces .fx-state { display: grid; align-content: center; justify-items: center; gap: 3px; min-width: 0; }
.fx-seesaw .fx-die { display: grid; place-items: center; box-sizing: border-box; width: 26px; height: 26px; border: 1px solid var(--fx-ink); border-radius: 4px; background: var(--fx-paper); font-size: 14px; font-weight: 800; }
.fx-seesaw .fx-faces { display: flex; gap: 2px; justify-content: center; }
.fx-seesaw .fx-faces .fx-die { width: 16px; height: 22px; font-size: 12px; }
.fx-seesaw .fx-ticket { padding: 3px; border: 1px dashed var(--fx-ink); background: var(--fx-sun-pale); }
.fx-seesaw .fx-icon { width: 44px; height: 28px; }
.fx-seesaw .fx-icon * { fill: var(--fx-sun-pale); stroke: var(--fx-ink); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.fx-seesaw .fx-icon path { fill: none; }
.fx-seesaw .fx-scale { position: absolute; bottom: 14px; left: 16px; right: 16px; height: 100px; font-size: 12px; }
.fx-seesaw .fx-scale > b { display: block; margin-bottom: 4px; }
.fx-seesaw .fx-scale-row { display: flex; gap: 8px; align-items: center; height: 22px; }
.fx-seesaw .fx-scale-row > span { flex: 0 0 72px; }
.fx-seesaw .fx-numbers, .fx-seesaw .fx-track { position: relative; flex: 1 1 0; min-width: 0; height: 18px; margin-right: 8px; }
.fx-seesaw .fx-numbers span { position: absolute; top: 0; transform: translateX(-50%); }
.fx-seesaw .fx-zero { left: 0; }
.fx-seesaw .fx-half { left: 50%; }
.fx-seesaw .fx-one { left: 100%; }
.fx-seesaw .fx-track::before { content: ""; position: absolute; top: 8px; left: 0; right: 0; border-top: 2px solid var(--fx-muted); }
.fx-seesaw .fx-tail-dot, .fx-seesaw .fx-event-dot { position: absolute; top: 3px; box-sizing: border-box; width: 12px; height: 12px; border: 1px solid var(--fx-ink); }
.fx-seesaw .fx-tail-dot { left: 50%; border-radius: 50%; background: var(--fx-coral); transform: translateX(-50%); }
.fx-seesaw .fx-event-dot { left: calc(var(--fx-p) * 100%); background: var(--fx-grape); transform: translateX(-50%) rotate(45deg); transition: left 0.6s; }
.fx-seesaw:has(#fx-seesaw-empty:checked) .fx-event-dot { visibility: hidden; }
.fx-seesaw .fx-messages { display: grid; }
.fx-seesaw .fx-messages .fx-state { margin: 0; padding: 12px; border: 2px solid var(--fx-ink); border-radius: 10px; color: var(--fx-ink); font-size: 16px; line-height: 1.45; }
.fx-seesaw .fx-messages .fx-note { background: var(--fx-sky-pale); }
.fx-seesaw .fx-messages .fx-right { background: var(--fx-mint-pale); }
.fx-seesaw:has(#fx-seesaw-empty:checked) .fx-s-empty, .fx-seesaw:has(#fx-seesaw-seven:checked) .fx-s-seven, .fx-seesaw:has(#fx-seesaw-lottery:checked) .fx-s-lottery, .fx-seesaw:has(#fx-seesaw-six:checked) .fx-s-six, .fx-seesaw:has(#fx-seesaw-odd:checked) .fx-s-odd, .fx-seesaw:has(#fx-seesaw-even:checked) .fx-s-even, .fx-seesaw:has(#fx-seesaw-rain:checked) .fx-s-rain, .fx-seesaw:has(#fx-seesaw-birthday:checked) .fx-s-birthday { visibility: visible; }
@container (max-width: 480px) { .fx-seesaw .fx-options { grid-template-columns: 1fr; } }