/* Benny occupies the former order-ticket space; the workbench keeps its width. */
.baker-coach{position:relative;min-width:0;min-height:0;align-self:stretch}
.coach-anchor{position:absolute;inset-inline:0;bottom:clamp(64px,13vh,140px)}
.coach-bubble{position:relative;margin:0 0 12px;padding:15px 14px;background:#fff9e8;border:2px solid #cb9857;border-radius:19px 19px 19px 5px;box-shadow:inset 0 2px #fffef8,0 5px 0 #bc8c52,0 9px 12px #51351f24}
.coach-bubble[hidden]{display:none}
.coach-bubble::after{content:'';position:absolute;bottom:-11px;left:47%;width:17px;height:17px;background:#fff9e8;border-right:2px solid #cb9857;border-bottom:2px solid #cb9857;transform:rotate(45deg)}
.coach-kicker{position:relative;z-index:1;color:#286444;font-family:'Lilita One',sans-serif;font-size:23px;font-weight:400;line-height:1.12;margin:0 0 9px}
.coach-message{font-size:17px;line-height:1.4;font-weight:650;color:#513827;margin:0}
.coach-reminder{background:#fff3cd;border-color:#b87c39}
.coach-reminder::after{background:#fff3cd;border-color:#b87c39}
body[data-family=CC-A] .baker-coach .coach-replay{display:block;width:100%;min-height:44px;padding:0!important;border:0!important;background:transparent!important;box-shadow:none!important;transform:none!important;border-radius:14px;position:relative}
.baker-coach .coach-replay>.btn-content{display:flex;flex-direction:column;width:100%;gap:0}
.coach-crop{display:block;width:100%;height:218px;overflow:hidden;position:relative;filter:drop-shadow(0 3px 2px #63412424)}
.baker-coach .benny{position:absolute;top:0;left:50%;margin-left:-132px;width:264px;height:330px}
.coach-name{position:relative;z-index:1;display:flex;align-items:center;justify-content:center;gap:7px;width:100%;min-height:40px;padding:7px 5px;font-size:15px;font-weight:750;color:#51321b;border:1px solid #b88345;border-radius:7px;background:linear-gradient(#fae5b5,#e6b971);box-shadow:inset 0 2px #fff0c8,0 5px 0 #a3703d,0 8px 9px #52321c30}
.coach-name .icon{width:18px;height:18px}
body[data-family=CC-A] .baker-coach .coach-replay:hover .coach-name{background:#fce8bd}
body[data-family=CC-A] .baker-coach .coach-replay:focus-visible{outline:3px solid #175d91;outline-offset:4px}
@media(max-width:1100px){
  /* On smaller screens use the existing instruction row, not a floating overlay. */
  .baker-coach{height:70px}
  .coach-anchor{inset:0;display:grid;grid-template-columns:72px minmax(0,1fr);gap:12px;align-items:center}
  .baker-coach .coach-replay{grid-column:1;grid-row:1;align-self:end}
  .coach-crop{height:63px}
  .baker-coach .benny{width:88px;height:110px;margin-left:-44px}
  .coach-name{min-height:7px;height:7px;padding:0;font-size:0;border-radius:3px}
  .coach-name .icon{display:none}
  .coach-bubble{grid-column:2;grid-row:1;margin:0;padding:9px 12px;border-radius:15px 15px 15px 4px}
  .coach-bubble::after{left:-8px;bottom:15px;width:12px;height:12px;border-right:0;border-left:2px solid #cb9857;transform:rotate(45deg)}
  .coach-kicker{display:none}
  .coach-message{font-size:14px;line-height:1.3}
}
@media(max-width:700px){
  .baker-coach{height:62px}
  .coach-anchor{grid-template-columns:58px minmax(0,1fr);gap:7px}
  .coach-crop{height:55px}
  .baker-coach .benny{width:74px;height:92.5px;margin-left:-37px}
  .coach-bubble{padding:4px 9px}
  .coach-message{font-size:13px;line-height:1.25}
  .coach-name .icon{display:block;position:absolute;right:0;bottom:4px;width:22px;height:22px;padding:3px;border-radius:50%;background:#fff3d1;box-shadow:0 1px 2px #6a432955}
  body[data-family=CC-A][data-pair-layout=phone][data-stage=arrange] .work-content{gap:4px}
  body[data-family=CC-A][data-pair-layout=phone][data-stage=arrange] .placement-copy{padding-block:0}
  body[data-family=CC-A][data-pair-layout=phone][data-stage=arrange] .placement-copy .placement-instruction{margin-bottom:2px}
}
@media(min-width:1101px) and (max-height:700px){
  .coach-anchor{bottom:40px}
  .coach-crop{height:180px}
  .baker-coach .benny{width:223.2px;height:279px;margin-left:-111.6px}
  .coach-message{font-size:15px}
}

/* Foreground Benny: the viewport edge hides his legs, with his hat at the
   previous height. Reserve his width beside the counting workbench. */
@media(min-width:1101px){
  body[data-family=CC-A]{
    --benny-foreground-height:calc((clamp(64px,13vh,140px) + 253px) * 1.09);
    --benny-foreground-art:calc(var(--benny-foreground-height) * 1.13);
    --benny-foreground-width:calc(var(--benny-foreground-art) * .75);
  }
  body[data-family=CC-A][data-view=game] .work-layout{grid-template-columns:var(--benny-foreground-width) minmax(0,1fr)}
  .baker-coach .coach-anchor{position:static}
  .baker-coach .coach-bubble{position:fixed;z-index:4;left:14px;bottom:calc(var(--benny-foreground-height) + 18px);width:calc(var(--benny-foreground-width) - 26px);margin:0}
  body[data-family=CC-A] .baker-coach .coach-replay{position:fixed;z-index:3;left:0;bottom:0;width:var(--benny-foreground-width);height:var(--benny-foreground-height);border-radius:0}
  .baker-coach .coach-crop{height:var(--benny-foreground-height)}
  .baker-coach .benny{left:calc(var(--benny-foreground-art) * -.155);top:0;margin:0;width:var(--benny-foreground-art);height:calc(var(--benny-foreground-art) * 1.25)}
  .baker-coach .coach-name{position:absolute;left:76px;bottom:18px;width:44px;min-height:44px;padding:10px;font-size:0;border-radius:50%;background:#fff4d6;box-shadow:0 3px 5px #51321b30}
  .baker-coach .coach-name .icon{width:22px;height:22px}
  body[data-family=CC-A] .baker-coach .coach-replay:focus-visible{outline-offset:-4px}
}
@media(min-width:1101px) and (max-height:700px){
  body[data-family=CC-A]{--benny-foreground-height:276px}
}
