/* In-page AI order assistant (header "Call" = voice, "WhatsApp" = text chat). Bottom sheet, mobile-first. */
body.ai-open { overflow:hidden; }
.ai-sheet { position:fixed; inset:0; z-index:100; background:#0009; display:flex; align-items:flex-end; justify-content:center; }
.ai-panel { width:100%; max-width:560px; height:min(92dvh, 760px); background:#efeae2; border-radius:16px 16px 0 0; display:flex; flex-direction:column; overflow:hidden; box-shadow:0 -6px 30px #0005; }
@media (min-width:700px) { .ai-sheet { align-items:center; } .ai-panel { border-radius:16px; } }
.ai-head { display:flex; align-items:center; gap:10px; padding:10px 12px; background:var(--black,#111); color:#fff; border-bottom:4px solid var(--yellow,#f5c518); }
.ai-sheet:not(.voice) .ai-head { background:#075e54; border-bottom-color:#25d366; }
.ai-av { width:36px; height:36px; border-radius:50%; background:var(--red,#d62828); color:var(--yellow,#f5c518); display:grid; place-items:center; font-weight:900; font-style:italic; font-family:Impact,"Arial Black",sans-serif; flex-shrink:0; }
.ai-ttl { flex:1; display:flex; flex-direction:column; line-height:1.2; min-width:0; }
.ai-ttl b { font-size:1rem; } .ai-ttl span { font-size:.75rem; opacity:.85; }
.ai-x { background:transparent; border:0; color:#fff; font-size:1.3rem; padding:6px 10px; cursor:pointer; }
.ai-body { flex:1; overflow-y:auto; padding:12px 10px; display:flex; flex-direction:column; gap:6px; -webkit-overflow-scrolling:touch; }
.ai-row { display:flex; } .ai-row.me { justify-content:flex-end; }
.ai-bub { max-width:82%; padding:8px 11px; border-radius:12px; font-size:.95rem; line-height:1.38; white-space:pre-wrap; word-wrap:break-word; box-shadow:0 1px 1px #0001; }
.ai-row.bot .ai-bub { background:#fff; border-top-left-radius:4px; }
.ai-row.me .ai-bub { background:#d9fdd3; border-top-right-radius:4px; }
.ai-sheet.voice .ai-row.me .ai-bub { background:#fff4c2; }
.ai-row.cap .ai-bub { font-size:1rem; }
.ai-dots { display:flex; gap:4px; padding:12px 14px; }
.ai-dots i { width:7px; height:7px; border-radius:50%; background:#999; animation:aiDot 1.2s infinite; }
.ai-dots i:nth-child(2) { animation-delay:.2s; } .ai-dots i:nth-child(3) { animation-delay:.4s; }
@keyframes aiDot { 0%,60%,100% { opacity:.3; transform:translateY(0); } 30% { opacity:1; transform:translateY(-3px); } }
.ai-note { align-self:center; text-align:center; max-width:92%; font-size:.8rem; color:#54656f; background:#fff8; border-radius:8px; padding:6px 10px; }
.ai-note a { color:#075e54; font-weight:600; }
.ai-order { align-self:center; background:#fff; border:2px solid var(--green,#0b7a3e); border-radius:12px; padding:10px 14px; text-align:center; display:flex; flex-direction:column; gap:3px; font-size:.88rem; }
.ai-order b { color:var(--green,#0b7a3e); font-size:1rem; }
.ai-again { align-self:center; margin-top:6px; background:var(--black,#111); color:var(--yellow,#f5c518); border:0; border-radius:10px; padding:10px 16px; font-weight:700; cursor:pointer; }
.ai-input { display:flex; gap:8px; padding:8px; background:#f0f2f5; border-top:1px solid #0001; padding-bottom:max(8px, env(safe-area-inset-bottom)); }
.ai-input input { flex:1; border:0; border-radius:22px; padding:11px 15px; font-size:16px; background:#fff; outline:none; }
.ai-input button { width:44px; height:44px; border-radius:50%; border:0; background:#00a884; color:#fff; font-size:1.1rem; cursor:pointer; }
.ai-input button:disabled, .ai-input input:disabled { opacity:.5; }
.ai-voice { display:flex; flex-direction:column; align-items:center; gap:10px; padding:14px 10px max(12px, env(safe-area-inset-bottom)); background:var(--black,#111); color:#fff; }
.ai-status { font-size:.92rem; min-height:1.2em; opacity:.92; }
.ai-mic { width:92px; height:92px; border-radius:50%; border:0; background:var(--red,#d62828); color:#fff; font-size:2.4rem; cursor:pointer; box-shadow:0 0 0 0 #d6282866; transition:transform .15s; }
.ai-mic:active { transform:scale(.95); }
.ai-voice.listen .ai-mic { background:var(--green,#0b7a3e); animation:aiPulse 1.6s infinite; }
.ai-voice.rec .ai-mic { background:var(--green,#0b7a3e); animation:aiPulse .8s infinite; }
.ai-voice.speak .ai-mic { background:#444; }
.ai-voice.busy .ai-mic { background:#555; opacity:.8; }
.ai-voice.listen .ai-mic-ico::after, .ai-voice.rec .ai-mic-ico::after { content:""; }
@keyframes aiPulse { 0% { box-shadow:0 0 0 0 #0b7a3eaa; } 70% { box-shadow:0 0 0 18px #0b7a3e00; } 100% { box-shadow:0 0 0 0 #0b7a3e00; } }
.ai-end { background:transparent; color:#fff; border:2px solid #ff5a4f; border-radius:22px; padding:8px 26px; font-weight:700; cursor:pointer; }
.ai-foot { margin:0; padding:5px 10px 7px; font-size:.68rem; text-align:center; color:#667; background:#f0f2f5; }
.ai-sheet.voice .ai-foot { background:var(--black,#111); color:#aaa; }
