/* XSGround's focused engineering workspace. The existing chat is kept alive. */
.ai-workspace-only { display: none; }
body.ai-workspace-open { overflow: hidden; }
#toolPanel.is-ai-workspace {
  --glass-text: #17334c;
  --glass-muted: #5c7186;
  --feature-status-error: #a32237;
  position: fixed !important;
  inset: 0 !important;
  z-index: 1035 !important; /* Below Bootstrap's result/history dialogs. */
  display: grid !important;
  grid-template-columns: 260px minmax(0, 1fr);
  width: 100% !important;
  min-width: 0 !important;
  max-width: none !important;
  height: 100dvh;
  border: 0;
  border-radius: 0;
  background: #fafcfd;
  color: #17334c;
  box-shadow: none;
  backdrop-filter: none;
  font-family: inherit;
}
.is-ai-workspace #toolPanelResizeHandle { display: none; }
.is-ai-workspace #toolPanelInner { min-width: 0; min-height: 0; height: 100%; }
.is-ai-workspace .ai-workspace-only { display: block; }
.is-ai-workspace .map-ai-panel-header {
  flex: 0 0 auto;
  min-height: 82px;
  padding: 18px 30px !important;
  gap: 16px;
  border-bottom: 1px solid #dee6ed !important;
  background: #fff;
}
.is-ai-workspace .map-ai-panel-title { font-size: 16px; font-weight: 700; }
.is-ai-workspace .map-ai-panel-title::before {
  content: "ENGINEERING WORKSPACE";
  display: block;
  font-size: 10px;
  letter-spacing: .13em;
  color: #62778a;
  margin-bottom: 4px;
}
.is-ai-workspace .btn-outline-light {
  color: #294d69;
  background: #fff;
  border-color: #cad8e4;
  border-radius: 10px;
}
.is-ai-workspace .btn-outline-light:hover { background: #eaf2f7; border-color: #8fa9bf; }
.is-ai-workspace #mapAiHistoryBtn { display: none; }
.is-ai-workspace #mapAiWorkspaceHistoryToggle { display: none; }
.is-ai-workspace [data-panel-close] { font-size: 13px; }
.ai-workspace-rail {
  min-height: 0;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 28px 18px 18px;
  border-right: 1px solid #dce5ee;
  background: #f0f5f9;
}
.ai-workspace-rail > :not(.ai-workspace-history-list) { flex-shrink: 0; }
.ai-workspace-brand { display: flex; align-items: center; gap: 10px; font-size: 23px; font-weight: 750; letter-spacing: -.7px; }
.ai-workspace-monogram {
  display: grid;
  place-items: center;
  height: 40px;
  width: 40px;
  border-radius: 12px 12px 12px 3px;
  background: #0a3d62;
  color: #fff;
  font-size: 17px;
  letter-spacing: -1px;
}
.ai-workspace-brand small { display: block; font-size: 8px; letter-spacing: .16em; color: #59758b; margin-top: 1px; }
.ai-workspace-project { display: flex; flex-direction: column; gap: 6px; margin: 32px 0 24px; padding: 14px; border: 1px solid #d3e0e9; border-radius: 12px; background: #f9fbfd; }
.ai-workspace-eyebrow { font-size: 9px; letter-spacing: .1em; color: #58738a; font-weight: 750; }
.ai-workspace-project strong { font-size: 14px; line-height: 1.5; overflow-wrap: anywhere; }
.ai-workspace-project > span:last-child { font-size: 11px; color: #627b8f; }
.ai-workspace-project-picker { width: 100%; margin-top: 4px; border: 1px solid #cad9e4; border-radius: 7px; background: #fff; color: #294d69; font-size: 12px; padding: 7px; }
.ai-workspace-data { margin: -12px 0 18px; border: 1px solid #d3e0e9; border-radius: 10px; background: #f9fbfd; color: #345972; }
.ai-workspace-data summary { cursor: pointer; display: flex; justify-content: space-between; gap: 8px; padding: 10px 12px; font-size: 11px; font-weight: 700; list-style: none; }
.ai-workspace-data summary::-webkit-details-marker { display: none; }
.ai-workspace-data summary::after { content: "+"; color: #52728a; }
.ai-workspace-data[open] summary::after { content: "−"; }
.ai-workspace-data summary small { color: #667f94; font-weight: 500; }
.ai-workspace-data p { margin: 0; padding: 0 12px 9px; color: #617b8f; font-size: 10px; line-height: 1.5; }
.ai-workspace-data-list { max-height: min(220px, 25dvh); overflow-y: auto; overscroll-behavior: contain; scrollbar-gutter: stable; border-top: 1px solid #e0e9ef; padding: 5px 12px 8px; font-size: 11px; }
.ai-workspace-data-list > div { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; }
.ai-workspace-data-list strong { color: #58738a; font-size: 10px; font-weight: 600; white-space: nowrap; }
.ai-workspace-new { width: 100%; background: #0a3d62; color: #fff; border: 1px solid #0a3d62; border-radius: 10px; padding: 11px 8px; font-size: 13px; font-weight: 600; }
.ai-workspace-new:hover { background: #12547d; }
.ai-workspace-document-slot{margin:12px 0 4px}.ai-workspace-document{width:100%;border:1px solid #bfd2e1;border-radius:10px;background:#fff;color:#0a4d78;padding:10px 8px;font-size:12px;font-weight:700}.ai-workspace-document:hover{background:#eaf3f8}.ai-workspace-profile{position:relative;margin-top:18px;border-top:1px solid #d7e2eb;padding-top:12px}.ai-workspace-profile summary{display:flex;align-items:center;gap:8px;cursor:pointer;list-style:none;font-size:12px;font-weight:700;color:#234a65}.ai-workspace-profile summary::-webkit-details-marker{display:none}.ai-workspace-profile-icon{display:grid;place-items:center;width:28px;height:28px;border-radius:50%;background:#0a4d78;color:#fff;font-size:15px}.ai-workspace-profile-menu{display:grid;gap:3px;margin:9px 0 0 36px}.ai-workspace-profile-menu a{border-radius:6px;color:#315b77;font-size:11px;padding:5px 7px;text-decoration:none}.ai-workspace-profile-menu a:hover{background:#e1ecf4;color:#0a4d78}
.ai-workspace-history-heading { display: flex; justify-content: space-between; align-items: center; margin: 28px 5px 10px; }
.ai-workspace-history-heading h2 { font-size: 11px; font-weight: 700; color: #59738a; margin: 0; text-transform: uppercase; letter-spacing: .06em; }
.ai-workspace-refresh { border: 0; background: transparent; color: #47667f; font-size: 21px; padding: 0 7px; border-radius: 6px; }
.ai-workspace-history-list { flex: 1; min-height: 0; overflow: auto; }
.ai-workspace-history-item { display: flex; flex-direction: column; gap: 4px; text-align: left; width: 100%; padding: 11px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: #27465e; margin-bottom: 3px; }
.ai-workspace-history-item:hover, .ai-workspace-history-item[aria-current] { background: #e2ecf4; border-color: #d0dfeb; }
.ai-workspace-history-item span { width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.ai-workspace-history-item small { font-size: 10px; color: #667f94; }
.ai-workspace-note { padding: 8px; font-size: 12px; color: #637b8e; line-height: 1.6; }
.ai-workspace-history-retry { border: 1px solid #c8d8e5; background: #fff; border-radius: 8px; padding: 6px 12px; color: #294d69; }
.ai-workspace-rail-foot { border-top: 1px solid #d7e2eb; margin-top: 16px; padding: 18px 5px 0; font-size: 11px; color: #345972; }
.ai-workspace-rail-foot p { margin: 8px 0 0; font-size: 10px; color: #6b8192; line-height: 1.7; }
.ai-workspace-profile-icon{overflow:hidden}.ai-workspace-profile-photo{width:100%;height:100%;object-fit:cover}.ai-workspace-document-view{display:none}.is-ai-workspace.ai-workspace-document-open .map-ai-chat,.is-ai-workspace.ai-workspace-document-open .map-ai-compose{display:none}.is-ai-workspace.ai-workspace-document-open .ai-workspace-document-view{display:block;flex:1;min-height:0;width:min(100%,920px);align-self:center;overflow:auto;padding:48px 22px;color:#173a5c}.ai-workspace-document-view>header{display:flex;justify-content:space-between;gap:28px;border-bottom:1px solid #dce7ef;padding-bottom:28px}.ai-workspace-document-view>header span{color:#087ba8;font-size:11px;font-weight:800;letter-spacing:.11em}.ai-workspace-document-view h1{max-width:620px;margin:10px 0;font-size:clamp(29px,3vw,44px);line-height:1.22}.ai-workspace-document-view header p{max-width:650px;margin:0;color:#627b8e;font-size:15px;line-height:1.65}.ai-workspace-document-view header button{align-self:flex-start;border:0;background:transparent;color:#60798d;font-size:34px;line-height:1;padding:0}.ai-document-upload{display:grid;max-width:680px;gap:18px;margin:38px auto}.ai-document-upload label{display:flex;min-height:230px;align-items:center;justify-content:center;flex-direction:column;gap:10px;border:1.5px dashed #74b6d8;border-radius:16px;background:#f5fafc;cursor:pointer;text-align:center}.ai-document-upload input{position:absolute;width:1px;height:1px;opacity:0}.ai-document-upload strong{font-size:17px;color:#0a4d78}.ai-document-upload small{color:#6a8497}.ai-document-upload button{min-height:44px;border:0;border-radius:10px;background:#0a4d78;color:#fff;font-size:14px;font-weight:750}.ai-document-upload button:disabled{background:#7896ab}.ai-document-status{max-width:680px;margin:0 auto;color:#537187;text-align:center}.ai-document-result{max-width:680px;margin:28px auto;padding:22px;border:1px solid #cfe2ec;border-radius:14px;background:#f7fbfd}.ai-document-result h2{margin:0 0 8px;font-size:18px}.ai-document-result p{margin:6px 0;color:#58748a;line-height:1.55}
.ai-workspace-live-dot { display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: #25838d; margin-right: 6px; }
.is-ai-workspace .map-ai-panel { flex: 1; min-height: 0; overflow: hidden; padding: 0 32px 18px; gap: 0; }
.is-ai-workspace .map-ai-chat { order: 0; flex: 1; min-height: 0; width: min(100%, 900px); align-self: center; border: 0; padding: 34px 10px 24px; gap: 28px; overscroll-behavior: contain; }
.is-ai-workspace .map-ai-compose { order: 1; flex: 0 0 auto; width: min(100%, 880px); align-self: center; padding: 16px 18px 10px; border: 1px solid #cbd9e4; border-radius: 18px; background: #fff; box-shadow: 0 4px 24px #1437510b; gap: 10px; }
.is-ai-workspace .map-ai-quick-prompts { display: none; }
.is-ai-workspace .map-ai-compose label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
.is-ai-workspace .map-ai-prompt { border: 0; box-shadow: none; border-radius: 4px; background: #fff; color: #17334c; font-size: 15px; min-height: 65px; max-height: 180px; padding: 2px 0; resize: vertical; }
.is-ai-workspace .map-ai-prompt::placeholder { color: #70869b; }
.is-ai-workspace .map-ai-compose-actions { align-items: center; }
.is-ai-workspace .map-ai-compose-hint { flex: 1; font-size: 10px; color: #647f94; }
.is-ai-workspace #mapAiAskBtn { flex: 0 0 auto !important; padding: 8px 19px; border-radius: 10px; background: #0a3d62; border-color: #0a3d62; font-size: 13px; }
.is-ai-workspace #mapAiClearBtn { font-size: 12px; }
.is-ai-workspace .map-ai-status:empty { display: none; }
.is-ai-workspace .map-ai-message { flex-shrink: 0; background: none; border: 0; border-radius: 14px; padding: 4px 0; }
.is-ai-workspace .map-ai-message.is-user { max-width: 85%; border: 1px solid #dce5ed; background: #edf3f8; padding: 15px 20px; }
.is-ai-workspace .map-ai-message-head { font-size: 10px; color: #5b758b; letter-spacing: .08em; margin-bottom: 4px; }
.is-ai-workspace .map-ai-message.is-assistant .map-ai-message-head { color: #0a5276; }
.is-ai-workspace .map-ai-message-body { font-size: 14px; line-height: 1.85; overflow-wrap: anywhere; }
.is-ai-workspace .map-ai-message.is-error { background: #fff3f3; color: #972638; padding: 16px; }
.map-ai-evidence { margin-top: 13px; border: 1px solid #cbdce8; border-radius: 9px; background: #f7fbfd; color: #294d69; padding: 9px 11px; }
.map-ai-evidence summary { cursor: pointer; color: #0a5276; font-size: 12px; font-weight: 700; }
.map-ai-evidence-note { color: #5f788d; font-size: 11px; line-height: 1.5; margin: 9px 0 6px; }
.map-ai-evidence ul { margin: 0 0 10px; padding-left: 18px; color: #49677e; font-size: 11px; line-height: 1.65; }
.map-ai-evidence .btn { margin-top: 2px; }
.is-ai-workspace .feature-ai-open-btn { color: #0a3d62; background: #e6f0f7; border-color: #bbd0e0; }
.is-ai-workspace .map-ai-empty { display: flex; flex-direction: column; justify-content: center; flex: 1; border: 0; background: none; padding: 25px 10px; text-align: center; }
.is-ai-workspace .map-ai-empty > p { display: none; }
.ai-workspace-welcome-mark { display: grid; place-items: center; width: 60px; height: 60px; margin: 0 auto 24px; color: #0a3d62; background: #e3eef5; border: 1px solid #ccdfea; border-radius: 18px 18px 18px 4px; font-size: 24px; font-weight: 750; letter-spacing: -1px; box-shadow: 7px 7px 0 #f0f5f8; }
.ai-workspace-welcome h1 { font-size: clamp(24px, 2.4vw, 34px); line-height: 1.3; letter-spacing: -.8px; color: #17334c; margin: 0 0 12px; font-weight: 650; }
.ai-workspace-welcome > p { font-size: 14px; line-height: 1.8; max-width: 480px; margin: 0 auto 28px; color: #61798d; }
.ai-workspace-suggestions { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.ai-workspace-suggestion { display: flex; flex-direction: column; gap: 8px; text-align: left; border: 1px solid #d7e3ec; background: #fff; color: #264d68; border-radius: 12px; padding: 17px; }
.ai-workspace-suggestion:hover { background: #f0f6fa; border-color: #8ab0ca; }
.ai-workspace-suggestion strong { font-size: 12px; font-weight: 650; }
.ai-workspace-suggestion span { font-size: 11px; line-height: 1.65; color: #678094; }
.is-ai-workspace button:focus-visible, .is-ai-workspace textarea:focus-visible { outline: 2px solid #1684aa; outline-offset: 3px; }
.is-ai-workspace button:disabled { opacity: .5; cursor: not-allowed; }
@media (max-width: 1050px) {
  #toolPanel.is-ai-workspace { grid-template-columns: 220px minmax(0, 1fr); }
  .ai-workspace-rail { padding: 24px 12px 16px; }
  .is-ai-workspace .map-ai-panel { padding: 0 20px 14px; }
  .ai-workspace-suggestions { gap: 8px; }
  .ai-workspace-suggestion { padding: 12px; }
}
@media (max-width: 760px) {
  #toolPanel.is-ai-workspace { grid-template-columns: minmax(0, 1fr); }
  .is-ai-workspace .ai-workspace-rail { display: none; }
  .is-ai-workspace #mapAiWorkspaceHistoryToggle { display: block; }
  .is-ai-workspace.ai-workspace-history-open .ai-workspace-rail { display: flex; position: absolute; z-index: 4; top: var(--ai-workspace-header-height, 82px); bottom: 0; left: 0; width: min(300px, 85vw); box-shadow: 15px 0 30px #14375120; }
  .is-ai-workspace .map-ai-panel-header { padding: 14px !important; gap: 8px; flex-wrap: wrap; }
  .is-ai-workspace .map-ai-panel-title { font-size: 14px; }
  .is-ai-workspace .map-ai-panel-title::before { font-size: 8px; }
  .is-ai-workspace .map-ai-panel { padding: 0 12px max(12px, env(safe-area-inset-bottom)); }
  .is-ai-workspace .map-ai-chat { padding: 24px 2px 18px; }
  .is-ai-workspace .map-ai-compose { padding: 12px; border-radius: 14px; }
  .is-ai-workspace .map-ai-compose-hint { display: none; }
  .is-ai-workspace #mapAiAskBtn { margin-left: auto; }
  .is-ai-workspace .map-ai-message.is-user { max-width: 95%; }
  .ai-workspace-suggestions { grid-template-columns: 1fr; text-align: left; }
  .ai-workspace-suggestion { padding: 12px 14px; gap: 3px; }
  .ai-workspace-welcome-mark { margin-bottom: 18px; }
}
@media (max-height: 700px) {
  .is-ai-workspace .map-ai-empty { justify-content: flex-start; padding: 8px 0; }
  .ai-workspace-welcome-mark { display: none; }
  .ai-workspace-welcome > p { margin-bottom: 16px; }
}

.ai-workspace-change-project{align-self:flex-start;border:0;background:transparent;color:#37678a;font-size:11px;padding:2px 0;text-decoration:underline}.ai-workspace-project-options{display:grid;gap:7px}.ai-workspace-project-options[hidden]{display:none}.ai-workspace-project-options a{font-size:12px;color:#315b77}.ai-workspace-profile-menu button{border:0;background:transparent;text-align:left;border-radius:6px;color:#315b77;font-size:11px;padding:5px 7px}.ai-workspace-account-open .map-ai-compose,.ai-workspace-account-open .map-ai-thread,.ai-workspace-account-open .ai-workspace-document-view:not(#mapAiAccountView){display:none!important}.ai-workspace-usage-table{overflow:auto}.ai-workspace-usage-table table{width:100%;font-size:12px;border-collapse:collapse}.ai-workspace-usage-table th,.ai-workspace-usage-table td{padding:12px 8px;border-bottom:1px solid #d5e2eb;text-align:left;white-space:nowrap}

.is-ai-workspace.ai-workspace-account-open #mapAiAccountView:not([hidden]){display:block;flex:1;min-height:0;width:min(100%,1100px);align-self:center;overflow:auto;padding:40px 22px;color:#173a5c}.ai-workspace-account-open .map-ai-chat{display:none!important}

#mapAiAccountView[hidden],#mapAiDocumentIntake[hidden]{display:none!important}
