/* The chef who reacts to a choice. Sits bottom-left so it never covers the
   WhatsApp and call buttons on the right, and never takes pointer events away
   from the page behind it. */
.chef-reaction{
    position:fixed;
    left:18px;
    bottom:18px;
    z-index:60;
    display:flex;
    align-items:flex-end;
    gap:10px;
    pointer-events:none;
    opacity:0;
    transform:translateY(14px);
    transition:opacity .28s ease, transform .28s ease;
}
.chef-reaction.is-in{ opacity:1; transform:translateY(0); pointer-events:auto; cursor:pointer; }
.chef-reaction[hidden]{ display:none; }

.chef-stage{
    order:-1;
    width:72px;
    height:78px;
    flex:0 0 auto;
    filter:drop-shadow(0 6px 14px rgba(20,67,47,.28));
}
.chef-figure{ width:100%; height:100%; overflow:visible; }

/* Colours follow the site palette rather than inventing a new one. */
.chef-shadow{ fill:#14432f; opacity:.12; }
.chef-toque{ fill:#fff; stroke:#cfe0d6; stroke-width:1.4; }
.chef-toque-band{ fill:#f3f8f5; stroke:#dfeae4; stroke-width:1; }
.chef-neck{ fill:url(#chefRxSkin); }
.chef-coat{ fill:url(#chefRxCoat); stroke:#cfe0d6; stroke-width:1.4; stroke-linejoin:round; }
.chef-apron{ fill:#14432f; opacity:.1; }
.chef-collar{ fill:#14432f; }
.chef-button{ fill:#b9cec2; }
.chef-face,.chef-ear,.chef-hand{ fill:url(#chefRxSkin); }
.chef-hair{ fill:#2f231a; }
.chef-eyes circle{ fill:#2b2118; }
.chef-brow{ fill:none; stroke:#2f231a; stroke-width:1.6; stroke-linecap:round; }
.chef-tache{ fill:#2f231a; }
.chef-smile{ fill:none; stroke:#2b2118; stroke-width:1.6; stroke-linecap:round; }
.chef-blush{ fill:#e07a4a; opacity:.28; }
.chef-sleeve{ fill:url(#chefRxCoat); stroke:#cfe0d6; stroke-width:1.4; }
.chef-thumb-up{ fill:url(#chefRxSkin); opacity:0; }

.chef-bubble{
    max-width:min(15.5rem, calc(100vw - 130px));
    background:#14432f;
    color:#fff;
    font-size:13.5px;
    font-weight:600;
    line-height:1.45;
    padding:10px 14px;
    border-radius:14px 14px 14px 4px;
    box-shadow:0 8px 20px rgba(20,67,47,.26);
    position:relative;
    margin-bottom:12px;
}
.chef-bubble::after{
    content:"";
    position:absolute;
    left:-6px;
    bottom:8px;
    width:12px;
    height:12px;
    background:#14432f;
    transform:rotate(45deg);
    border-radius:2px;
}

/* ---- reactions ---------------------------------------------------------- */

.chef-eyes{ transform-origin:48px 38px; animation:chef-blink 5s infinite; }
@keyframes chef-blink{
    0%,92%,100%{ transform:scaleY(1); }
    95%{ transform:scaleY(.12); }
}

.chef-arm{ transform-origin:64px 62px; }
.chef-body-group{ transform-origin:48px 92px; }

.chef-wave{ }
.chef-figure.chef-wave .chef-arm{ animation:chef-wave-arm 1.5s ease-in-out 2; }
@keyframes chef-wave-arm{
    0%,100%{ transform:rotate(0deg); }
    25%{ transform:rotate(-26deg); }
    60%{ transform:rotate(12deg); }
}

.chef-figure.chef-thumb .chef-arm{ animation:chef-thumb-arm 1.1s ease-out 1 forwards; }
.chef-figure.chef-thumb .chef-thumb-up{ animation:chef-thumb-pop .5s ease-out .18s 1 forwards; }
.chef-figure.chef-thumb .chef-hand{ animation:chef-hand-tuck .5s ease-out .18s 1 forwards; }
@keyframes chef-thumb-arm{
    0%{ transform:rotate(0deg) translateY(0); }
    55%{ transform:rotate(-16deg) translateY(-7px); }
    100%{ transform:rotate(-12deg) translateY(-5px); }
}
@keyframes chef-thumb-pop{ to{ opacity:1; } }
@keyframes chef-hand-tuck{ to{ r:4.4; } }

.chef-figure.chef-point .chef-arm{ animation:chef-point-arm 1.4s ease-in-out 1 forwards; }
@keyframes chef-point-arm{
    0%{ transform:rotate(0deg); }
    45%{ transform:rotate(-34deg); }
    100%{ transform:rotate(-28deg); }
}

.chef-figure.chef-rest .chef-arm{ animation:none; }

.chef-figure.chef-bob .chef-body-group{ animation:chef-bob 1.5s ease-in-out 2; }
@keyframes chef-bob{
    0%,100%{ transform:translateY(0); }
    50%{ transform:translateY(-3px); }
}

.chef-figure.chef-hop .chef-body-group{ animation:chef-hop .7s cubic-bezier(.3,1.4,.5,1) 2; }
@keyframes chef-hop{
    0%,100%{ transform:translateY(0) scaleY(1); }
    35%{ transform:translateY(-8px) scaleY(1.04); }
    70%{ transform:translateY(0) scaleY(.96); }
}

.chef-figure.chef-lean .chef-body-group{ animation:chef-lean 1.4s ease-in-out 1 forwards; }
@keyframes chef-lean{
    0%{ transform:rotate(0deg); }
    100%{ transform:rotate(3.5deg); }
}

.chef-figure.chef-tilt .chef-head{ animation:chef-tilt 1.6s ease-in-out 2; transform-origin:48px 52px; }
@keyframes chef-tilt{
    0%,100%{ transform:rotate(0deg); }
    50%{ transform:rotate(-7deg); }
}

/* Phones: keep the chef out of the way of the sticky order bar. */
@media (max-width:600px){
    .chef-reaction{ left:12px; right:86px; bottom:14px; }
    .chef-stage{ width:56px; height:60px; }
    .chef-bubble{ font-size:12.5px; padding:8px 11px; max-width:none; }
}
body.has-order-mobile-bar .chef-reaction{ bottom:96px; }

/* Someone who asked for less motion still gets the message, held still. */
@media (prefers-reduced-motion: reduce){
    .chef-reaction{ transition:none; transform:none; }
    .chef-figure *,
    .chef-figure{ animation:none !important; }
}
