/* Keep the requested rounding place above the action hint in the hierarchy. */
.sweets-layout .order-sign{padding:12px 14px;background:#fffdf6;border-color:#d994b5}
.rounding-order{display:flex;align-items:center;justify-content:center;gap:12px;line-height:1.35}
.rounding-order>strong{display:block;padding:5px 17px 7px;color:#fffaf6;background:#994d78;border:2px solid #7b3b60;border-radius:14px;box-shadow:0 3px 0 #6b33542b;font-size:clamp(28px,3vw,38px);white-space:nowrap}
.rounding-order>span{font-size:clamp(16px,1.8vw,22px);text-align:left;font-weight:800;color:#68415b}
.sweets-layout .order-sign>small{margin-top:7px;font-size:13px;color:#637784}.sweets-layout .order-sign>small>b{font-size:17px;color:#344e62;font-variant-numeric:tabular-nums;letter-spacing:.02em}
.sweets-layout .sweet-aim-hint{font-size:clamp(15px,1.5vw,19px);line-height:1.4;margin-top:8px;padding:7px 6px;background:#f6edf4;border:0;border-radius:10px;box-shadow:none;color:#79546c}.sweets-layout .sweet-aim-hint>span:first-child{display:none}
.sweets-level{display:flex;align-items:center;gap:10px}.sweet-lives{display:inline-flex;gap:5px;align-items:baseline;padding:3px 10px;border:1px solid #d3a2b8;border-radius:20px;background:#fff3f5;color:#784660;white-space:nowrap;font-size:12px}.sweet-lives b{font-size:20px;color:inherit}.sweet-lives.last-chance{color:#a73743;background:#fff0e4;border-color:#ce8c83}
.sweets-layout.sweets-success{height:auto;min-height:0;grid-template-rows:auto auto}
.sweets-layout.sweets-success .pancake-arena{grid-column:1/-1;min-height:530px;height:auto;padding:24px 18px 30px;display:flex;align-items:center;justify-content:center;box-sizing:border-box}
.sweets-success .order-sign,.sweets-success .pancake-controls{display:none}
.sweets-layout.sweets-success .success-overlay{position:relative;inset:auto;transform:none;width:100%;max-width:740px;max-height:none;padding:0;background:none;border:0;box-shadow:none;overflow:visible}
.sweets-layout .success-overlay>strong{font-size:clamp(23px,3vw,34px);color:#805170;text-shadow:0 2px #fff}.success-overlay>strong>span{color:#347e68}
.sweets-success .finished-cake{width:clamp(260px,36vw,410px);height:clamp(160px,18vw,205px);max-width:80%;margin:52px auto 28px;border-width:4px;box-sizing:border-box}
.sweets-success .cake-icing{height:29%}.sweets-success .cake-berries{gap:clamp(24px,4vw,48px)}
.sweets-success .finished-cake>b{top:44%;font-size:clamp(36px,4.8vw,56px);padding:8px 18px;border-radius:14px;border-width:3px;max-width:94%;box-sizing:border-box}
.sweets-layout .success-overlay .cake-equation{display:flex;flex-wrap:wrap;align-items:center;justify-content:center;gap:8px 12px;margin:14px 0 0;font-size:clamp(21px,2.8vw,30px);line-height:1.4}.cake-equation>span{padding:0}.sweets-layout .success-overlay .cake-equation>b{font-size:clamp(29px,3.8vw,42px);color:#8b3d65}
.cake-place-caption{display:block;font-size:15px;font-weight:800;color:#5c657a;margin:4px 0 16px}
.sweets-layout .success-overlay .sweet-success-next{display:block;width:min(360px,100%);min-height:56px;margin:18px auto 0;font-size:20px;padding:10px 15px}
.sweets-success .snow-hero{opacity:.55;max-width:130px;z-index:1}
@media(max-width:760px){
 .sweets-layout .order-sign{padding:8px;left:8px;right:8px}.rounding-order{gap:9px}.rounding-order>strong{font-size:28px;padding:4px 12px 6px;border-radius:12px}.rounding-order>span{font-size:16px}
 .sweets-layout .order-sign>small{margin-top:5px;font-size:11px}.sweets-layout .order-sign>small>b{font-size:15px}.sweets-layout .sweet-aim-hint{font-size:14px;padding:5px 3px;margin-top:5px}
 .sweets-level{gap:5px}.sweet-lives{font-size:10px;padding:1px 7px;gap:3px}.sweet-lives b{font-size:16px}
 .sweets-layout.sweets-success .pancake-arena{min-height:465px;padding:20px 10px 24px}.sweets-layout .success-overlay>strong{font-size:23px;line-height:1.5}
 .sweets-success .finished-cake{width:290px;height:160px;margin:45px auto 26px}.sweets-success .finished-cake>b{font-size:clamp(30px,8vw,40px);padding:8px 12px;top:46%}.sweets-success .cake-berries{gap:26px}
 .sweets-layout .success-overlay .cake-equation{font-size:21px;gap:7px}.sweets-layout .success-overlay .cake-equation>b{font-size:30px}.cake-place-caption{font-size:13px;margin:5px 0 14px}.sweets-layout .success-overlay .sweet-success-next{font-size:18px;min-height:52px;margin-top:14px}
 .sweets-success .snow-hero{width:80px;opacity:.35}
}
@media(max-width:360px){.rounding-order>strong{font-size:25px}.rounding-order>span{font-size:14px}.sweets-layout .success-overlay>strong{font-size:21px}.sweets-layout .success-overlay .cake-equation{font-size:18px}.sweets-layout .success-overlay .cake-equation>b{font-size:26px}}

/* Keep the task and the current operation distinct; only a chosen cake is marked. */
.sweets-layout:has(.sweet-steps){height:auto;grid-template-rows:auto auto minmax(0,1fr);row-gap:10px}
.sweet-steps{grid-column:1/-1;grid-row:2;list-style:none;padding:0;margin:0;display:flex;gap:8px}
.sweet-steps li{flex:1;min-width:0;display:flex;justify-content:center;align-items:center;gap:8px;padding:9px 8px;border:2px solid #cbbdcc;border-radius:12px;background:#f9f5f1;color:#79717b;line-height:1.35;font-size:16px}
.sweet-steps li>span,.sweet-panel-title>span,.sweet-ready-steps span{display:inline-grid;place-items:center;flex-shrink:0;width:27px;height:27px;border-radius:50%;background:#e4dce5;color:#6e6273;font-weight:900}
.sweet-steps .current{background:#805579;border-color:#694260;color:#fff;box-shadow:0 3px #62425c26}.sweet-steps .current>span{background:#fff8e5;color:#744d70}
.sweet-steps .done{background:#eef6ee;color:#53765f;border-color:#a6bba9}.sweet-steps .done>span{background:#d7e9d9;color:#3c6c48}
.sweets-layout:has(.sweet-steps) .pancake-arena{grid-row:3;height:500px;min-height:500px}
.sweets-layout:has(.sweet-steps) .pancake-controls{grid-row:3;height:auto}
.sweets-layout:has(.sweet-steps) .order-sign{top:10px;left:auto;right:12px;width:320px;max-width:calc(100% - 24px);padding:8px 10px;box-sizing:border-box;border-width:2px;border-radius:14px}
.sweets-layout:has(.sweet-steps) .rounding-order{justify-content:flex-start;gap:9px}.sweets-layout:has(.sweet-steps) .rounding-order>strong{font-size:27px;padding:3px 11px 5px;border-radius:10px}.sweets-layout:has(.sweet-steps) .rounding-order>span{font-size:15px}
.sweets-layout .sweet-action{box-sizing:border-box;margin:7px 0 0;padding:5px 3px;background:#fff1cd;border:1px solid #e2ba6c;border-radius:8px;color:#734c31;line-height:1.4}
.sweet-action>b{display:block;font-size:16px}
.pancake-drop-track{position:absolute;left:50%;transform:translateX(-50%);max-width:calc(100% - 14px);box-sizing:border-box;border-inline:2px dashed #76afc05c;border-radius:16px 16px 0 0;background:linear-gradient(#fff2,#fff5);pointer-events:none;z-index:0}
.sweets-layout:has(.sweet-steps) .melt-line{bottom:64px;font-size:11px;border-top:3px dashed #c36189;z-index:2}
.sweets-layout:has(.sweet-steps) .fall-clock{bottom:10px}
.sweets-layout .near-floor .melt-line{border-color:#bb3854;background:#f8c6ce44;color:#9e2540}
.sweets-layout .near-floor .pancake-drop-track{border-color:#c4617880;background:linear-gradient(#fff2,#ffd5d45c)}
.sweets-layout .number-pancake.targeted:after{top:-22px;font-size:19px}
.sweets-layout .number-pancake small{color:#563315;background:#fffceb}
.sweets-layout .number-pancake.targeted small{background:#ffe39a;border-color:#bd732e;font-weight:900}
.sweets-layout .pancake-console-slot{height:auto;min-height:0}
.sweet-panel-title{display:flex;align-items:center;justify-content:center;gap:8px;font-size:19px;font-weight:900;color:#724e6d;margin:0 0 12px;line-height:1.5}
.sweet-panel-title>span{background:#805579;color:white}
.awaiting-place .sweet-panel-title{color:#827680}.awaiting-place .sweet-panel-title>span{background:#ddd4df;color:#6e6273}
.sweets-layout .shot-prompt{font-size:15px;margin:0 0 16px}.shot-prompt strong{font-size:24px;color:#7c512d}
.sweets-layout .ammo:disabled{opacity:1;background:#f1e9e6;border-color:#c7b7bc;color:#81777b;text-shadow:none;box-shadow:0 3px #d7cbd0;cursor:default}
.sweets-layout .ammo>span{font-size:34px}.sweets-layout .ammo b{font-size:23px}.sweets-layout .ammo small{font-size:16px;letter-spacing:.05em}
.sweets-layout .shoot-feedback:empty{display:none}
.sweet-ready-steps{list-style:none;text-align:left;display:grid;gap:10px;width:max-content;max-width:100%;margin:15px auto;padding:0;color:#724e6d;font-size:17px;font-weight:800}
.sweet-ready-steps li{display:flex;align-items:center;gap:9px}
.sweet-ready-steps span{background:#805579;color:white}
@media(max-width:899px){
 .sweet-steps{margin:8px 0;gap:5px}.sweet-steps li{font-size:12px;gap:4px;padding:7px 4px;border-radius:10px}.sweet-steps li>span{width:22px;height:22px;font-size:13px}
 .sweets-layout:has(.sweet-steps) .pancake-arena{height:420px;min-height:420px}.sweets-layout:has(.sweet-steps) .melt-line{bottom:60px;font-size:10px}
 .sweets-layout:has(.sweet-steps) .order-sign{right:8px;left:auto;width:285px;max-width:calc(100% - 16px);padding:7px 8px}
 .sweets-layout:has(.sweet-steps) .rounding-order>strong{font-size:24px}.sweets-layout:has(.sweet-steps) .rounding-order>span{font-size:14px}
 .sweets-layout .sweet-action{margin:6px 0 0;padding:4px 2px}.sweet-action>b{font-size:15px}
 .sweet-panel-title{font-size:16px;margin:0 0 6px;gap:6px}.sweet-panel-title>span{width:24px;height:24px;font-size:14px}
 .sweets-layout .shot-prompt{font-size:13px;margin-bottom:9px}.shot-prompt strong{font-size:21px}
 .sweets-layout .ammo b{font-size:20px}.sweets-layout .ammo small{font-size:14px}.sweets-layout .ammo>span{font-size:29px}
 .sweet-ready-steps{font-size:14px;gap:9px;margin:14px auto}.sweet-ready-steps span{width:24px;height:24px}
 .sweets-layout .pancake-controls{scroll-margin-top:8px}
}
@media(prefers-reduced-motion:reduce){.sweets-layout .number-pancake{transition:none}}

/* Keep the tall desktop playfield after starting, choosing and firing. */
@media(min-width:900px){
 .sweets-layout{--sweet-field-height:clamp(600px,calc(100dvh - 110px),960px)}
 .sweets-layout.sweets-ready{height:auto;grid-template-rows:44px minmax(0,1fr)}
 .sweets-layout:is(.sweets-ready,.sweets-falling,.sweets-answer,.sweets-flying) .pancake-arena{height:var(--sweet-field-height);min-height:var(--sweet-field-height)}
 .sweets-layout:is(.sweets-ready,.sweets-falling,.sweets-answer,.sweets-flying) .pancake-controls{height:auto}
}
