.fx-coins { display: grid; gap: 16px; }
.fx-coins .fx-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.fx-coins .fx-goal { margin: 0; color: var(--fx-ink); }
.fx-coins .fx-controls { border: 0; padding: 0; margin: 0; min-width: 0; }
.fx-coins .fx-controls legend { padding: 0; margin-bottom: 12px; font-weight: 800; }
.fx-coins .fx-actions { display: grid; }
.fx-coins .fx-choice { grid-area: 1 / 1; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 12px; visibility: hidden; min-width: 0; }
.fx-coins .fx-state { visibility: hidden; }
.fx-coins .fx-btn, .fx-coins .fx-end { box-sizing: border-box; display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 64px; min-width: 0; padding: 8px; font-size: 14px; white-space: normal; color: var(--fx-ink); text-align: center; }
.fx-coins .fx-drop { background: var(--fx-sun-pale); }
.fx-coins .fx-undo { background: var(--fx-mint-pale); }
.fx-coins .fx-end { border: 2px dashed var(--fx-muted); border-radius: 12px; }
.fx-coins .fx-token { box-sizing: border-box; width: 36px; height: 36px; flex: 0 0 36px; display: grid; place-items: center; border: 2px solid var(--fx-muted); border-radius: 50%; background: var(--fx-paper); box-shadow: 0 0 0 4px var(--fx-sun); font-weight: 800; }
.fx-coins .fx-choice:has(input:focus-visible) .fx-btn { outline: 3px solid var(--fx-ink); outline-offset: 3px; }
.fx-coins .fx-help { margin: 12px 0 0; font-size: 14px; color: var(--fx-ink); }
.fx-coins:has(#fx-coins-c1:not(:checked)) .fx-s0 { visibility: visible; }
.fx-coins:has(#fx-coins-c1:checked):has(#fx-coins-c2:not(:checked)) .fx-s1 { visibility: visible; }
.fx-coins:has(#fx-coins-c2:checked):has(#fx-coins-c3:not(:checked)) .fx-s2 { visibility: visible; }
.fx-coins:has(#fx-coins-c3:checked):has(#fx-coins-c4:not(:checked)) .fx-s3 { visibility: visible; }
.fx-coins:has(#fx-coins-c4:checked):has(#fx-coins-c5:not(:checked)) .fx-s4 { visibility: visible; }
.fx-coins:has(#fx-coins-c5:checked):has(#fx-coins-c6:not(:checked)) .fx-s5 { visibility: visible; }
.fx-coins:has(#fx-coins-c6:checked):has(#fx-coins-c7:not(:checked)) .fx-s6 { visibility: visible; }
.fx-coins:has(#fx-coins-c7:checked):has(#fx-coins-c8:not(:checked)) .fx-s7 { visibility: visible; }
.fx-coins:has(#fx-coins-c8:checked):has(#fx-coins-c9:not(:checked)) .fx-s8 { visibility: visible; }
.fx-coins:has(#fx-coins-c9:checked):has(#fx-coins-c10:not(:checked)) .fx-s9 { visibility: visible; }
.fx-coins:has(#fx-coins-c10:checked) .fx-s10 { visibility: visible; }
.fx-coins .fx-scene { --fx-in: 0; --fx-fill: var(--fx-paper); --fx-from: 25%; --fx-to: 75%; --fx-pile-top: 100px; --fx-in-top: 245px; position: relative; box-sizing: border-box; height: 345px; display: block; color: var(--fx-ink); overflow: hidden; }
.fx-coins .fx-pile-label, .fx-coins .fx-counter, .fx-coins .fx-count-label, .fx-coins .fx-purse-label, .fx-coins .fx-thought { position: absolute; box-sizing: border-box; width: 50%; text-align: center; padding: 0 6px; font-size: 14px; }
.fx-coins .fx-pile-label { left: 0; top: 12px; }
.fx-coins .fx-counter { left: 50%; top: 12px; }
.fx-coins .fx-values { display: grid; margin: 8px auto 0; width: fit-content; min-width: 100px; border: 3px solid var(--fx-ink); border-radius: 10px; background: var(--fx-paper); font-size: 32px; line-height: 1.25; padding: 4px 8px; }
.fx-coins .fx-values span, .fx-coins .fx-thought > span, .fx-coins .fx-says p { grid-area: 1 / 1; }
.fx-coins .fx-count-label { left: 50%; top: 112px; }
.fx-coins .fx-dots { position: absolute; left: 50%; top: 138px; width: 50%; display: flex; justify-content: center; gap: 3px; }
.fx-coins .fx-dot { box-sizing: border-box; width: 10px; height: 10px; flex: 0 0 10px; border: 1px solid var(--fx-ink); border-radius: 50%; background: var(--fx-fill); }
.fx-coins .fx-thought { left: 50%; top: 164px; display: grid; font-weight: 800; }
.fx-coins .fx-thought > span { border: 2px solid var(--fx-ink); border-radius: 16px; padding: 4px; background: var(--fx-sun-pale); }
.fx-coins .fx-cross { text-decoration: line-through; text-decoration-color: var(--fx-coral); text-decoration-thickness: 3px; }
.fx-coins .fx-purse { position: absolute; box-sizing: border-box; left: calc(var(--fx-to) - 65px); top: 205px; width: 130px; height: 80px; border: 3px solid var(--fx-ink); border-radius: 16px 16px 36px 36px; background: var(--fx-coral-pale); }
.fx-coins .fx-purse::before { content: ""; position: absolute; box-sizing: border-box; left: -3px; top: -12px; width: 130px; height: 24px; border: 3px solid var(--fx-ink); border-radius: 50%; background: var(--fx-paper); }
.fx-coins .fx-coin { position: absolute; box-sizing: border-box; left: calc(var(--fx-from) + var(--fx-in) * (var(--fx-to) - var(--fx-from)) - 23px); top: calc((1 - var(--fx-in)) * (var(--fx-pile-top) + var(--fx-i) * 8px) + var(--fx-in) * (var(--fx-in-top) - var(--fx-i) * 4px)); width: 46px; height: 46px; display: grid; place-items: center; border: 3px solid var(--fx-muted); border-radius: 50%; background: var(--fx-paper); font-size: 15px; font-weight: 800; z-index: calc(11 - var(--fx-i)); transition: left 0.45s, top 0.45s, opacity 0.25s 0.45s, transform 0.25s 0.45s; }
.fx-coins:has(#fx-coins-c1:checked) .fx-c1, .fx-coins:has(#fx-coins-c2:checked) .fx-c2, .fx-coins:has(#fx-coins-c3:checked) .fx-c3, .fx-coins:has(#fx-coins-c4:checked) .fx-c4, .fx-coins:has(#fx-coins-c5:checked) .fx-c5, .fx-coins:has(#fx-coins-c6:checked) .fx-c6, .fx-coins:has(#fx-coins-c7:checked) .fx-c7, .fx-coins:has(#fx-coins-c8:checked) .fx-c8, .fx-coins:has(#fx-coins-c9:checked) .fx-c9, .fx-coins:has(#fx-coins-c10:checked) .fx-c10 { --fx-in: 1; --fx-fill: var(--fx-mint); }
.fx-coins .fx-gold { position: absolute; box-sizing: border-box; left: calc(var(--fx-to) - 30px); top: 211px; width: 60px; height: 60px; display: grid; place-items: center; border: 4px solid var(--fx-ink); border-radius: 50%; background: var(--fx-sun); font-size: 26px; font-weight: 800; opacity: 0; transform: scale(0.3); z-index: 12; transition: opacity 0.3s 0.7s, transform 0.3s 0.7s; }
.fx-coins:has(#fx-coins-c10:checked) .fx-coin { opacity: 0; transform: scale(0.2); }
.fx-coins:has(#fx-coins-c10:checked) .fx-gold { opacity: 1; transform: scale(1); }
.fx-coins .fx-purse-label { left: 50%; top: 306px; }
.fx-coins .fx-says { display: grid; }
.fx-coins .fx-says p { margin: 0; }
@container (max-width: 480px) { .fx-coins .fx-choice { grid-template-columns: minmax(0, 1fr); gap: 8px; } .fx-coins .fx-scene { --fx-from: 50%; --fx-to: 50%; --fx-pile-top: 35px; --fx-in-top: 455px; height: 540px; } .fx-coins .fx-pile-label, .fx-coins .fx-counter, .fx-coins .fx-count-label, .fx-coins .fx-purse-label, .fx-coins .fx-thought { left: 0; width: 100%; } .fx-coins .fx-counter { top: 222px; } .fx-coins .fx-count-label { top: 322px; } .fx-coins .fx-dots { left: 0; top: 348px; width: 100%; } .fx-coins .fx-thought { top: 374px; padding: 0 45px; } .fx-coins .fx-purse { top: 415px; } .fx-coins .fx-gold { top: 421px; } .fx-coins .fx-purse-label { top: 516px; } }
@media (prefers-reduced-motion: reduce) { .fx-coins .fx-coin, .fx-coins .fx-gold { transition: none; } }