:root{--ink:#1e2437;--ink2:#32304a;--paper:#fae9cc;--cream:#ffeed1;--pink:#ea9eaa;--gold:#f7c779;--soft:#c8b7b8;--line:#ffdbab50;--leaf:#99c9b0;--danger:#d96d84;--radius:23px;}
*{box-sizing:border-box}html,body{height:100%;margin:0}body{background:#16182b;color:var(--paper);font-family:Trebuchet MS,Segoe UI,Arial,sans-serif;overflow:hidden}button{font:inherit;cursor:pointer;border:0}button:disabled{opacity:.36;cursor:not-allowed}button:focus-visible{outline:3px solid var(--gold);outline-offset:3px}#app{height:100%}
.stage{height:100vh;min-height:640px;position:relative;overflow:hidden;background:linear-gradient(110deg,#1a1d32c7,#241d2a59),url('assets/bakery.webp') center/cover no-repeat}
.stage:before{content:'';position:absolute;inset:0;background:linear-gradient(0deg,#101122a8,transparent 42%);pointer-events:none}
.stage.story-bg{background-image:linear-gradient(110deg,#171d2de3,#1e223976),url('assets/bakery.webp')}
.ambient{pointer-events:none;position:absolute;inset:0;background:radial-gradient(circle at 77% 31%,#ffba6b22,transparent 26%),radial-gradient(circle at 30% 48%,#bd87d722,transparent 35%);animation:amb 9s ease-in-out infinite alternate}@keyframes amb{from{opacity:.7;transform:scale(1)}to{opacity:1;transform:scale(1.03)}}
.center{position:relative;z-index:1;width:min(1200px,96%);margin:auto;height:100%;display:flex;align-items:center}.menu{width:560px;max-width:100%;padding:54px 44px 42px;border:1px solid #f5cb8d50;border-radius:30px;background:linear-gradient(145deg,#151729ee,#28213ae6);box-shadow:0 25px 90px #0a0c1ad0;backdrop-filter:blur(14px)}.eyebrow{font-size:11px;letter-spacing:4px;color:var(--gold);font-weight:800;text-transform:uppercase}.menu h1{font-family:Georgia,serif;font-size:clamp(45px,5.6vw,77px);letter-spacing:-3px;line-height:.96;margin:20px 0 16px;color:#ffedca;text-shadow:0 6px 20px #0006}.menu h1 span{font-style:italic;color:var(--pink)}.menu p{font-size:15px;line-height:1.8;color:#e9d7d3;margin:0 0 24px}.actions{display:flex;gap:12px;flex-wrap:wrap}.btn{border:1px solid #f5ca9070;border-radius:15px;color:#ffeedb;background:#4d384a;padding:12px 19px;font-weight:750;transition:.16s}.btn:hover:not(:disabled){transform:translateY(-2px);background:#644a60}.btn.primary{color:#342638;background:linear-gradient(#ffe4a1,#e9a2a3);border-color:#fce1ac;box-shadow:0 9px 25px #cc819c44}.btn.primary:hover:not(:disabled){background:linear-gradient(#fff2ba,#f1b3bf)}.btn.tiny{padding:8px 12px;border-radius:12px;font-size:12px}.menu-foot{display:flex;gap:20px;margin-top:30px;padding-top:19px;border-top:1px solid #ffe2af25;color:#d1b8ba;font-size:12px}.lang{margin-top:20px;display:flex;align-items:center;gap:9px}.lang button{font-size:12px;padding:6px 12px;color:#d8c3bb;border:1px solid #e2ad875b;background:#1b1f32;border-radius:30px}.lang button.active{color:#342638;background:var(--gold)}
/* gameplay */
.game{height:100%;display:grid;grid-template-rows:auto minmax(0,1fr) auto;gap:12px;padding:14px;position:relative;z-index:2;max-width:1800px;margin:auto}.game-top{display:flex;justify-content:space-between;align-items:center;gap:9px;background:#181a2bdc;border:1px solid #f4d5ae3c;border-radius:18px;padding:10px 16px;min-height:64px;box-shadow:0 7px 20px #14102033;backdrop-filter:blur(12px)}.brand{font-family:Georgia,serif;font-size:24px;color:#ffddae;line-height:1.05;white-space:nowrap}.brand small{display:block;font-size:10px;letter-spacing:2px;color:#f6b4ad;font-family:Arial,sans-serif;font-weight:800;margin-top:4px}.metrics{display:flex;gap:8px;flex-wrap:wrap;justify-content:flex-end}.metric{padding:8px 10px;background:#ffffff0b;border-radius:11px;color:#f8dfbd;white-space:nowrap;font-size:13px;border:1px solid #ffffff09}.metric b{color:#fff0cb;font-size:15px}.top-actions{display:flex;gap:5px}.icon-btn{border:1px solid #f5d4aa42;background:#ffffff12;color:var(--paper);width:39px;height:39px;border-radius:12px;font-size:17px;display:grid;place-items:center}
.play-grid{min-height:0;display:grid;grid-template-columns:minmax(230px,260px) minmax(370px,1fr) minmax(280px,340px);gap:12px}.panel{background:#181b2ce8;border:1px solid #fce2b13b;border-radius:22px;box-shadow:0 14px 37px #0e1020a1;backdrop-filter:blur(10px);min-height:0}.panel .cap{font-family:Georgia,serif;font-size:20px;color:#ffe6c1;margin:0}.tickets-panel,.guest-panel{padding:18px;overflow:auto;scrollbar-width:thin}.panelhead{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:14px}.mini{font-size:11px;color:#d3b7b9;letter-spacing:1.1px;text-transform:uppercase}.ticket{display:flex;align-items:center;gap:10px;width:100%;text-align:left;border:1px solid #fbe6be2c;background:#eee4d30c;color:#f7dfd2;border-radius:15px;padding:10px;margin-bottom:8px;transition:.2s;position:relative}.ticket img{width:62px;height:62px;object-fit:contain;filter:drop-shadow(0 7px 8px #0006)}.ticket.active{border-color:#f5d595;background:#9a6c6633;box-shadow:0 0 0 2px #f4dd9c18}.ticket strong{display:block;font-size:14px}.ticket .small{font-size:11px;color:#d5bcb8;display:block;margin-top:5px}.patience{width:100%;height:5px;border-radius:12px;background:#ffffff20;margin-top:8px;overflow:hidden}.patience span{height:100%;display:block;background:linear-gradient(90deg,#e57e9b,#f8d27a);transition:width .4s}.blank-note{font-size:13px;line-height:1.65;color:#d7c2bd;padding:16px;border:1px dashed #e9ba9661;border-radius:14px}
.workshop{position:relative;display:flex;flex-direction:column;justify-content:space-between;overflow:hidden;padding:18px;min-height:450px;background:linear-gradient(#1e223175,#272033bb),url('assets/bakery.webp') 49% 42%/cover}.workshop::after{content:'';position:absolute;inset:0;pointer-events:none;background:radial-gradient(circle at 52% 45%,#ffb87516,transparent 42%)}.worktop{position:relative;z-index:1;text-align:center}.work-title{font-family:Georgia,serif;font-size:22px;color:#fff0d3;margin:0 0 5px}.workhint{font-size:12px;color:#eed1c2;line-height:1.55}.dish-preview{height:clamp(150px,30vh,250px);width:min(320px,90%);margin:auto;position:relative;display:flex;align-items:center;justify-content:center}.dish-preview::before{content:'';position:absolute;bottom:12%;left:10%;width:80%;height:28%;border-radius:50%;background:#1d1325b3;filter:blur(13px)}.dish-preview img{position:relative;width:clamp(128px,22vh,218px);height:clamp(128px,22vh,218px);object-fit:contain;filter:drop-shadow(0 13px 17px #150b1daa);animation:plate 3s ease-in-out infinite}.dish-preview .bowl{width:195px;height:195px;border-radius:50%;background:radial-gradient(circle,#e8c69b,#b17d75 54%,#533f54 69%,#d5a57b 72%,#412a45 78%);border:7px solid #ead0aa;box-shadow:0 12px 36px #0009;display:grid;place-items:center;gap:3px;padding:15px;grid-template-columns:repeat(2,1fr);position:relative;animation:plate 3s ease-in-out infinite}.dish-preview .bowl img{width:74px;height:74px;filter:drop-shadow(0 4px 5px #0006);animation:none}.dish-preview .bowl.empty:after{content:'✦';font-size:65px;color:#f6ddba99;position:absolute}.dish-preview .mixing{font-size:72px;color:#ffe0bb;text-shadow:0 9px 18px #2a1738;animation:whisk .4s ease-in-out infinite alternate}.dish-preview .baking{width:210px;height:210px;display:grid;place-items:center;background:radial-gradient(circle,#ffbf7c44,transparent 73%);font-size:87px;text-shadow:0 8px 16px #261225;animation:plate 1.8s ease-in-out infinite}
@keyframes plate{50%{transform:translateY(-6px) rotate(2deg)}}@keyframes whisk{to{transform:rotate(13deg)}}.work-actions{z-index:2;position:relative;display:flex;gap:10px;justify-content:center;align-items:center;flex-wrap:wrap;min-height:60px}.mix-bar{height:13px;max-width:330px;background:#1d1b2d;border:1px solid #e0c09c70;border-radius:11px;margin:12px auto;overflow:hidden}.mix-bar>span{display:block;height:100%;width:0;background:linear-gradient(90deg,#f3a7a9,#ffe6a5);transition:width .18s}.oven-meter{width:min(410px,94%);height:23px;margin:12px auto 8px;position:relative;border:3px solid #dcb28b;background:linear-gradient(90deg,#ad5968,#e7b574,#f5d69c,#c16b70);border-radius:30px;box-shadow:0 3px 8px #0007}.oven-zone{position:absolute;top:0;height:100%;background:#adf0be66;outline:2px solid #d3ffd0;border-radius:8px}.oven-cursor{position:absolute;top:-10px;height:39px;width:7px;background:#fdf4d3;box-shadow:0 0 12px #fff5aa;border-radius:8px;transition:left 70ms linear}.heathelp{font-size:12px;color:#fff0c8;text-align:center}
.guest-art{text-align:center;position:relative;padding-top:6px}.guest-art img{width:min(85%,240px);height:clamp(180px,30vh,270px);object-fit:contain;filter:drop-shadow(0 20px 19px #0009);animation:guest 3.9s ease-in-out infinite}.guest-art:after{content:'';position:absolute;width:70%;height:9px;bottom:9px;left:15%;background:#0007;filter:blur(10px)}@keyframes guest{50%{transform:translateY(-6px)}}.guest-name{font-family:Georgia,serif;color:#ffe2b4;font-size:21px;text-align:center;margin:4px 0}.guest-quote{font-size:13px;line-height:1.65;background:#f6d7c91a;border:1px solid #ffcabb42;padding:13px;border-radius:14px;color:#f9ddd0;text-align:center;min-height:68px}.recipe-card{margin-top:13px;background:#f0dbc81a;padding:12px;border:1px solid #f9e6c82d;border-radius:14px}.recipe-card strong{font-family:Georgia,serif;color:#ffe6ba}.recipe-card .ingredients{display:flex;gap:5px;margin-top:10px;justify-content:center}.recipe-card .ingredients img{width:50px;height:50px;object-fit:contain}.progressline{color:#dac6bd;font-size:12px;text-align:center;margin-top:12px}
.pantry{background:#1e1d2ce8;border:1px solid #e6ba854f;border-radius:21px;padding:13px 17px;box-shadow:0 9px 28px #11101fa3}.pantry-head{display:flex;justify-content:space-between;align-items:center;gap:10px;margin-bottom:9px}.pantry-head h3{font-family:Georgia,serif;font-size:18px;margin:0;color:#ffe1b4}.ingredient-row{display:grid;grid-template-columns:repeat(10,minmax(55px,1fr));gap:8px}.ingredient{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:0;position:relative;border-radius:14px;background:linear-gradient(#fbddd416,#c2a8ac0d);border:1px solid #fbd2a32c;color:#f4dbca;padding:5px 2px 7px;min-height:92px;transition:.12s}.ingredient:hover:not(:disabled){background:#ffe8af23;transform:translateY(-4px)}.ingredient img{width:65px;height:65px;max-width:100%;object-fit:contain;filter:drop-shadow(0 5px 6px #110b1c90)}.ingredient span{font-size:11px;white-space:nowrap;max-width:100%;overflow:hidden;text-overflow:ellipsis}.ingredient.dim{filter:grayscale(.7)}.floating{position:absolute;pointer-events:none;color:#ffe6bb;animation:floatout .8s ease-out forwards;font-weight:bold;text-shadow:0 2px 8px #000}@keyframes floatout{to{transform:translateY(-65px);opacity:0}}
/* overlays, summaries and recipe book */
.overlay{position:fixed;inset:0;background:#101223bd;display:grid;place-items:center;z-index:90;padding:15px;backdrop-filter:blur(9px);overflow:auto}.paper{width:min(770px,98%);max-height:min(92vh,850px);overflow:auto;background:linear-gradient(145deg,#342f49,#252438);border:1px solid #f4d49b70;border-radius:29px;padding:30px;box-shadow:0 30px 100px #05060edb}.paper h2{font-family:Georgia,serif;font-size:clamp(25px,4vw,40px);color:#ffe4af;margin:5px 0 12px}.paper p{color:#edc9c9;line-height:1.78}.paper .choice{width:100%;display:block;text-align:left;margin-top:11px;border:1px solid #f0d4ae63;border-radius:17px;background:#f6ead00e;padding:15px 17px;color:#fce4cd;transition:.2s}.paper .choice:hover{background:#f2d0ad26;border-color:#f5d2ad}.paper .choice strong{display:block;font-size:14px;margin-bottom:4px}.paper .choice small{display:block;font-size:12px;line-height:1.5;color:#e2c3bd}.portrait-story{height:225px;object-fit:contain;float:right;margin:-20px -15px 3px 12px;filter:drop-shadow(0 12px 16px #0007)}.daily-grid{display:grid;grid-template-columns:repeat(3,1fr);gap:9px;margin:20px 0}.daily-stat{border:1px solid #d3b48a44;border-radius:15px;padding:14px;text-align:center;background:#fff2ca0c}.daily-stat b{display:block;font-family:Georgia,serif;font-size:28px;color:#ffe3ad}.daily-stat small{color:#ddc2bc}.upgrades{display:grid;grid-template-columns:repeat(2,1fr);gap:12px;margin:14px 0 20px}.upg{background:#efe4d314;border:1px solid #f7d5a547;border-radius:18px;padding:14px;color:#fbdfce;text-align:left}.upg strong{display:block;color:#ffe2b8}.upg .level{display:block;font-size:11px;color:#c3d5c0;margin:8px 0}.upg small{display:block;font-size:12px;line-height:1.5;color:#e6bfc0;margin-top:8px}.bookgrid{display:grid;grid-template-columns:repeat(3,1fr);gap:10px}.bookcard{border:1px solid #f7d9b13c;border-radius:16px;background:#ffffff0b;padding:13px;text-align:center}.bookcard img{width:92px;height:92px;object-fit:contain}.bookcard h3{font-family:Georgia,serif;font-size:16px;color:#ffe2b0;margin:3px 0 6px}.bookcard .small{font-size:11px;color:#dac6bc}.bookcard .row{display:flex;justify-content:center}.bookcard .row img{width:32px;height:32px}.toast{position:fixed;left:50%;bottom:120px;transform:translateX(-50%);z-index:160;border:1px solid #f0cba4a3;border-radius:17px;background:#191e30ef;color:#fff0ce;padding:12px 21px;box-shadow:0 12px 30px #08080fa9;max-width:min(440px,95vw);text-align:center;pointer-events:none}
@media(max-width:1020px){body{overflow:auto}.stage{height:auto;min-height:100vh;overflow:auto}.game{min-height:100vh;grid-template-rows:auto auto auto}.play-grid{grid-template-columns:1fr 1fr}.workshop{grid-column:1/-1;grid-row:1;min-height:400px}.tickets-panel{grid-row:2;max-height:290px}.guest-panel{grid-row:2;max-height:290px}.ingredient-row{grid-template-columns:repeat(5,minmax(0,1fr))}.pantry{padding:12px}.ingredient{min-height:84px}.menu{margin:25px 0}}
@media(max-width:580px){.game{padding:9px;gap:9px}.game-top{align-items:flex-start;padding:10px;flex-wrap:wrap}.brand{font-size:21px}.metrics{order:3;width:100%;justify-content:flex-start}.metric{padding:6px 9px;font-size:12px}.top-actions{margin-left:auto}.play-grid{grid-template-columns:1fr;gap:9px}.workshop{grid-row:1;grid-column:auto;min-height:350px;padding:11px}.tickets-panel{grid-row:2;max-height:185px;overflow:auto}.ticket img{width:50px;height:50px}.guest-panel{grid-row:3;max-height:none}.guest-art img{height:185px}.pantry-head{align-items:flex-start}.ingredient-row{grid-template-columns:repeat(5,minmax(0,1fr));gap:5px}.ingredient{min-height:78px;padding:3px}.ingredient img{width:50px;height:50px}.ingredient span{font-size:10px}.paper{padding:21px}.portrait-story{height:145px}.upgrades,.bookgrid{grid-template-columns:1fr 1fr}.daily-grid{grid-template-columns:repeat(3,1fr)}.daily-stat{padding:9px}.daily-stat b{font-size:21px}.menu{padding:33px 25px}.menu h1{font-size:49px}}
@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation:none!important;transition:none!important}}
