.fx-boxes { --fx-open: 0; --fx-done: 0; display: grid; gap: 16px; }
.fx-boxes .fx-goal { margin: 0; }
.fx-boxes .fx-note ol { margin: 0; padding-left: 24px; }
.fx-boxes .fx-controls { min-width: 0; margin: 0; padding: 0; border: 0; }
.fx-boxes .fx-controls legend { padding: 0; margin-bottom: 12px; font-weight: 800; }
.fx-boxes .fx-controls .fx-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.fx-boxes .fx-btn { min-height: 44px; box-sizing: border-box; padding: 10px; color: var(--fx-ink); }
.fx-boxes .fx-btn:has(input:checked) { background: var(--fx-mint-pale); color: var(--fx-ink); border-color: var(--fx-ink); }
.fx-boxes .fx-btn:focus-within { outline: 3px solid var(--fx-ink); outline-offset: 3px; }
.fx-boxes .fx-says, .fx-boxes .fx-feedback { display: grid; min-width: 0; }
.fx-boxes .fx-says > p, .fx-boxes .fx-feedback > p { grid-area: 1 / 1; margin: 0; }
.fx-boxes .fx-open, .fx-boxes .fx-mid, .fx-boxes .fx-all, .fx-boxes .fx-found { visibility: hidden; }
.fx-boxes:has(input:checked) .fx-start { visibility: hidden; }
.fx-boxes:has(input:checked) .fx-mid { visibility: visible; }
.fx-boxes:has(#fx-boxes-car:checked) .fx-car, .fx-boxes:has(#fx-boxes-sheep:checked) .fx-sheep, .fx-boxes:has(#fx-boxes-tooth:checked) .fx-tooth, .fx-boxes:has(#fx-boxes-mouse:checked) .fx-mouse, .fx-boxes:has(#fx-boxes-woman:checked) .fx-woman, .fx-boxes:has(#fx-boxes-fish:checked) .fx-fish { --fx-open: 1; }
.fx-boxes:has(#fx-boxes-car:checked) .fx-car .fx-open, .fx-boxes:has(#fx-boxes-sheep:checked) .fx-sheep .fx-open, .fx-boxes:has(#fx-boxes-tooth:checked) .fx-tooth .fx-open, .fx-boxes:has(#fx-boxes-mouse:checked) .fx-mouse .fx-open, .fx-boxes:has(#fx-boxes-woman:checked) .fx-woman .fx-open, .fx-boxes:has(#fx-boxes-fish:checked) .fx-fish .fx-open { visibility: visible; }
.fx-boxes:has(#fx-boxes-car:checked) .fx-car .fx-closed, .fx-boxes:has(#fx-boxes-sheep:checked) .fx-sheep .fx-closed, .fx-boxes:has(#fx-boxes-tooth:checked) .fx-tooth .fx-closed, .fx-boxes:has(#fx-boxes-mouse:checked) .fx-mouse .fx-closed, .fx-boxes:has(#fx-boxes-woman:checked) .fx-woman .fx-closed, .fx-boxes:has(#fx-boxes-fish:checked) .fx-fish .fx-closed { visibility: hidden; }
.fx-boxes:has(#fx-boxes-car:checked) .fx-search { visibility: hidden; }
.fx-boxes:has(#fx-boxes-car:checked) .fx-found { visibility: inherit; }
.fx-boxes:has(#fx-boxes-car:checked):has(#fx-boxes-sheep:checked):has(#fx-boxes-tooth:checked):has(#fx-boxes-mouse:checked):has(#fx-boxes-woman:checked):has(#fx-boxes-fish:checked) { --fx-done: 1; }
.fx-boxes:has(#fx-boxes-car:checked):has(#fx-boxes-sheep:checked):has(#fx-boxes-tooth:checked):has(#fx-boxes-mouse:checked):has(#fx-boxes-woman:checked):has(#fx-boxes-fish:checked) .fx-mid { visibility: hidden; }
.fx-boxes:has(#fx-boxes-car:checked):has(#fx-boxes-sheep:checked):has(#fx-boxes-tooth:checked):has(#fx-boxes-mouse:checked):has(#fx-boxes-woman:checked):has(#fx-boxes-fish:checked) .fx-all { visibility: visible; }
.fx-boxes .fx-room { height: 500px; box-sizing: border-box; padding: 16px; display: grid; grid-template-rows: 24px 1fr; gap: 16px; color: var(--fx-ink); }
.fx-boxes .fx-shelves { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); grid-template-rows: repeat(2, 200px); gap: 16px; }
.fx-boxes .fx-card { min-width: 0; margin: 0; display: grid; grid-template-rows: 52px 148px; border-bottom: 5px solid var(--fx-ink); }
.fx-boxes .fx-card figcaption { display: grid; align-content: end; justify-items: center; text-align: center; font-weight: 800; font-size: 16px; }
.fx-boxes .fx-sticky { display: block; background: var(--fx-sun-pale); color: var(--fx-ink); font-size: 12px; line-height: 16px; padding: 2px; }
.fx-boxes .fx-space { perspective: 650px; position: relative; min-width: 0; }
.fx-boxes .fx-box { position: relative; top: 30px; margin: 0 auto; width: min(144px, 90%); height: 100px; transform-style: preserve-3d; transform: rotateX(20deg) rotateY(-8deg); box-shadow: 0 0 0 calc(var(--fx-done) * 5px) var(--fx-coral); }
.fx-boxes .fx-car .fx-box { box-shadow: 0 0 0 calc(var(--fx-done) * 5px) var(--fx-mint); }
.fx-boxes .fx-base, .fx-boxes .fx-lid { position: absolute; inset: 0; border: 2px solid var(--fx-ink); box-sizing: border-box; }
.fx-boxes .fx-base { background: var(--fx-sun-pale); transform: translateZ(-26px); }
.fx-boxes .fx-front { position: absolute; top: 100%; width: 100%; height: 26px; box-sizing: border-box; background: var(--fx-sun); border: 2px solid var(--fx-ink); transform-origin: center top; transform: rotateX(-90deg); }
.fx-boxes .fx-side { position: absolute; top: 0; left: 100%; width: 26px; height: 100%; box-sizing: border-box; background: var(--fx-sun-pale); border: 2px solid var(--fx-ink); transform-origin: left center; transform: rotateY(90deg); }
.fx-boxes .fx-lid { display: grid; justify-items: center; align-content: center; gap: 2px; background: var(--fx-sun); transform-origin: center top; transform: rotateX(calc(var(--fx-open) * -110deg)); transition: transform 0.6s; }
.fx-boxes .fx-lid b { font-size: 18px; }
.fx-boxes .fx-lid svg { width: 45px; height: 40px; }
.fx-boxes .fx-inside { position: absolute; inset: 3px; display: grid; justify-items: center; align-content: center; gap: 1px; background: var(--fx-paper); color: var(--fx-ink); opacity: var(--fx-open); transform: translateZ(calc(-22px + var(--fx-open) * 30px)); transition: opacity 0.25s 0.2s, transform 0.5s, visibility 0.2s 0.2s; }
.fx-boxes .fx-inside svg { width: min(94px, 100%); height: 36px; }
.fx-boxes .fx-inside strong { font-size: 17px; line-height: 20px; }
.fx-boxes .fx-inside small { display: block; font-size: 12px; line-height: 14px; }
.fx-boxes .fx-room svg path { fill: none; stroke: var(--fx-ink); stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.fx-boxes .fx-change { background: var(--fx-mint); color: var(--fx-ink); padding: 0 2px; }
.fx-boxes .fx-strike { text-decoration: line-through; text-decoration-thickness: 2px; }
.fx-boxes .fx-reports { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.fx-boxes .fx-report { display: grid; grid-template-rows: auto auto; gap: 8px; align-content: start; min-width: 0; }
@container (max-width: 480px) { .fx-boxes .fx-controls .fx-row, .fx-boxes .fx-reports { grid-template-columns: 1fr; } .fx-boxes .fx-room { height: 1360px; } .fx-boxes .fx-shelves { grid-template-columns: 1fr; grid-template-rows: repeat(6, 200px); } }
@media (prefers-reduced-motion: reduce) { .fx-boxes .fx-lid, .fx-boxes .fx-inside { transition: none; } }