.genie-launch{position:fixed;right:20px;bottom:20px;z-index:90;border:0;border-radius:999px;padding:13px 18px;display:flex;gap:8px;align-items:center;box-shadow:0 10px 30px #0004;background:#173b68;color:#fff;font:700 15px/1 system-ui;cursor:pointer}.genie-launch span{color:#f4be61;font-size:20px}.genie-panel{position:fixed;right:20px;bottom:78px;z-index:91;width:min(390px,calc(100vw - 24px));max-height:min(620px,calc(100vh - 110px));background:#fff;color:#1d2430;border-radius:22px;box-shadow:0 18px 60px #0005;overflow:hidden;border:1px solid #0001;font-family:system-ui,sans-serif}.genie-panel[hidden]{display:none}.genie-panel>header{background:#173b68;color:#fff;padding:16px 18px;display:flex;align-items:center;justify-content:space-between}.genie-panel header div{display:grid}.genie-panel header strong{font-size:18px}.genie-panel header small{opacity:.8}.genie-panel header button{border:0;background:transparent;color:#fff;font-size:28px;cursor:pointer}.genie-feed{min-height:190px;max-height:340px;overflow:auto;padding:16px;background:#f6f7f9}.genie-feed p{margin:0 0 12px;padding:10px 12px;border-radius:14px;max-width:90%;white-space:pre-wrap}.genie-feed p b{display:block;font-size:11px;text-transform:uppercase;letter-spacing:.08em;margin-bottom:3px}.genie-system{color:#5d6570;background:#fff}.genie-you{margin-left:auto!important;background:#173b68;color:#fff}.genie-genie{background:#fff;border:1px solid #dfe3e8}.genie-compose{padding:14px}.genie-compose textarea{width:100%;box-sizing:border-box;resize:none;border:1px solid #cfd5dc;border-radius:12px;padding:11px;font:inherit}.genie-actions{display:flex;gap:9px;margin-top:9px}.genie-actions button{border:0;border-radius:11px;padding:11px 14px;font-weight:700;cursor:pointer}.genie-mic{background:#eef2f6;color:#173b68}.genie-mic.listening{outline:3px solid #d44}.genie-send{margin-left:auto;background:#173b68;color:#fff}.genie-compose>small{display:block;color:#69717c;margin-top:8px;line-height:1.3}@media(max-width:520px){.genie-launch{right:12px;bottom:12px}.genie-panel{right:12px;bottom:68px;max-height:calc(100vh - 86px)}}
.site-signin{font:700 12px/1 system-ui;border:1px solid var(--line);border-radius:999px;padding:11px 16px;white-space:nowrap;background:var(--paper)}.site-signin:hover{filter:brightness(.96)}@media(max-width:800px){header{gap:10px}.site-signin{margin-left:auto}.bag{white-space:nowrap}}@media(max-width:560px){.site-signin{font-size:11px;padding:9px 11px}}

.genie-build{border:1px solid currentColor;background:transparent;border-radius:999px;padding:.65rem .85rem;font-weight:700;cursor:pointer}
.genie-draft-actions{display:flex;gap:.55rem;flex-wrap:wrap;margin:.35rem .25rem .8rem}
.genie-draft-actions button{border:1px solid currentColor;border-radius:999px;padding:.55rem .8rem;background:transparent;font-weight:700;cursor:pointer}
.genie-draft-actions button:first-child{background:var(--accent,#f4be61);color:#20130d;border-color:transparent}
@media(max-width:520px){.genie-actions{flex-wrap:wrap}.genie-build{order:3;flex:1 0 100%}}

.genie-build{background:#fff;border:1px solid currentColor;border-radius:10px;padding:.65rem .8rem;font-weight:700;cursor:pointer}
.genie-draft-actions{display:flex;gap:.5rem;flex-wrap:wrap;margin:.35rem .75rem .75rem}
.genie-draft-actions button{border:0;border-radius:10px;padding:.65rem .8rem;font-weight:700;cursor:pointer}
.genie-draft-actions button:first-child{background:#111;color:#fff}
@media(max-width:520px){.genie-actions{flex-wrap:wrap}.genie-build{order:3;width:100%}}

/* Customer voice conversation (Cookout Lane B): small state pill, no overlay. */
.genie-state{display:inline-flex;align-items:center;gap:6px;margin:0 0 8px;padding:5px 11px;border-radius:999px;font:700 12px/1.2 system-ui,sans-serif;background:#eef2f6;color:#173b68}
.genie-state[hidden]{display:none}
.genie-state[data-state=listening]{background:#fde8e8;color:#9b1c1c}
.genie-state[data-state=thinking]{background:#fff4d6;color:#6b4a00}
.genie-state[data-state=speaking]{background:#e3eeff;color:#173b68}
.genie-state[data-state=typing]{background:#eef2f6;color:#3d4652}
.genie-mic.live{background:#9b1c1c;color:#fff}
.genie-voice{display:flex;align-items:center;gap:8px;margin-top:8px;font:12px/1.2 system-ui,sans-serif;color:#69717c}
.genie-voice[hidden]{display:none}
.genie-voice select{flex:1;min-width:0;border:1px solid #cfd5dc;border-radius:8px;padding:5px 6px;font:inherit;color:#1d2430;background:#fff}
@media (prefers-reduced-motion:no-preference){.genie-state[data-state=listening]::before{content:'';width:8px;height:8px;border-radius:50%;background:currentColor;animation:genie-pulse 1.2s ease-in-out infinite}}
@keyframes genie-pulse{50%{opacity:.25}}

/* P0 voice controls: End is always reachable in the header; phone height uses the dynamic viewport. */
.genie-end{border:0;border-radius:999px;padding:7px 14px;margin-left:auto;margin-right:6px;background:#c62828;color:#fff;font:700 13px/1 system-ui,sans-serif;cursor:pointer}
.genie-end[hidden]{display:none}
@supports (height:100dvh){.genie-panel{max-height:min(620px,calc(100dvh - 110px));display:flex;flex-direction:column}.genie-feed{flex:1 1 auto;min-height:120px}@media(max-width:520px){.genie-panel{max-height:calc(100dvh - 86px)}}}
/* Theme isolation (Cookout Lane B): site themes style bare header/button with higher specificity than the panel's
   classes (e.g. body[data-theme=burgundy] header, button{background:var(--paper);color:var(--ink)}), which made the
   header a narrow dark box and some buttons cream-on-white. Anchor every panel surface on the #genie-panel id. */
#genie-panel{color:#1d2430}
#genie-panel>header{display:flex;flex-wrap:nowrap;align-items:center;justify-content:space-between;gap:8px;position:static;width:auto;max-width:none;margin:0;padding:16px 18px;background:#173b68;color:#fff;border:0;border-radius:0;box-shadow:none;backdrop-filter:none}
#genie-panel>header nav{display:none}
#genie-panel>header #genie-close{border:0;background:transparent;color:#fff;font-size:28px;line-height:1;min-width:44px;min-height:44px;padding:0}
#genie-panel>header .genie-end{background:#c62828;color:#fff;border:0}
#genie-panel .genie-actions button{border:0;border-radius:11px;padding:11px 14px;font-weight:700;min-height:44px}
#genie-panel .genie-mic,#genie-panel .genie-dictate{background:#eef2f6;color:#173b68}
#genie-panel .genie-mic.live{background:#9b1c1c;color:#fff}
#genie-panel .genie-dictate.listening{outline:3px solid #d44}
#genie-panel .genie-send{background:#173b68;color:#fff}
#genie-panel .genie-build{background:#fff;color:#173b68;border:1px solid #173b68;border-radius:10px}
#genie-panel .genie-draft-actions button{background:#fff;color:#173b68;border:1px solid #173b68;border-radius:10px;padding:.65rem .8rem;min-height:44px;font-weight:700}
#genie-panel .genie-draft-actions button:first-child{background:#173b68;color:#fff;border-color:#173b68}
#genie-panel textarea{background:#fff;color:#1d2430}
#genie-panel button:disabled{opacity:.55}
/* Bag-fill note by the launcher (the panel folds away so the bag is visible). */
.genie-note{position:fixed;right:20px;bottom:78px;z-index:92;max-width:min(320px,calc(100vw - 40px));margin:0;padding:10px 14px;border-radius:14px;background:#173b68;color:#fff;font:600 14px/1.3 system-ui,sans-serif;box-shadow:0 10px 30px #0004}.genie-note[hidden]{display:none}
@media(max-width:520px){.genie-note{right:12px;bottom:68px}}
/* Voice entry at the top of the panel (Uton feedback): a full-width Talk button right under the header. */
#genie-panel .genie-voicebar{display:flex;align-items:center;gap:10px;padding:10px 14px;background:#eef2f6;border-bottom:1px solid #dfe3e8}
#genie-panel .genie-voicebar .genie-mic{flex:1 1 auto;min-height:48px;border:0;border-radius:12px;padding:10px 16px;background:#173b68;color:#fff;font:700 16px/1.1 system-ui,sans-serif;cursor:pointer}
#genie-panel .genie-voicebar .genie-mic.live{background:#9b1c1c;color:#fff}
#genie-panel .genie-voicebar .genie-mic:disabled{background:#5d6570;color:#fff}
#genie-panel .genie-voicebar .genie-state{flex:0 0 auto;margin:0}
/* Natural mode (beta) toggle + its status note. */
#genie-panel .genie-natural{display:flex;align-items:flex-start;gap:8px;margin-top:8px;min-height:44px;font:13px/1.35 system-ui,sans-serif;color:#1d2430;cursor:pointer}#genie-panel .genie-natural[hidden]{display:none}
#genie-panel .genie-natural input{width:20px;height:20px;margin:2px 0 0;flex:0 0 auto;accent-color:#173b68}
#genie-panel .genie-natural-note{display:block;margin-top:4px;padding:6px 10px;border-radius:8px;background:#fff4e5;color:#6b3d00;font:12px/1.35 system-ui,sans-serif}#genie-panel .genie-natural-note[hidden]{display:none}
/* Voice debug panel (opt-in) + headphones checkbox. */
#genie-panel .genie-linkbtn{display:inline-block;margin-top:4px;min-height:32px;padding:4px 0;border:0;background:transparent;color:#173b68;font:600 12px/1.2 system-ui,sans-serif;text-decoration:underline;cursor:pointer}#genie-panel .genie-linkbtn[hidden]{display:none}
#genie-panel .genie-vdebug{margin-top:6px;padding:8px;border:1px solid #cfd5dc;border-radius:10px;background:#f6f7f9;font:11px/1.35 ui-monospace,Consolas,monospace;color:#1d2430}#genie-panel .genie-vdebug[hidden]{display:none}
#genie-panel .vd-meter{position:relative;height:12px;border-radius:6px;background:#dfe3e8;overflow:hidden}#genie-panel .vd-bar{position:absolute;left:0;top:0;bottom:0;width:0;background:#2e8b57}#genie-panel .vd-thr{position:absolute;top:0;bottom:0;width:2px;background:#c62828}
#genie-panel .vd-nums,#genie-panel .vd-state{margin:4px 0}#genie-panel .vd-log{max-height:120px;overflow:auto;margin:4px 0;padding-left:18px}
#genie-panel .vd-actions{display:flex;align-items:center;gap:8px}#genie-panel .vd-actions button{min-height:36px;padding:4px 10px;border:1px solid #173b68;border-radius:8px;background:#fff;color:#173b68;font:600 12px system-ui,sans-serif}
#genie-panel .vd-copytext{width:100%;min-height:80px;margin-top:6px;font:11px ui-monospace,Consolas,monospace}#genie-panel .vd-copytext[hidden]{display:none}
.genie-order{margin:0;padding:.55rem .9rem .6rem;border-top:1px solid var(--genie-order-line,#dfe3e8);background:var(--genie-order-bg,#fff);color:var(--genie-order-fg,inherit);font-size:.9rem}
.genie-order[hidden]{display:none}
.genie-order strong{display:block;font-size:.72rem;text-transform:uppercase;letter-spacing:.08em;opacity:.75;margin-bottom:.2rem}
.genie-order ol{list-style:none;margin:0;padding:0;max-height:7.5rem;overflow:auto}
.genie-order li{padding:.12rem 0}
