@charset "UTF-8";
:root{font-family:ui-rounded,"Hiragino Kaku Gothic ProN","Yu Gothic",-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#f6ead6;background:#14100d;font-synthesis:none;--ink:#f6ead6;--muted:#c2b3a0;--glass:#1a130ee0;--line:#ffffff24;--accent:#f4b64a;--accent-ink:#2a1602;--red:#ff7a5c;--green:#a8e09a}
*{box-sizing:border-box}html,body{margin:0;width:100%;height:100%;overflow:hidden}body{overscroll-behavior:none}
button,select{font:inherit;color:inherit;-webkit-tap-highlight-color:transparent}button{cursor:pointer;border:0}button:disabled{cursor:default}
button:focus-visible,select:focus-visible,a:focus-visible{outline:3px solid var(--accent);outline-offset:3px}
button:active:not(:disabled){transform:translateY(2px)}[hidden]{display:none!important}
.sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0)}
#app{display:grid;grid-template-columns:minmax(0,1fr);grid-template-rows:54px minmax(0,1fr);height:100%;height:100dvh;padding-bottom:env(safe-area-inset-bottom)}
.toolbar{display:flex;align-items:center;gap:14px;padding:0 18px;background:#17110d;border-bottom:1px solid var(--line);z-index:3}
.brand{display:flex;align-items:center;gap:8px;font-weight:850;font-size:16px;text-decoration:none;color:var(--ink);white-space:nowrap}
.brand-mark{display:grid;place-items:center;width:28px;height:28px;border-radius:8px;background:var(--accent);color:var(--accent-ink);font-weight:950;font-size:21px;font-style:italic}
.toolbar-rule{height:22px;width:1px;background:var(--line)}h1{font-size:15px;margin:0;font-weight:800;white-space:nowrap}
.toolbar-actions{margin-inline-start:auto;display:flex;align-items:center;gap:8px}
.icon-button{display:grid;place-items:center;min-width:42px;height:42px;border:1px solid var(--line);background:#ffffff0d;border-radius:12px;font-size:19px;font-weight:700}
.icon-button[aria-pressed=false]{opacity:.45;text-decoration:line-through}
.language-wrap select{height:42px;min-width:104px;border:1px solid var(--line);border-radius:12px;padding:0 10px;background:#241a12;font-size:12px}
.stage{position:relative;overflow:hidden;isolation:isolate;background:#080605}
.stage>canvas{display:block;width:100%;height:100%;touch-action:none;outline:none;user-select:none;-webkit-user-select:none}
.loading{position:absolute;inset:0;display:grid;place-items:center;background:#080605;color:var(--muted);font-weight:700;z-index:2;transition:opacity .5s}.loading.done{opacity:0;pointer-events:none}
/* what this scene is, what to do in it, and how it is going */
.top{position:absolute;top:10px;left:12px;right:12px;display:grid;gap:6px;justify-items:center;pointer-events:none;text-align:center}
.hint{margin:0;padding:7px 14px;border-radius:14px;background:var(--glass);border:1px solid var(--line);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);font-size:14.5px;font-weight:800;line-height:1.4;max-width:min(560px,100%);text-shadow:0 1px 2px #0008}
.feedback{position:absolute;left:50%;top:calc(var(--top,150px) + 8px);transform:translate(-50%,0) scale(.94);padding:10px 18px;border-radius:16px;background:var(--glass);border:1px solid var(--line);backdrop-filter:blur(12px);-webkit-backdrop-filter:blur(12px);font-weight:900;font-size:16px;text-align:center;opacity:0;transition:opacity .2s,transform .2s;pointer-events:none;max-width:86%;line-height:1.4}
.feedback.show{opacity:1;transform:translate(-50%,0) scale(1)}.feedback.bad{color:#ffb7a3}.feedback.good{color:var(--green)}
.primary-button,.secondary-button{min-height:48px;padding:0 18px;border-radius:14px;font-weight:850;font-size:15px;touch-action:manipulation}
.primary-button{background:var(--accent);color:var(--accent-ink)}.secondary-button{background:#ffffff12;border:1px solid var(--line)}
.overlay{position:absolute;inset:0;display:grid;place-items:center;padding:18px;background:radial-gradient(ellipse at center,#08060599 0%,#080605d9 100%);backdrop-filter:blur(7px);-webkit-backdrop-filter:blur(7px);z-index:2}
.overlay.clear{background:linear-gradient(180deg,#08060500 38%,#080605d0 100%);backdrop-filter:none;-webkit-backdrop-filter:none;place-items:end center;pointer-events:none}.overlay.clear .panel{pointer-events:auto}
.overlay.clear .panel{width:min(400px,100%)}
.panel{width:min(460px,100%);max-height:100%;overflow:auto;padding:24px 24px 20px;border-radius:22px;background:#241a12f2;border:1px solid var(--line);box-shadow:0 24px 70px #000a;text-align:center}
.panel.result{padding:16px 20px 14px;background:#241a12ee}
.eyebrow{font-size:11px;font-weight:800;letter-spacing:.16em;color:var(--accent)}
h2{margin:8px 0 6px;font-size:30px;letter-spacing:-.02em}.panel.result h2{font-size:25px;margin:4px 0 0}.lead{margin:0 0 16px;font-size:15px;line-height:1.55;color:#eadfce}
.actions{display:flex;gap:10px;justify-content:center;align-items:center;flex-wrap:wrap;margin-top:12px}
.text-button{padding:4px 10px;min-height:30px;background:none;color:var(--muted);font-size:13px;font-weight:750;text-decoration:underline;text-underline-offset:4px;border-radius:10px}.text-button:hover{color:var(--ink)}
.fine-print{margin:8px 0 0;font-size:12px;color:var(--muted);line-height:1.5}.fine-print:empty,.record:empty{display:none}
.record{margin:6px 0 0;font-weight:800;color:var(--accent)}
.result-top{display:flex;align-items:center;justify-content:center;gap:14px;margin-top:2px}
.result-score{display:flex;align-items:baseline;gap:6px;direction:ltr}.result-score strong{font-size:50px;letter-spacing:-.04em;line-height:1.05;font-variant-numeric:tabular-nums;color:var(--accent)}.result-score span{font-size:15px;color:var(--muted);font-weight:800}
#help-steps{text-align:start;margin:10px 0 0;padding-inline-start:20px;font-size:14px;line-height:1.6}#help-steps li{margin-bottom:4px}
.tips{text-align:start;margin:10px 0 0;padding-inline-start:20px;font-size:13px;line-height:1.6;color:var(--muted)}
/* The counter is the control. What is written on it: a name under every fruit, and on a first game where to begin */
.top{justify-items:center}
.labels{position:absolute;inset:0;pointer-events:none;overflow:hidden}
.labels span{position:absolute;transform:translate(-50%,-50%);padding:2px 8px;border-radius:9px;background:#0c0806d0;border:1px solid #ffffff1c;font-size:12.5px;font-weight:800;line-height:1.2;color:#f3e6d2;text-align:center;width:max-content;max-width:20vw;overflow-wrap:normal;word-break:normal}
.ring{position:absolute;width:108px;height:108px;margin:-54px 0 0 -54px;border-radius:50%;border:4px solid var(--accent);box-shadow:0 0 22px #f4b64acc,inset 0 0 14px #f4b64a66;pointer-events:none;animation:beckon 1.2s ease-in-out infinite}
@keyframes beckon{0%,100%{transform:scale(1);opacity:1}50%{transform:scale(1.12);opacity:.5}}
.coach{position:absolute;display:flex;align-items:center;gap:8px;padding:9px 8px 9px 16px;border-radius:18px;background:#2a1a0ef5;border:2px solid var(--accent);box-shadow:0 6px 24px #000a;font-size:15.5px;font-weight:850;line-height:1.35;width:max-content;max-width:min(78%,340px);text-align:start;z-index:1}
[dir=rtl] .coach{padding:9px 16px 9px 8px}
.coach button{flex:none;width:30px;height:30px;border-radius:50%;background:#ffffff14;color:var(--muted);font-size:18px;line-height:1}
.feedback{top:calc(var(--top,60px) + 10px);font-size:18px}
.result-top{justify-content:space-between;align-items:flex-start;gap:12px;margin-top:4px}.panel.result h2{margin:0;text-align:start;font-size:27px;line-height:1.22;letter-spacing:-.01em}
/* the verdict on the box: the thing the cook reads first */
.review{margin:8px 0 4px;font-size:15.5px;line-height:1.62;font-weight:700;color:#f6ead6;text-align:start}
.marks{display:grid;gap:5px;margin:8px 0 0;padding:0;list-style:none;text-align:start}
.marks li{display:grid;grid-template-columns:auto 1fr auto;gap:10px;align-items:baseline;font-size:13.5px;font-weight:800;border-bottom:1px solid #ffffff14;padding-bottom:4px}
.marks li span{color:var(--muted);white-space:nowrap}.marks li em{font-style:normal;color:#f6ead6}.marks li b{font-variant-numeric:tabular-nums;direction:ltr;color:var(--accent);white-space:nowrap}.marks li b i{font-style:normal;color:var(--muted);font-weight:700;margin-inline-start:2px}.marks li.low b{color:#ffb7a3}.marks li.low em{color:#ffd9cf}
@media (max-width:640px){.toolbar{padding:0 10px;gap:8px}.toolbar-rule,h1,.wide-tool,.brand span:last-child{display:none}.top{top:8px;left:8px;right:8px}.hint{font-size:13.5px;padding:6px 11px}.primary-button,.secondary-button{min-height:46px;font-size:14.5px;padding:0 12px}h2{font-size:26px}.panel{padding:20px 16px 16px}.panel.result{padding:12px 14px 12px}.panel.result h2{font-size:24px}.review{font-size:14.5px}.result-score strong{font-size:40px}.marks li{font-size:12.5px;gap:8px}.coach{font-size:14.5px}.feedback{font-size:16px}.labels span{font-size:11.5px;padding:1px 6px}.bar{left:8px;right:8px;bottom:10px}.ring{width:84px;height:84px;margin:-42px 0 0 -42px}}
@media (prefers-reduced-motion:reduce){.feedback{transition:none}.ring{animation:none}}
@media (orientation:landscape) and (max-height:560px),(orientation:landscape) and (min-width:820px){.overlay.clear{place-items:center end}.overlay.clear .panel{width:min(340px,46vw)}.labels span{max-width:12vw}}
/* under the board: shut the sandwich and cut it */
.bar{position:absolute;left:12px;right:12px;bottom:12px;display:grid;justify-items:center;z-index:1;pointer-events:none}
.bar button{min-height:52px;min-width:min(260px,72%);padding:0 26px;font-size:16.5px;white-space:nowrap;box-shadow:0 6px 22px #000a;pointer-events:auto}
/* the name of a fruit under its dish: the one in hand is lit; and the word at the line of the cut */
.labels span{transition:background .15s,color .15s,border-color .15s}
.labels span.on{background:var(--accent);color:var(--accent-ink);border-color:var(--accent)}
.labels span.cut{background:#d64a1ee6;color:#fff;border-color:#ffffff40;font-size:11px;padding:1px 7px;transform:translate(-50%,-50%) rotate(0deg)}
.labels span.cut{max-width:none;white-space:nowrap}
@media (max-width:380px){.labels span{font-size:10.5px;padding:1px 5px;border-radius:7px}.labels span.cut{font-size:10px}}
/* the verdict may be long: it scrolls inside the panel, the cut face stays in sight above it and the button below it */
.overlay.clear .panel.result{max-height:min(72%,calc(100% - 150px))}
.panel.result .actions{position:sticky;bottom:-14px;margin:8px -14px -12px;padding:8px 14px 12px;background:linear-gradient(180deg,#241a1200,#241a12 34%)}
/* on a wide screen the panel stands at the right in every language: the scene keeps to the left of it */
@media (orientation:landscape) and (max-height:560px),(orientation:landscape) and (min-width:820px){.overlay.clear{justify-items:right}.overlay.clear .panel.result{max-height:100%}.labels span{max-width:12vw}}
/* the order at the top: which egg, what the customer wants; under it how hot the pan is */
.top{gap:7px}
.ticket{display:flex;flex-wrap:wrap;gap:6px;align-items:center;justify-content:center;margin:0;padding:7px 12px;border-radius:14px;background:var(--glass);border:1px solid var(--line);backdrop-filter:blur(10px);-webkit-backdrop-filter:blur(10px);max-width:min(600px,100%)}
.ticket b{color:var(--muted);font-size:12.5px;font-weight:800;margin-inline-end:2px;white-space:nowrap}
.ticket span{padding:3px 10px;border-radius:9px;background:var(--accent);color:var(--accent-ink);font-size:15px;font-weight:900;white-space:nowrap;line-height:1.35}
.ticket span.alt{background:#ffffff1c;color:var(--ink);font-size:13px;font-weight:800}
.heat{display:grid;grid-template-columns:auto minmax(110px,230px) auto;gap:8px;align-items:center;direction:ltr;padding:4px 12px;border-radius:12px;background:var(--glass);border:1px solid var(--line);font-size:12px;font-weight:800;color:var(--muted)}
.heat-bar{position:relative;height:9px;border-radius:5px;background:linear-gradient(90deg,#557fd2 0 30%,#e9b24a 30% 86.5%,#e0523a 86.5% 100%)}
.heat-bar i{position:absolute;top:-5px;width:6px;height:19px;margin-left:-3px;border-radius:3px;background:#fff;box-shadow:0 0 0 2px #000a;transition:left .15s linear}
.heat b{color:var(--ink);min-width:3.2em;text-align:start}
.labels span{max-width:30vw}.labels span[hidden]{display:none}
.labels span.big{font-size:13.5px;padding:3px 10px}
.panel.egg{padding:14px 20px 14px;background:#241a12ee}.panel.egg h2{margin:0;text-align:start;font-size:30px;line-height:1.2}
.overlay.clear .panel.egg{max-height:min(60%,calc(100% - 190px))}
.overlay.clear{background:linear-gradient(180deg,#08060500 46%,#080605b0 100%)}
@media (max-width:640px){.ticket{padding:6px 9px;gap:5px}.ticket span{font-size:14px;padding:2px 8px}.heat{font-size:11.5px;padding:3px 10px}.panel.egg{padding:12px 14px 12px}.panel.egg h2{font-size:26px}.labels span.big{font-size:12.5px}}
@media (orientation:landscape) and (max-height:560px),(orientation:landscape) and (min-width:820px){.overlay.clear .panel.egg{max-height:100%}.labels span{max-width:16vw}}
.panel.result h2{text-wrap:balance}
.feedback{left:6%;right:6%;width:fit-content;margin-inline:auto;transform:scale(.94);font-size:16px;padding:8px 16px}.feedback.show{transform:scale(1)}
.labels span{max-width:46vw}
@media (max-width:640px){.feedback{font-size:15px}}
/* a phone held sideways: the order stands in the left corner and the counter keeps the height */
@media (orientation:landscape) and (max-height:480px){.top{left:8px;right:auto;top:8px;width:min(40vw,270px);justify-items:start;text-align:start}.ticket{justify-content:flex-start;padding:5px 8px}.ticket span{font-size:13px;padding:2px 7px}.heat{grid-template-columns:auto minmax(60px,1fr) auto;width:100%}.labels span{font-size:11px;padding:1px 5px}}

/* doughnut box: many small names on the counter, a few that say what a touch does, and the time left */
.labels span{font-size:11.5px;padding:1px 6px;border-radius:8px;max-width:25vw;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.labels span.go{background:var(--accent);color:var(--accent-ink);border-color:var(--accent);font-size:13.5px;font-weight:900;padding:3px 10px;max-width:none}
.ticket span.time{background:#ffffff1c;color:var(--ink);font-variant-numeric:tabular-nums;direction:ltr}.ticket span.time.late{background:#d64a1e;color:#fff}
.reveal-bar{position:absolute;left:0;right:0;bottom:calc(14px + env(safe-area-inset-bottom));display:flex;justify-content:center;pointer-events:none}.reveal-bar[hidden]{display:none}
.reveal-bar button{pointer-events:auto;min-height:46px;padding:0 22px;border-radius:23px;background:#2a1a0ef2;border:2px solid var(--accent);color:var(--ink);font-size:15px;font-weight:900}
.review{font-size:16px}
@media (max-width:640px){.labels span{font-size:10.5px;padding:1px 5px}.labels span.go{font-size:12.5px;padding:2px 9px}.review{font-size:15px}}
@media (orientation:landscape) and (max-height:480px){.labels span{font-size:10px;padding:0 4px;max-width:14vw}.labels span.go{font-size:11.5px}.reveal-bar{justify-content:flex-start;padding-left:12px;bottom:8px}}

.coach { pointer-events: none; }
.coach button { pointer-events: auto; }
#result-panel > .result-body { flex: 1 1 auto; }
#result-panel .result-top h2 { min-width: 0; overflow-wrap: anywhere; }
#result-panel .result-top .result-score { flex: none; white-space: nowrap; }

@media (orientation: landscape) and (max-height: 420px) {
  #app { grid-template-rows: 46px minmax(0, 1fr); }
  #stage > #overlay { grid-template-rows: minmax(0, 1fr); padding: 8px 10px; }
  #ready-panel { padding: 10px 12px; min-width: 0; }
  #ready-panel > .eyebrow { display: none; }
  #ready-panel h2 { margin: 0 0 4px; font-size: 22px; line-height: 1.18; }
  #ready-panel .lead { margin: 0; font-size: 13px; line-height: 1.32; }
  #ready-panel .actions { margin-top: 8px; gap: 6px; }
  #ready-panel .actions > button { min-height: 44px; padding: 4px 10px; white-space: normal; }
  #ready-panel .fine-print { margin-top: 4px; }
  #result-panel > .result-footer .actions { margin: 0; }
}
