.fx-crates{--fx-c21:0;--fx-c22:0;--fx-c23:0;--fx-c24:0;display:grid;gap:14px;}
.fx-crates:has(#fx-crates-n21:checked){--fx-c21:1;}
.fx-crates:has(#fx-crates-n22:checked){--fx-c21:1;--fx-c22:1;}
.fx-crates:has(#fx-crates-n23:checked){--fx-c21:1;--fx-c22:1;--fx-c23:1;}
.fx-crates:has(#fx-crates-n24:checked){--fx-c21:1;--fx-c22:1;--fx-c23:1;--fx-c24:1;}
.fx-crates .fx-crates-steps{margin:0;padding-left:24px;font-size:16px;line-height:1.5;}
.fx-crates .fx-crates-goal,.fx-crates .fx-crates-hint{margin:0;font-size:16px;line-height:1.5;}
.fx-crates .fx-crates-controls{min-width:0;padding:0;margin:0;border:0;}
.fx-crates .fx-crates-controls legend{padding:0;margin-bottom:10px;font-size:16px;font-weight:800;}
.fx-crates .fx-row{display:flex;flex-wrap:wrap;gap:8px;}
.fx-crates .fx-btn{box-sizing:border-box;min-width:38px;min-height:44px;padding:8px 10px;font-size:16px;line-height:24px;color:var(--fx-ink);background:var(--fx-paper);cursor:pointer;}
.fx-crates .fx-btn:has(input:checked){color:var(--fx-ink);background:var(--fx-sun);}
.fx-crates .fx-btn:has(input:focus-visible){outline:3px solid var(--fx-ink);outline-offset:3px;}
.fx-crates .fx-crates-scene{box-sizing:border-box;height:520px;padding:12px;display:grid;grid-template-rows:24px 1fr;gap:10px;color:var(--fx-ink);}
.fx-crates .fx-crates-total{margin:0;font-size:16px;line-height:24px;text-align:center;}
.fx-crates .fx-crates-layout{display:grid;grid-template-columns:minmax(0, 1fr) minmax(0, 1fr);gap:14px;}
.fx-crates .fx-crates-stackpanel{min-width:0;display:grid;grid-template-rows:60px 400px;}
.fx-crates .fx-crates-caption{margin:0;text-align:center;font-size:14px;line-height:18px;}
.fx-crates .fx-crates-caption small{font-size:12px;line-height:16px;}
.fx-crates .fx-crates-view{height:400px;display:grid;place-items:end center;perspective:700px;}
.fx-crates .fx-crates-tower{position:relative;width:112px;height:384px;transform-style:preserve-3d;transform-origin:center bottom;transform:rotateX(-4deg) rotateY(-14deg);}
.fx-crates .fx-crates-box{--fx-show:1;position:absolute;left:0;bottom:calc((var(--fx-level) - 1) * 16px);box-sizing:border-box;width:112px;height:16px;padding:2px 3px;display:flex;align-items:center;gap:2px;border:1px solid var(--fx-ink);background:var(--fx-sun-pale);transform-style:preserve-3d;transform:translate3d(0, calc((1 - var(--fx-show)) * -24px), calc((1 - var(--fx-show)) * 12px)) scale(var(--fx-show));opacity:var(--fx-show);transition:transform 0.45s, opacity 0.3s;}
.fx-crates .fx-crates-box::before{content:"";position:absolute;box-sizing:border-box;top:0;left:0;width:100%;height:12px;border:1px solid var(--fx-ink);background:var(--fx-sun);transform-origin:top;transform:rotateX(-90deg);}
.fx-crates .fx-crates-box::after{content:"";position:absolute;box-sizing:border-box;top:0;left:100%;width:12px;height:100%;border:1px solid var(--fx-ink);background:var(--fx-sun);transform-origin:left;transform:rotateY(90deg);}
.fx-crates .fx-crates-box > span{flex:0 0 16px;font-size:12px;line-height:12px;font-weight:800;text-align:center;}
.fx-crates .fx-crates-box i,.fx-crates .fx-crates-floor i{position:relative;display:block;box-sizing:border-box;width:8px;height:8px;border:1px solid var(--fx-ink);border-radius:45%;background:var(--fx-coral);}
.fx-crates .fx-crates-box i{flex:0 0 8px;}
.fx-crates .fx-crates-box i::before,.fx-crates .fx-crates-floor i::before{content:"";position:absolute;top:-3px;left:45%;width:1px;height:3px;background:var(--fx-ink);}
.fx-crates .fx-crates-extra21{--fx-show:var(--fx-c21);}
.fx-crates .fx-crates-extra22{--fx-show:var(--fx-c22);}
.fx-crates .fx-crates-extra23{--fx-show:var(--fx-c23);}
.fx-crates .fx-crates-extra24{--fx-show:var(--fx-c24);}
.fx-crates .fx-crates-partial{background:var(--fx-mint-pale);}
.fx-crates .fx-crates-partial i:nth-of-type(n + 3),.fx-crates .fx-crates-empty i{background:var(--fx-paper);border:1px dashed var(--fx-muted);}
.fx-crates .fx-crates-partial i:nth-of-type(n + 3)::before,.fx-crates .fx-crates-empty i::before{visibility:hidden;}
.fx-crates .fx-crates-empty,.fx-crates .fx-crates-empty::before,.fx-crates .fx-crates-empty::after{background:var(--fx-paper);border-color:var(--fx-muted);}
.fx-crates .fx-crates-floorpanel{min-width:0;display:flex;flex-direction:column;gap:8px;}
.fx-crates .fx-crates-floorpanel .fx-crates-caption{flex:0 0 60px;}
.fx-crates .fx-crates-floor{box-sizing:border-box;width:118px;height:90px;padding:0 8px 8px;border-bottom:2px solid var(--fx-ink);display:flex;flex-wrap:wrap;align-content:flex-start;gap:8px;align-self:center;flex:0 0 90px;}
.fx-crates .fx-crates-floor i{width:14px;height:14px;}
.fx-crates:has(#fx-crates-n21:checked) .fx-crates-floor i:nth-of-type(n + 11),.fx-crates:has(#fx-crates-n22:checked) .fx-crates-floor i:nth-of-type(n + 3),.fx-crates:has(#fx-crates-n23:checked) .fx-crates-floor i,.fx-crates:has(#fx-crates-n24:checked) .fx-crates-floor i{visibility:hidden;}
.fx-crates:has(#fx-crates-n22:checked) .fx-crates-floor i{outline:2px solid var(--fx-coral);outline-offset:3px;}
.fx-crates .fx-crates-floorcount,.fx-crates .fx-crates-readout,.fx-crates .fx-crates-feedback{display:grid;min-width:0;}
.fx-crates .fx-crates-floorcount{flex:0 0 44px;}
.fx-crates .fx-crates-state{display:block;grid-area:1 / 1;visibility:hidden;margin:0;}
.fx-crates .fx-crates-floorcount p{font-size:16px;line-height:20px;text-align:center;}
.fx-crates .fx-crates-readout .fx-score{font-size:20px;line-height:1.4;color:var(--fx-ink);}
.fx-crates .fx-crates-readlabel{display:block;font-size:14px;}
.fx-crates .fx-crates-detail{display:block;font-size:14px;line-height:1.4;font-weight:400;}
.fx-crates .fx-crates-feedback p{padding:12px;font-size:16px;line-height:1.5;color:var(--fx-ink);}
.fx-crates:has(#fx-crates-n20:checked) .fx-crates-s20,.fx-crates:has(#fx-crates-n21:checked) .fx-crates-s21,.fx-crates:has(#fx-crates-n22:checked) .fx-crates-s22,.fx-crates:has(#fx-crates-n23:checked) .fx-crates-s23,.fx-crates:has(#fx-crates-n24:checked) .fx-crates-s24{visibility:visible;}
@container (max-width:480px){.fx-crates .fx-crates-scene{height:730px;}.fx-crates .fx-crates-layout{grid-template-columns:1fr;grid-template-rows:460px 190px;}.fx-crates .fx-crates-floorpanel .fx-crates-caption{flex-basis:36px;}}
@media (prefers-reduced-motion:reduce){.fx-crates .fx-crates-box{transition:none;}}