/* BZDR Engineering Copilot — shared desktop/Electron and mobile-browser UI */
#bzdrCopilotLauncher {
  position:fixed;right:max(14px,env(safe-area-inset-right));
  bottom:calc(86px + env(safe-area-inset-bottom));
  z-index:850;background:linear-gradient(128deg,#c8fa63,#77e9c5);
  color:#11221b;border:1px solid #d2ffb0;border-radius:999px;
  padding:11px 17px;font-weight:800;letter-spacing:.025em;
  box-shadow:0 12px 30px #0008;touch-action:manipulation;
}
#bzdrCopilotLauncher:focus-visible,.bzdr-copilot-panel button:focus-visible {
  outline:2px solid #bafa88;outline-offset:3px;
}
.bzdr-copilot-panel {
  position:fixed;right:max(14px,env(safe-area-inset-right));
  bottom:calc(140px + env(safe-area-inset-bottom));
  z-index:860;width:min(430px,calc(100vw - 28px));
  max-height:min(75dvh,730px);display:flex;flex-direction:column;gap:12px;
  overflow:hidden;box-sizing:border-box;padding:16px;
  color:#e6f3f2;background:linear-gradient(150deg,rgba(23,35,42,.985),rgba(7,18,25,.985));
  border:1px solid #45676b;border-radius:18px;
  box-shadow:0 25px 60px #000b;font-size:13px;
}
.bzdr-copilot-panel[hidden]{display:none!important}
.bzdr-copilot-head {display:flex;align-items:start;justify-content:space-between;gap:12px}
.bzdr-copilot-head span{display:flex;flex-direction:column;gap:2px}
.bzdr-copilot-head strong {color:#d5ffa8;font-size:15px;letter-spacing:.04em}
.bzdr-copilot-head small {font-size:10px;color:#92a8b0;letter-spacing:.1em}
.bzdr-copilot-panel button {font:inherit;cursor:pointer;background:#203841;color:#edf9f4;border:1px solid #476067;border-radius:9px;padding:8px 10px}
.bzdr-copilot-panel button:disabled {opacity:.42;cursor:not-allowed}
.bzdr-copilot-head button {background:transparent;font-size:20px;padding:1px 9px;line-height:1.3}
.bzdr-copilot-tabs,.bzdr-copilot-actions,.bzdr-copilot-footer {display:flex;gap:7px;flex-wrap:wrap}
.bzdr-copilot-tabs button {flex:1;min-width:90px}
.bzdr-copilot-tabs [aria-pressed=true] {background:#d5ffa8;color:#13241b;font-weight:750;border-color:#d5ffa8}
.bzdr-copilot-note {margin:0;color:#a8b9bc;line-height:1.4}
.bzdr-copilot-label {font-size:11px;text-transform:uppercase;font-weight:700;letter-spacing:.08em;color:#c1d2d5}
#bzdrCopilotInput {resize:vertical;min-height:64px;width:100%;box-sizing:border-box;max-height:160px;
 color:#f0f9f6;background:#0b1b24;border:1px solid #547077;border-radius:10px;
 font:inherit;padding:10px;line-height:1.45}
.bzdr-copilot-actions button{flex:1;min-width:90px;font-size:12px}
#bzdrCopilotOutput {min-height:42px;overflow-y:auto;overscroll-behavior:contain;padding:10px;
 border:1px solid #314b50;border-radius:11px;background:#091a2299;line-height:1.45}
#bzdrCopilotOutput strong{font-size:12px;color:#d0ffae;display:block;margin:5px 0}
#bzdrCopilotOutput ul {list-style:disc;margin:4px 0 12px;padding-left:19px}
#bzdrCopilotOutput li {margin:5px 0;overflow-wrap:anywhere}
#bzdrCopilotOutput p {margin:0}
#bzdrCopilotOutput .bzdr-copilot-error {color:#ffb1a7}
#bzdrCopilotOutput .bzdr-copilot-success {color:#bafa88}
#bzdrCopilotOutput .bzdr-copilot-info {color:#b6d3da}
.bzdr-copilot-footer {justify-content:space-between}
.bzdr-copilot-footer .bzdr-copilot-primary {background:#c3f78d;color:#173024;border-color:#c3f78d;font-weight:800}
@media(min-width:900px){
 #bzdrCopilotLauncher{bottom:22px;right:23px}
 .bzdr-copilot-panel{bottom:75px;right:23px}
}
@media(max-width:899px){
 .bzdr-copilot-panel{left:0;right:0;bottom:0;width:100%;max-height:min(78dvh,850px);
 border-radius:18px 18px 0 0;padding:16px 15px calc(16px + env(safe-area-inset-bottom));
 border-left:0;border-right:0;border-bottom:0}
}
@media(max-width:899px) and (orientation:landscape) and (max-height:520px){
 #bzdrCopilotLauncher{bottom:calc(8px + env(safe-area-inset-bottom));right:10px;padding:7px 11px}
 .bzdr-copilot-panel{left:auto;right:0;width:min(430px,80vw);height:100dvh;max-height:100dvh;
  border-radius:14px 0 0 14px;padding:10px 12px 10px;gap:7px}
 #bzdrCopilotInput{min-height:35px}
}


/* Mode identity, workflow state and reachable controls on short screens. */
.bzdr-copilot-panel{--copilot-accent:#b8f3c5;width:min(490px,calc(100vw - 28px));overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;max-height:min(82dvh,850px)}
.bzdr-copilot-panel[data-assistant-mode="mix"]{--copilot-accent:#cebaff;border-color:#786a9e}
.bzdr-copilot-panel [hidden]{display:none!important}
.bzdr-copilot-mode-card{padding:12px 14px;border:1px solid #506b68;border-left:4px solid var(--copilot-accent);border-radius:12px;background:#10222e;flex-shrink:0}
.bzdr-copilot-mode-card strong{display:block;color:var(--copilot-accent);font-size:16px}.bzdr-copilot-mode-card p{margin:5px 0 10px;line-height:1.45;color:#d1e0e7}
#bzdrCopilotStage{display:block;font-size:11px;color:#b6c9d3;letter-spacing:.02em}
.bzdr-copilot-tabs button{min-height:44px}.bzdr-copilot-tabs [aria-pressed=true]{background:var(--copilot-accent);border-color:var(--copilot-accent)}
.bzdr-copilot-panel button{min-height:42px}.bzdr-copilot-panel #bzdrCopilotInput{flex-shrink:0}
.bzdr-copilot-actions{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));flex-shrink:0}.bzdr-copilot-actions button{min-width:0;line-height:1.3}
#bzdrCopilotOutput{flex-shrink:0;min-height:60px;max-height:300px}.bzdr-copilot-footer{position:sticky;bottom:-16px;background:#0b1a23;padding:10px 0 3px;flex-shrink:0}
.bzdr-copilot-footer .bzdr-copilot-primary{background:var(--copilot-accent);border-color:var(--copilot-accent)}
@media(max-width:899px){.bzdr-copilot-panel{width:100%;max-height:88dvh}.bzdr-copilot-footer{bottom:calc(-16px - env(safe-area-inset-bottom))}}
@media(max-width:899px) and (orientation:landscape) and (max-height:520px){.bzdr-copilot-panel{width:min(490px,88vw);max-height:100dvh}.bzdr-copilot-mode-card{padding:8px 10px}.bzdr-copilot-footer{bottom:-10px}}
