/* ═══════════════════════════════════════
   DESIGN TOKENS (shared with dashboard.css)
═══════════════════════════════════════ */
:root {
  --font-sans: 'Inter', 'Segoe UI', Arial, sans-serif;
  --font-mono: 'Geist Mono', 'Courier New', monospace;
  --c-navy:          #20232A;
  --c-blue:          #2457C5;
  --c-blue-accent:   #4da6ff;
  --c-border:        #dde3ec;
  --c-border-light:  #d0d7e3;
  --c-surface-2:     #f4f6f9;
  --r-md:   8px;
  --r-lg:   12px;
  --r-xl:   16px;
  --r-pill: 9999px;
}

@scope (html) to (#project-inline-dashboard) {

*, *::before, *::after { box-sizing: border-box; }

/* ═══════════════════════════════════════
   AUTH PAGES
═══════════════════════════════════════ */
.auth-page {
  min-height: 100vh;
  background: linear-gradient(225deg, #20232A 0%, #2457C5 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  font-family: Inter, -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

.auth-card {
  background: #fff;
  border-radius: 16px;
  padding: 40px 36px;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 20px 60px rgba(0,0,0,0.2);
}

.auth-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}

.auth-logo-icon {
  font-size: 28px;
  color: #2457C5;
}

.auth-logo-text {
  font-size: 22px;
  font-weight: 700;
  color: #20232A;
  letter-spacing: -0.5px;
}

.auth-subtitle {
  color: #666;
  font-size: 13px;
  margin: 0 0 28px 0;
}

.auth-heading {
  font-size: 20px;
  font-weight: 600;
  color: #20232A;
  margin: 0 0 16px 0;
}

.auth-hint {
  color: #555;
  font-size: 14px;
  margin: 0 0 20px 0;
}

.auth-alert {
  padding: 10px 14px;
  border-radius: 6px;
  font-size: 13px;
  margin-bottom: 16px;
}

.auth-alert--error {
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
}

.auth-alert--success {
  background: #f0fdf4;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.btn-google {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  box-sizing: border-box;
  padding: 11px 16px;
  background: #fff;
  border: 1.5px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  color: #333;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
}

.btn-google:hover {
  background: #f9f9f9;
  border-color: #bbb;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: #bbb;
  font-size: 12px;
}

.auth-divider::before,
.auth-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e5e5e5;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-field {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.form-field label {
  font-size: 13px;
  font-weight: 500;
  color: #444;
}

.form-field input {
  padding: 9px 12px;
  border: 1.5px solid #ddd;
  border-radius: 6px;
  font-size: 14px;
  color: #222;
  outline: none;
  transition: border-color 0.15s;
}

.form-field input:focus {
  border-color: #2457C5;
  box-shadow: 0 0 0 3px rgba(46,117,182,0.1);
}

.btn-primary {
  padding: 11px 16px;
  background: #2457C5;
  color: #fff;
  border: none;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}

.btn-primary:hover {
  background: #2457C5;
}

.btn-primary.btn-dark {
  background: #111;
  border-radius: 999px;
}
.btn-primary.btn-dark:hover { background: #333; }

.auth-text-btn {
  background: none;
  border: none;
  color: #666;
  font-size: 13px;
  cursor: pointer;
  text-decoration: none;
  padding: 0;
}
.auth-text-btn:hover { color: #333; text-decoration: underline; }

.auth-footer {
  margin-top: 20px;
  text-align: center;
  font-size: 13px;
}

.auth-footer a {
  color: #2457C5;
  text-decoration: none;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* ═══════════════════════════════════════
   DASHBOARD NAV ADDITIONS
═══════════════════════════════════════ */
.nav-user {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
}
.nav-user-block {
  display: flex;
  align-items: center;
  gap: 8px;
  height: 34px;
  border-radius: 8px;
  padding: 0 10px;
  cursor: default;
}

.nav-user-info {
  display: flex;
  align-items: center;
  gap: 7px;
}

.nav-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: linear-gradient(225deg, #20232A, #2457C5);
  color: #fff;
  font-size: 10px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0;
}

.nav-user-name {
  font-size: 13px;
  font-weight: 500;
  color: #666666;
  max-width: 120px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.nav-vdivider {
  width: 1px;
  height: 22px;
  background: #E8ECF1;
  flex-shrink: 0;
}

.nav-admin-btn {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 0 14px;
  height: 34px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #666666;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.nav-admin-btn:hover { background: #F4F6F9; color: #20232A; }

/* Ask Agent chat button */
.nav-chat-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 0 14px;
  height: 34px;
  border-radius: 8px;
  border: 1px solid #C5DFFF;
  background: #F0F6FF;
  color: #2457C5;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.nav-chat-btn:hover { background: #E0EEFF; border-color: #93C5FD; }
.nav-chat-btn.active { background: #DBEAFE; }

/* Feedback button: make on/off unmistakable. Off (no .active) is greyed out;
   on (.active) is a solid accent fill. Scoped to the feedback buttons so the
   "Ask Agent" button keeps its default blue style. */
#nav-feedback-btn,
#nav-feedback-btn-iframe {
  background: #F1F3F5;
  border-color: #DDE1E6;
  color: #8A94A6;
}
#nav-feedback-btn:hover,
#nav-feedback-btn-iframe:hover {
  background: #E6E9ED;
  border-color: #C4CAD3;
  color: #5B6472;
}
#nav-feedback-btn.active,
#nav-feedback-btn-iframe.active {
  background: #2457C5;
  border-color: #2457C5;
  color: #fff;
}
#nav-feedback-btn.active:hover,
#nav-feedback-btn-iframe.active:hover {
  background: #1E4AAC;
  border-color: #1E4AAC;
}

.nav-logout-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 8px;
  border: none;
  background: none;
  color: #BBBBBB;
  cursor: pointer;
  text-decoration: none;
  transition: color 0.15s, background 0.15s;
}
.nav-logout-btn:hover { color: #20232A; background: #F4F6F9; }

/* ═══════════════════════════════════════
   MAIN WRAPPER (dashboard + sidebar)
═══════════════════════════════════════ */
.main-wrapper {
  display: flex;
  position: relative;
  height: calc(100vh - 56px - 40px - 48px); /* nav (56) + sub-navbar (40) + filter-bar (48) */
  overflow: hidden;
}

.dashboard-content {
  flex: 1;
  min-width: 0;
  transition: width 0.3s ease;
  overflow: hidden;
  position: relative;
}

/* ═══════════════════════════════════════
   CHAT SIDEBAR
═══════════════════════════════════════ */
.chat-sidebar {
  width: 0;
  min-width: 0;
  overflow: hidden;
  position: absolute;
  top: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 420;
  height: calc(100% - 24px);
  box-sizing: border-box;
  transition: box-shadow 0.15s ease;
  background: #fff;
  border: 1px solid #d8e0eb;
  border-radius: 12px;
  box-shadow: 0 18px 48px rgba(32, 35, 42, 0.18);
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  resize: none;
}

.chat-sidebar.open {
  width: 380px;
  min-width: 320px;
  min-height: min(280px, calc(100% - 24px));
  max-width: calc(100% - 24px);
  max-height: calc(100% - 24px);
  resize: both;
}

.chat-sidebar.open.expanded {
  width: min(600px, calc(100% - 24px));
  min-width: 320px;
}

.chat-sidebar.dragging {
  transition: none;
  box-shadow: 0 22px 58px rgba(32, 35, 42, 0.24);
}

.chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid #dde3ec;
  background: #fff;
  flex-shrink: 0;
}

.chat-header-title {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 14px;
  font-weight: 700;
  color: #20232A;
}

.chat-mode-badge {
  flex-basis: 100%;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10px;
  font-weight: 400;
  color: #8a9099;
  margin-top: -2px;
  padding-left: 36px;
  letter-spacing: 0.2px;
  cursor: pointer;
  user-select: all;
  transition: color 0.15s;
}
.chat-mode-badge:hover { color: #2457C5; }
.chat-mode-badge:empty { display: none; }

.chat-header-icon {
  width: 28px;
  height: 28px;
  background: rgba(46,117,182,0.12);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #2457C5;
}

.chat-online-badge {
  font-size: 10px;
  font-weight: 600;
  background: #d4edda;
  color: #155724;
  padding: 2px 8px;
  border-radius: 9999px;
}

.chat-close-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: #888;
  font-size: 16px;
  padding: 2px 6px;
  border-radius: 4px;
  line-height: 1;
}

.chat-close-btn:hover {
  background: #e8edf5;
  color: #333;
}

.chat-messages {
  flex: 1;
  overflow-y: auto;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.chat-welcome {
  color: #555;
  font-size: 13px;
  line-height: 1.5;
}

.chat-welcome p {
  margin: 0 0 12px 0;
}

.chat-suggestions {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.chat-suggestion {
  background: #f0f4fa;
  border: 1px solid #dde3ed;
  border-radius: 8px;
  padding: 8px 12px;
  font-size: 12px;
  color: #2457C5;
  cursor: pointer;
  text-align: left;
  transition: background 0.15s;
}

.chat-suggestion:hover {
  background: #dde8f5;
}

/* Password show/hide toggle — wraps any input[type="password"][data-password-toggle] */
.password-field-wrapper {
  position: relative;
  display: block;
}
.password-field-wrapper input[type="password"],
.password-field-wrapper input[type="text"] {
  padding-right: 40px;
}
.password-toggle-btn {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 28px;
  height: 28px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: var(--db-radius-sm, 4px);
  color: var(--db-muted, #6B7280);
  cursor: pointer;
  opacity: 0.7;
  transition: opacity .15s, background .15s, color .15s;
}
.password-toggle-btn:hover {
  opacity: 1;
  background: rgba(32, 35, 42, 0.06);
  color: var(--db-ink, #20232A);
}
.password-toggle-btn:focus-visible {
  outline: 2px solid var(--db-blue, #2457C5);
  outline-offset: 1px;
  opacity: 1;
}
.password-toggle-btn[aria-pressed="true"] { color: var(--db-blue, #2457C5); opacity: 1; }

.chat-bubble {
  max-width: 100%;
  font-size: 13px;
  line-height: 1.5;
  position: relative;
}

/* Copy-to-clipboard button — bottom-right of each completed chat bubble */
.chat-bubble-copy-btn {
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 26px;
  height: 26px;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: var(--db-radius-sm, 4px);
  color: var(--db-muted, #6B7280);
  cursor: pointer;
  opacity: 0.55;
  transition: opacity .15s, background .15s, color .15s;
}
.chat-bubble--complete .chat-bubble-copy-btn { display: inline-flex; }
.chat-bubble-copy-btn:hover {
  opacity: 1;
  background: rgba(32, 35, 42, 0.06);
  color: var(--db-ink, #20232A);
}
.chat-bubble-copy-btn:focus-visible {
  outline: 2px solid var(--db-blue, #2457C5);
  outline-offset: 1px;
  opacity: 1;
}
.chat-bubble-copy-btn--copied,
.chat-bubble-copy-btn--copied:hover {
  color: var(--db-green, #237A57);
  opacity: 1;
  background: transparent;
}

/* Reserve space at bubble bottom-right so text doesn't run under the button */
.chat-bubble--complete { padding-bottom: 28px !important; padding-right: 14px !important; }
.chat-bubble-text { display: block; }

.chat-bubble--user {
  background: rgba(46,117,182,0.12);
  color: #20232A;
  padding: 12px;
  border-radius: 12px 4px 12px 12px;
  align-self: flex-end;
  max-width: 85%;
  white-space: pre-wrap;
  word-break: break-word;
}

.chat-bubble--assistant {
  background: #f4f6f9;
  color: #4a5568;
  padding: 12px;
  border-radius: 4px 12px 12px 12px;
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.5;
}

/* Markdown-rendered content inside assistant bubbles */
.chat-bubble--assistant > * { white-space: normal; }
.chat-bubble--assistant p { margin: 0 0 8px 0; }
.chat-bubble--assistant p:last-child { margin-bottom: 0; }
.chat-bubble--assistant ul,
.chat-bubble--assistant ol { margin: 4px 0 8px 0; padding-left: 20px; }
.chat-bubble--assistant ul:last-child,
.chat-bubble--assistant ol:last-child { margin-bottom: 0; }
.chat-bubble--assistant li { margin: 2px 0; }
.chat-bubble--assistant li > p { margin: 0; }
.chat-bubble--assistant strong,
.chat-bubble--assistant b { color: #20232A; font-weight: 600; }
.chat-bubble--assistant em,
.chat-bubble--assistant i { font-style: italic; }
.chat-bubble--assistant code {
  background: rgba(0, 0, 0, 0.06);
  padding: 1px 5px;
  border-radius: 3px;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
}
.chat-bubble--assistant pre {
  background: rgba(0, 0, 0, 0.06);
  padding: 8px 10px;
  border-radius: 6px;
  overflow-x: auto;
  margin: 4px 0 8px 0;
  white-space: pre;
}
.chat-bubble--assistant pre code {
  background: none;
  padding: 0;
  font-size: 12px;
}
.chat-bubble--assistant a { color: #2457C5; text-decoration: underline; }
.chat-bubble--assistant blockquote {
  margin: 4px 0;
  padding: 4px 10px;
  border-left: 3px solid #cbd5e0;
  color: #4a5568;
}
.chat-bubble--assistant h1,
.chat-bubble--assistant h2,
.chat-bubble--assistant h3,
.chat-bubble--assistant h4,
.chat-bubble--assistant h5,
.chat-bubble--assistant h6 {
  color: #20232A;
  font-weight: 600;
  line-height: 1.3;
  margin: 12px 0 4px 0;
}
.chat-bubble--assistant h1:first-child,
.chat-bubble--assistant h2:first-child,
.chat-bubble--assistant h3:first-child,
.chat-bubble--assistant h4:first-child,
.chat-bubble--assistant h5:first-child,
.chat-bubble--assistant h6:first-child { margin-top: 0; }
.chat-bubble--assistant h1 { font-size: 15px; }
.chat-bubble--assistant h2 { font-size: 14px; }
.chat-bubble--assistant h3 { font-size: 13px; }
.chat-bubble--assistant h4,
.chat-bubble--assistant h5,
.chat-bubble--assistant h6 { font-size: 12px; }
.chat-bubble--assistant hr {
  border: none;
  border-top: 1px solid #d9dee6;
  margin: 10px 0;
}
/* Tables: display:block so overflow-x scrolls a wide table inside the
   narrow (~360px) sidebar instead of breaking the bubble layout. */
.chat-bubble--assistant table {
  display: block;
  overflow-x: auto;
  width: 100%;
  border-collapse: collapse;
  margin: 6px 0 8px 0;
  font-size: 12px;
}
.chat-bubble--assistant table:last-child { margin-bottom: 0; }
.chat-bubble--assistant th,
.chat-bubble--assistant td {
  border: 1px solid #dde3ec;
  padding: 5px 8px;
  text-align: left;
  vertical-align: top;
  white-space: nowrap;
}
.chat-bubble--assistant th {
  background: #eef1f5;
  color: #20232A;
  font-weight: 600;
}

.chat-bubble--processing {
  font-style: italic;
  color: #6B7280;
}
.chat-bubble--processing::after {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  margin-left: 6px;
  border-radius: 50%;
  background: #6B7280;
  animation: chat-bubble-pulse 1.2s ease-in-out infinite;
}
@keyframes chat-bubble-pulse {
  0%, 100% { opacity: 0.3; }
  50% { opacity: 1; }
}
.chat-bubble--warning {
  background: #FEF3C7;
  color: #92400E;
  border: 1px solid #FCD34D;
}

.chat-bubble--error {
  background: #fef2f2;
  color: #b91c1c;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 12px;
  border: 1px solid #fecaca;
}

.chat-tool-chip {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #20232A;
  color: #a8c4e0;
  padding: 3px 8px;
  border-radius: 4px;
  font-size: 11px;
  font-family: monospace;
  margin: 4px 0;
}

/* Marker rendered after /clear command — separates old context from new chat. */
.chat-divider {
  text-align: center;
  font-size: 11px;
  color: var(--db-muted, #6B7280);
  padding: 6px 0;
  margin: 14px 0;
  border-top: 1px dashed var(--db-border, #D9DEE6);
  border-bottom: 1px dashed var(--db-border, #D9DEE6);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.chat-tool-chip::before {
  content: '⚙';
  font-style: normal;
}

.chat-tool-chip--active::after {
  content: '';
  width: 6px;
  height: 6px;
  margin-left: 2px;
  border-radius: 50%;
  background: #78A8FF;
  animation: chat-tool-pulse 1s ease-in-out infinite;
}

@keyframes chat-tool-pulse {
  0%, 100% {
    opacity: 0.35;
    transform: scale(0.72);
  }
  50% {
    opacity: 1;
    transform: scale(1);
  }
}

.chat-typing {
  display: flex;
  gap: 4px;
  padding: 10px 14px;
  background: #f0f4fa;
  border-radius: 12px 12px 12px 4px;
  width: fit-content;
}

.chat-typing span {
  width: 6px;
  height: 6px;
  background: #2457C5;
  border-radius: 50%;
  animation: chat-bounce 1.2s infinite;
}

.chat-typing span:nth-child(2) { animation-delay: 0.2s; }
.chat-typing span:nth-child(3) { animation-delay: 0.4s; }

@keyframes chat-bounce {
  0%, 80%, 100% { transform: translateY(0); opacity: 0.4; }
  40% { transform: translateY(-6px); opacity: 1; }
}

.chat-input-area {
  padding: 14px;
  border-top: 1px solid #dde3ec;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex-shrink: 0;
}

.chat-toolbar {
  display: flex;
  align-items: center;
  gap: 8px;
}

.chat-toolbar-label {
  font-size: 11px;
  color: #6b7380;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.chat-toolbar-select {
  flex: 1;
  border: 1px solid #d0d7e3;
  border-radius: 8px;
  padding: 5px 8px;
  font-size: 12px;
  font-family: inherit;
  background: #f4f6f9;
  color: #333;
  cursor: pointer;
  outline: none;
  min-width: 0;
}

.chat-toolbar-select:focus {
  border-color: #2457C5;
  background: #fff;
}

.chat-input-row {
  display: flex;
  gap: 8px;
  align-items: flex-end;
}

.chat-input {
  flex: 1;
  resize: none;
  border: 1px solid #d0d7e3;
  border-radius: 12px;
  padding: 10px 14px;
  font-size: 13px;
  font-family: inherit;
  outline: none;
  max-height: 120px;
  overflow-y: auto;
  line-height: 1.4;
  background: #f4f6f9;
}

.chat-input:focus {
  border-color: #2457C5;
  background: #fff;
  box-shadow: 0 0 0 3px rgba(46,117,182,0.08);
}

.chat-send-btn {
  width: 36px;
  height: 36px;
  background: #2457C5;
  color: #fff;
  border: none;
  border-radius: 10px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.15s;
}

.chat-send-btn:hover { background: #2457C5; }
.chat-send-btn:disabled { background: #bbb; cursor: not-allowed; }

.chat-input-hint {
  font-size: 10px;
  color: #aaa;
  text-align: center;
}

/* Mobile FAB */
.chat-fab {
  display: none;
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 52px;
  height: 52px;
  background: #2457C5;
  color: #fff;
  border: none;
  border-radius: 50%;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(46,117,182,0.4);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

/* ═══════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════ */
@media (max-width: 768px) {
  .chat-fab { display: flex; }
  .nav-chat-btn { display: none; }
  .nav-user-name { display: none; }

  /* Push map legend above the chat FAB */
  .map-legend { bottom: 80px !important; }

  .chat-sidebar {
    position: fixed;
    inset: 0 !important;
    z-index: 500;
    height: 100dvh !important;
    max-width: none !important;
    max-height: none !important;
    width: 0 !important;
    min-width: 0 !important;
    min-height: 0 !important;
    border: 0;
    border-radius: 0;
    resize: none !important;
  }

  .chat-sidebar.open {
    width: 100vw !important;
    min-width: 100vw !important;
  }
}

@media print {
  .chat-sidebar { display: none; }
  .nav-user { display: none; }
}

/* ── Chart card in chat ─────────────────────────────── */
.chat-chart-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  padding: 12px;
  margin: 6px 0;
  width: 100%;
  box-sizing: border-box;
}

.chat-chart-metrics {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}

.chat-chart-metric {
  background: #f8fafc;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 8px 12px;
  flex: 1;
  min-width: 80px;
  text-align: center;
}

.metric-label {
  font-size: 10px;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 2px;
}

.metric-value {
  font-size: 14px;
  font-weight: 700;
  color: #111827;
}

.metric-delta {
  font-size: 11px;
  color: #10b981;
  margin-top: 2px;
}

.chat-chart-title {
  font-size: 12px;
  font-weight: 600;
  color: #374151;
  margin-bottom: 8px;
}

.chat-chart-container {
  width: 100%;
  height: 200px;
}

/* ═══════════════════════════════════════
   PROJECT SWITCHER (navbar)
═══════════════════════════════════════ */
.nav-version {
  font-size: 10px;
  font-weight: 400;
  color: #bbb;
  font-family: monospace;
  letter-spacing: 0.02em;
}

.nav-project-switcher {
  position: relative;
  margin-right: 4px;
}

.nav-project-btn {
  display: flex;
  align-items: center;
  gap: 5px;
  height: 30px;
  padding: 0 4px;
  background: none;
  border: none;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  color: #555;
  cursor: pointer;
  transition: color 0.15s;
  white-space: nowrap;
}

.nav-project-btn:hover {
  color: #20232A;
}

.nav-project-menu {
  display: none;
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 180px;
  background: #fff;
  border: 1px solid #dde3ed;
  border-radius: 8px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.12);
  z-index: 200;
  max-height: calc(100vh - 76px);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.nav-project-menu.open {
  display: block;
}

.nav-project-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 9px 14px;
  font-size: 13px;
  color: #333;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  text-decoration: none;
  transition: background 0.1s;
}

.nav-project-item:hover {
  background: #f0f4fa;
}

.nav-project-item.active {
  color: #2457C5;
  font-weight: 600;
}

.nav-project-divider {
  height: 1px;
  background: #e8edf5;
  margin: 4px 0;
}

.nav-project-manage {
  color: #2457C5;
  font-size: 12px;
}

/* Project iframe */
.project-iframe-shell {
  width: 100%;
  height: 100%;
  min-height: 0;
  display: flex;
  flex-direction: column;
  background: #fff;
}

.dashboard-scenario-toolbar {
  flex: 0 0 auto;
  position: relative;
  display: flex;
  align-items: center;
  z-index: 1100;
}

.dashboard-scenario-toggle {
  appearance: none;
  border: 1px solid #D6DEE9;
  border-radius: 8px;
  background: #FFFFFF;
  color: #4A5872;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  flex: 0 0 auto;
  min-width: 0;
  width: fit-content;
  max-width: min(280px, 32vw);
  height: 34px;
  padding: 0 10px;
  text-align: left;
  transition: border-color 120ms ease, background 120ms ease, color 120ms ease;
  white-space: nowrap;
}

.dashboard-scenario-toggle:hover {
  border-color: #2E75B6;
  background: #F4F8FD;
  color: #0D4F8B;
}

.dashboard-scenario-toggle:focus-visible,
.dashboard-scenario-btn:focus-visible,
.dashboard-scenario-select:focus-visible {
  outline: 2px solid #2E75B6;
  outline-offset: 2px;
}

.dashboard-scenario-toggle-kicker {
  color: inherit;
  font: 600 13px/1 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.dashboard-scenario-toggle-value {
  max-width: min(130px, 14vw);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #7A8699;
  font: 500 12px/1.2 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.dashboard-scenario-toggle-chevron {
  width: 10px;
  color: #5B6780;
  font: 800 13px/1 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  text-align: center;
}

.dashboard-scenario-toggle-chevron::before {
  content: '>';
}

.dashboard-scenario-toolbar--expanded .dashboard-scenario-toggle-chevron::before {
  content: 'v';
}

.dashboard-scenario-panel {
  position: absolute;
  top: calc(100% + 10px);
  right: 0;
  z-index: 1200;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  width: min(760px, calc(100vw - 24px));
  max-height: min(420px, calc(100vh - 80px));
  padding: 12px;
  border: 1px solid #D6E0EE;
  border-radius: 12px;
  background: #FFFFFF;
  box-shadow: 0 14px 38px rgba(27, 39, 61, 0.18);
  overflow-x: hidden;
  overflow-y: auto;
}

.dashboard-scenario-toolbar--collapsed .dashboard-scenario-panel {
  display: none;
}

.dashboard-scenario-toolbar--expanded {
  z-index: 1200;
}

.dashboard-scenario-btn-group {
  display: inline-flex;
  align-items: center;
  gap: 0;
  border: 1px solid #D6E0EE;
  border-radius: 10px;
  overflow: hidden;
  background: #FFFFFF;
  box-shadow: 0 1px 0 rgba(27, 39, 61, 0.03);
}

.dashboard-scenario-label {
  font: 700 12px/1 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #5B6780;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.dashboard-scenario-select {
  min-width: min(320px, 46vw);
  max-width: min(420px, 60vw);
  padding: 7px 10px;
  border: 1px solid #C9D5E8;
  border-radius: 8px;
  background: #FFFFFF;
  color: #1E2A44;
  font: 600 13px/1.2 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.dashboard-scenario-btn {
  appearance: none;
  border: 0;
  border-right: 1px solid #D6E0EE;
  background: #FFFFFF;
  color: #1E2A44;
  cursor: pointer;
  padding: 8px 12px;
  font: 600 13px/1.2 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  transition: background 120ms ease, color 120ms ease, opacity 120ms ease;
}

.dashboard-scenario-btn-group .dashboard-scenario-btn:last-child {
  border-right: 0;
}

.dashboard-scenario-btn:hover {
  background: #F4F8FD;
  color: #0D4F8B;
}

.dashboard-scenario-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  color: #6A7690;
  background: #FFFFFF;
}

.dashboard-scenario-btn--primary {
  background: #2E75B6;
  color: #FFFFFF;
}

.dashboard-scenario-btn--primary:hover {
  background: #1F5F9B;
  color: #FFFFFF;
}

.dashboard-scenario-btn--primary:disabled {
  background: #9FBBDD;
  color: #FFFFFF;
}

.dashboard-scenario-btn--danger {
  color: #A63D40;
}

.dashboard-scenario-btn--danger:hover {
  background: #FFF3F3;
  color: #8F2D30;
}

.dashboard-scenario-status {
  order: 20;
  flex: 0 1 auto;
  max-width: min(520px, 100%);
  padding: 6px 10px;
  border: 1px solid #D6E0EE;
  border-radius: 8px;
  background: #F4F8FD;
  color: #4A5872;
  font: 600 12px/1.35 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

.dashboard-scenario-status:empty {
  display: none;
}

.dashboard-tab-strip {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  min-height: 42px;
  padding: 6px 12px;
  overflow-x: auto;
  border-bottom: 1px solid #DDE3EC;
  background: #F7F9FC;
}

.dashboard-tab-btn {
  appearance: none;
  border: 1px solid #C9D5E8;
  border-radius: 8px;
  background: #FFFFFF;
  color: #1E2A44;
  cursor: pointer;
  flex: 0 0 auto;
  max-width: min(280px, 45vw);
  padding: 7px 13px;
  font: 600 13px/1.2 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-decoration: none;
}

.dashboard-tab-btn:hover {
  border-color: #2E75B6;
  color: #0D4F8B;
}

.dashboard-tab-btn.active {
  background: #2E75B6;
  border-color: #2E75B6;
  color: #FFFFFF;
}

@media (max-width: 900px) {
  .dashboard-scenario-toggle {
    width: 34px;
    max-width: 34px;
    padding: 0;
  }

  .dashboard-scenario-toggle-kicker,
  .dashboard-scenario-toggle-value,
  .dashboard-scenario-toggle-chevron {
    display: none;
  }

  .dashboard-scenario-panel {
    position: fixed;
    top: 64px;
    right: 8px;
    left: 8px;
    width: auto;
    max-height: calc(100vh - 72px);
  }

  .dashboard-scenario-select {
    min-width: 100%;
    max-width: 100%;
    flex: 1 1 100%;
  }

  .dashboard-scenario-btn-group {
    flex-wrap: wrap;
  }

  .dashboard-scenario-status {
    flex: 1 1 100%;
    max-width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  .dashboard-scenario-toggle {
    transition: none;
  }
}

.project-iframe {
  width: 100%;
  height: 100%;
  flex: 1 1 auto;
  min-height: 0;
  border: none;
  display: block;
}

/* Iframe mode — hide builtin nav/filters, iframe navbar takes over */
body.iframe-mode .nav:not(.nav--iframe),
body.iframe-mode .sub-navbar,
body.iframe-mode .seg-bar,
body.iframe-mode .filter-bar,
body.iframe-mode .tag-filter-bar {
  display: none !important;
}
body.iframe-mode .main-wrapper {
  height: calc(100vh - 56px); /* only nav--iframe height (56px) */
}
body.iframe-mode .dashboard-content {
  height: 100%;
  min-height: 0;
}

/* Natural inline dashboard mode keeps the application navbar but renders the
   uploaded document directly in the remaining viewport. Uploaded CSS is
   isolated separately with @scope in the server-compiled fragment. */
body.inline-dashboard-mode .sub-navbar,
body.inline-dashboard-mode .seg-bar,
body.inline-dashboard-mode .filter-bar,
body.inline-dashboard-mode .tag-filter-bar {
  display: none !important;
}
body.inline-dashboard-mode .main-wrapper {
  height: calc(100vh - 56px);
}
body.inline-dashboard-mode .dashboard-content {
  height: 100%;
  min-height: 0;
  overflow: hidden;
}

/* Iframe mode navbar — same styling as main nav */
.nav--iframe {
  display: flex;
}

/* ═══════════════════════════════════════
   ADMIN PAGES — complete design system
═══════════════════════════════════════ */
.admin-page {
  min-height: 100vh;
  background: #F0F3F7;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  display: flex;
}

/* ── Sidebar ────────────────────────────────────────── */
.admin-sidebar {
  width: 240px;
  min-height: 100vh;
  background: #FFFFFF;
  border-right: 1px solid #DDE3EC;
  display: flex;
  flex-direction: column;
  flex-shrink: 0;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.admin-sidebar-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 18px 20px;
  border-bottom: 1px solid #DDE3EC;
}

/* Wordmark two-tone colors — used in nav, login, admin sidebar */
.brand-market { color: #2457C5; }
.brand-maker  { color: #20232A; }

.mm-logo { height: 40px; width: auto; display: inline-block; }
.mm-logo-link { display: inline-flex; line-height: 0; text-decoration: none; }

.admin-sidebar-logo {
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.3px;
  display: inline-flex;
}

.admin-sidebar-nav {
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.admin-sidebar-section {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1px;
  color: #AAAAAA;
  text-transform: uppercase;
  padding: 16px 12px 6px;
}

.admin-sidebar-back {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #888888;
  font-size: 13px;
  text-decoration: none;
  padding: 9px 12px;
  border-radius: 8px;
  margin-bottom: 4px;
  transition: background 0.12s, color 0.12s;
}
.admin-sidebar-back:hover { background: #F4F6F9; color: #20232A; }

.admin-sidebar-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 12px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  color: #4A5568;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.12s, color 0.12s;
  border: none;
  background: none;
  width: 100%;
  text-align: left;
}

.admin-sidebar-item:hover {
  background: #F4F6F9;
  color: #20232A;
}

.admin-sidebar-item.active {
  background: #EBF5FB;
  color: #2457C5;
  font-weight: 600;
}

.admin-sidebar-item.active svg { color: #2457C5; }

.admin-sidebar-badge {
  margin-left: auto;
  font-size: 11px;
  font-weight: 600;
  padding: 1px 8px;
  border-radius: 9999px;
  background: #F4F6F9;
  color: #888888;
  font-family: 'Geist Mono', monospace;
}

.admin-sidebar-item.active .admin-sidebar-badge {
  background: rgba(46,117,182,0.12);
  color: #2457C5;
}

/* Sidebar footer */
.admin-sidebar-footer {
  margin-top: auto;
  padding: 14px 16px;
  border-top: 1px solid #DDE3EC;
  display: flex;
  align-items: center;
  gap: 10px;
}
.admin-sidebar-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(46,117,182,0.12);
  color: #2457C5;
  font-size: 12px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.5px;
}
.admin-sidebar-user-info { min-width: 0; }
.admin-sidebar-user-name {
  font-size: 13px;
  font-weight: 600;
  color: #20232A;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.admin-sidebar-user-email {
  font-size: 11px;
  color: #888888;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Main content area ──────────────────────────────── */
.admin-main {
  flex: 1;
  min-width: 0;
  overflow-y: auto;
  height: 100vh;
}

.admin-main-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 32px;
}

.admin-content {
  padding: 0 32px 32px;
}

.configuration-tabs {
  display: flex;
  gap: 6px;
  margin-bottom: 16px;
  border-bottom: 1px solid #DDE3EC;
}

.configuration-tab {
  color: #6B7280;
  font-size: 13px;
  font-weight: 650;
  padding: 10px 14px;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
}

.configuration-tab:hover,
.configuration-tab:focus-visible { color: #2457C5; }
.configuration-tab:focus-visible { outline: 2px solid #2457C5; outline-offset: 2px; }
.configuration-tab.active { color: #2457C5; border-bottom-color: #2457C5; }

.feature-section-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

.feature-section-copy { margin: 5px 0 0; color: #6B7280; font-size: 13px; }
.feature-private-badge {
  flex-shrink: 0;
  border: 1px solid #D9E3F5;
  border-radius: 999px;
  background: #F4F7FD;
  color: #2457C5;
  padding: 5px 9px;
  font-size: 11px;
  font-weight: 700;
}

.feature-list { display: grid; gap: 12px; margin-top: 20px; }
.feature-card {
  overflow: hidden;
  border: 1px solid #DDE3EC;
  border-radius: 10px;
  background: #FFFFFF;
}
.feature-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 18px;
}
.feature-copy h3 { margin: 0; color: #20232A; font-size: 15px; }
.feature-copy p { max-width: 650px; margin: 5px 0 0; color: #6B7280; font-size: 13px; line-height: 1.5; }
.feature-switch {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #D1D5DB;
  border-radius: 999px;
  background: #FFFFFF;
  color: #6B7280;
  padding: 5px 9px 5px 6px;
  cursor: pointer;
  font: inherit;
}
.feature-switch:hover { border-color: #9CA3AF; }
.feature-switch:focus-visible { outline: 3px solid rgba(36, 87, 197, .25); outline-offset: 2px; }
.feature-switch-track { width: 34px; height: 20px; border-radius: 999px; background: #9CA3AF; padding: 2px; transition: background .15s; }
.feature-switch-thumb { display: block; width: 16px; height: 16px; border-radius: 50%; background: #FFFFFF; box-shadow: 0 1px 2px rgba(0,0,0,.25); transition: transform .15s; }
.feature-switch.enabled { color: #0F7A39; border-color: #B6DEC6; background: #F3FBF6; }
.feature-switch.enabled .feature-switch-track { background: #168447; }
.feature-switch.enabled .feature-switch-thumb { transform: translateX(14px); }
.feature-switch-state { min-width: 24px; font-size: 11px; font-weight: 800; letter-spacing: .04em; }
.ai-runtime-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
  padding: 18px;
  border: 1px solid #E5EAF1;
  border-radius: 10px;
  background: #F8FAFD;
}
.ai-runtime-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}
.ai-runtime-heading h4 { margin: 0; color: #20232A; font-size: 14px; }
.ai-runtime-heading p { margin: 4px 0 0; color: #6B7280; font-size: 12px; line-height: 1.5; }
.ai-runtime-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 11px;
  font-weight: 750;
}
.ai-runtime-status.ready { border: 1px solid #B6DEC6; background: #F3FBF6; color: #0F7A39; }
.ai-runtime-status.incomplete { border: 1px solid #F0D3A8; background: #FFF8EA; color: #9A5B0A; }
.ai-runtime-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.ai-tier-list { display: grid; gap: 10px; }
.ai-tier-row {
  display: grid;
  grid-template-columns: minmax(220px, .72fr) minmax(420px, 1.28fr);
  align-items: center;
  gap: 22px;
  border: 1px solid #DDE3EC;
  border-radius: 9px;
  background: #FFFFFF;
  padding: 14px;
}
.ai-tier-copy { display: flex; align-items: center; gap: 11px; min-width: 0; }
.ai-tier-label {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  justify-content: center;
  min-width: 57px;
  border: 1px solid #C9D8F2;
  border-radius: 999px;
  background: #F4F7FD;
  color: #2457C5;
  padding: 5px 8px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: .03em;
}
.ai-tier-label.balanced { border-color: #D8DEE8; background: #F7F8FA; color: #4B5563; }
.ai-tier-copy h3 { margin: 0; color: #20232A; font-size: 13px; }
.ai-tier-copy p { margin: 3px 0 0; color: #7A8494; font-size: 11px; line-height: 1.4; }
.ai-tier-controls { display: grid; grid-template-columns: minmax(180px, .8fr) minmax(220px, 1.2fr); gap: 10px; }
.ai-runtime-field { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.ai-runtime-field > span { color: #374151; font-size: 12px; font-weight: 700; }
.ai-runtime-field input,
.ai-runtime-field select {
  width: 100%;
  min-width: 0;
  border: 1px solid #CDD5E1;
  border-radius: 7px;
  background: #FFFFFF;
  color: #20232A;
  padding: 9px 10px;
  font: inherit;
  font-size: 13px;
}
.ai-runtime-field input:focus,
.ai-runtime-field select:focus { border-color: #2457C5; outline: 3px solid rgba(36, 87, 197, .14); }
.ai-runtime-field small { color: #7A8494; font-size: 11px; line-height: 1.4; }
.ai-runtime-error {
  margin: 0;
  border: 1px solid #F0D3A8;
  border-radius: 7px;
  background: #FFF8EA;
  color: #8B5209;
  padding: 9px 11px;
  font-size: 12px;
}
.ai-runtime-clear { display: flex; align-items: flex-start; gap: 8px; color: #6B4B21; font-size: 11px; line-height: 1.45; }
.ai-runtime-clear input { margin-top: 2px; }
.ai-runtime-clear-list { display: grid; gap: 7px; margin-top: 13px; }
.ai-runtime-credentials { border-top: 1px solid #E5EAF1; padding-top: 2px; }
.ai-runtime-credentials summary {
  width: fit-content;
  color: #526077;
  cursor: pointer;
  font-size: 12px;
  font-weight: 700;
  padding: 8px 0;
}
.ai-runtime-credentials summary:focus-visible { outline: 2px solid #2457C5; outline-offset: 2px; }
.ai-runtime-credentials > p { margin: 0 0 12px; color: #7A8494; font-size: 11px; }
.ai-runtime-save { width: auto; align-self: flex-start; padding: 9px 17px; }
.ai-runtime-notice {
  border: 1px solid #C9D8F2;
  border-radius: 7px;
  background: #F4F7FD;
  color: #43516A;
  padding: 10px 12px;
  font-size: 12px;
  line-height: 1.5;
}
.codex-connect {
  overflow: hidden;
  border: 1px solid #C9D8F2;
  border-radius: 9px;
  background: #FFFFFF;
}
.codex-connect-main { display: flex; align-items: center; gap: 13px; padding: 14px; }
.codex-connect-icon {
  display: grid;
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  place-items: center;
  border-radius: 9px;
  background: #111827;
  color: #FFFFFF;
  font-size: 15px;
  font-weight: 800;
}
.codex-connect-copy { flex: 1 1 auto; min-width: 0; }
.codex-connect-title-row { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.codex-connect-title-row h3 { margin: 0; color: #20232A; font-size: 14px; }
.codex-connect-copy > p { margin: 4px 0 0; color: #657085; font-size: 12px; line-height: 1.45; }
.codex-connect-state {
  border: 1px solid #D8DEE8;
  border-radius: 999px;
  background: #F7F8FA;
  color: #647084;
  padding: 3px 7px;
  font-size: 10px;
  font-weight: 750;
}
.codex-connect-state.connected { border-color: #B6DEC6; background: #F3FBF6; color: #0F7A39; }
.codex-connect-state.disconnected { border-color: #D9E3F5; background: #F4F7FD; color: #2457C5; }
.codex-connect-state.unavailable { border-color: #F0D3A8; background: #FFF8EA; color: #8B5209; }
.codex-connect-button { flex: 0 0 auto; padding: 8px 13px; }
.codex-connect-button:disabled { cursor: not-allowed; opacity: .55; }
.codex-callback { border-top: 1px solid #E5EAF1; background: #F8FAFD; padding: 14px; }
.codex-callback[hidden] { display: none; }
.codex-callback strong { color: #20232A; font-size: 12px; }
.codex-callback p { margin: 3px 0 11px; color: #657085; font-size: 11px; line-height: 1.45; }
.codex-callback-controls { display: flex; align-items: flex-end; gap: 9px; }
.codex-callback-field { flex: 1 1 auto; }
.codex-callback-controls .btn-primary { flex: 0 0 auto; min-height: 37px; }
.codex-connect-feedback { min-height: 0; margin: 0; padding: 0 14px; color: #2457C5; font-size: 11px; line-height: 1.4; }
.codex-connect-feedback:not(:empty) { padding-bottom: 10px; }
.codex-connect-feedback.error { color: #B42318; }
.codex-connect-risk { margin: 0; border-top: 1px solid #EEF1F5; background: #FBFCFD; color: #7A8494; padding: 8px 14px; font-size: 10px; line-height: 1.45; }

@media (max-width: 700px) {
  .admin-page { display: block; }
  .admin-sidebar {
    position: static;
    width: 100%;
    height: auto;
    min-height: 0;
    overflow: visible;
    border-right: 0;
    border-bottom: 1px solid #DDE3EC;
  }
  .admin-sidebar-header { padding: 14px 16px; }
  .admin-sidebar-nav {
    flex-direction: row;
    gap: 6px;
    overflow-x: auto;
    padding: 8px 12px;
    scrollbar-width: none;
  }
  .admin-sidebar-nav::-webkit-scrollbar { display: none; }
  .admin-sidebar-section,
  .admin-sidebar-back,
  .admin-sidebar-footer { display: none; }
  .admin-sidebar-item {
    flex: 0 0 auto;
    width: auto;
    white-space: nowrap;
  }
  .admin-sidebar-badge { margin-left: 2px; }
  .admin-main {
    height: auto;
    min-height: calc(100vh - 112px);
    overflow: visible;
  }
  .admin-main-header { padding: 18px 16px 12px; }
  .admin-content { padding: 0 16px 24px; }
  .feature-row { align-items: flex-start; flex-direction: column; gap: 14px; }
  .feature-section-heading { flex-direction: column; }
  .ai-runtime-grid { grid-template-columns: 1fr; }
  .ai-runtime-heading { flex-direction: column; }
  .ai-tier-row { grid-template-columns: 1fr; gap: 12px; }
  .ai-tier-controls { grid-template-columns: 1fr; }
  .codex-connect-main { align-items: flex-start; flex-wrap: wrap; }
  .codex-connect-button { margin-left: 47px; }
  .codex-callback-controls { align-items: stretch; flex-direction: column; }
  .codex-callback-controls .btn-primary { align-self: flex-start; }
}

.telemetry-header { gap: 20px; }
.telemetry-eyebrow { margin: 0 0 4px; color: #2457C5; font-size: 11px; font-weight: 800; letter-spacing: .11em; text-transform: uppercase; }
.telemetry-ranges { display: inline-flex; border: 1px solid #DDE3EC; border-radius: 9px; background: #FFFFFF; padding: 3px; }
.telemetry-range { color: #6B7280; border-radius: 6px; padding: 7px 10px; font-size: 12px; font-weight: 700; text-decoration: none; }
.telemetry-range:hover, .telemetry-range:focus-visible { color: #2457C5; }
.telemetry-range:focus-visible { outline: 2px solid #2457C5; outline-offset: 1px; }
.telemetry-range.active { background: #2457C5; color: #FFFFFF; }
.telemetry-content { display: grid; gap: 18px; }
.telemetry-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.telemetry-kpi { display: flex; flex-direction: column; min-height: 126px; padding: 18px; border: 1px solid #DDE3EC; border-radius: 10px; background: #FFFFFF; }
.telemetry-kpi span { color: #6B7280; font-size: 12px; font-weight: 650; }
.telemetry-kpi strong { margin-top: 12px; color: #20232A; font-family: 'Geist Mono', monospace; font-size: 28px; line-height: 1; }
.telemetry-kpi small { margin-top: auto; color: #9CA3AF; font-size: 11px; }
.telemetry-kpi-primary { border-color: #B8CCF1; background: #F7F9FE; }
.telemetry-kpi-primary strong { color: #2457C5; }
.telemetry-panel, .telemetry-empty { border: 1px solid #DDE3EC; border-radius: 10px; background: #FFFFFF; padding: 20px; }
.telemetry-empty h2, .telemetry-panel-heading h2 { margin: 0; color: #20232A; font-size: 15px; }
.telemetry-empty p, .telemetry-panel-heading p { margin: 4px 0 0; color: #6B7280; font-size: 12px; }
.telemetry-panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; }
.telemetry-legend { display: flex; gap: 12px; color: #6B7280; font-size: 11px; }
.telemetry-legend span { display: inline-flex; align-items: center; gap: 5px; }
.telemetry-legend i { width: 7px; height: 7px; border-radius: 50%; background: #2457C5; }
.telemetry-legend i.chat { background: #75A7E8; }
.telemetry-trend { display: flex; align-items: flex-end; gap: 4px; height: 190px; overflow-x: auto; padding: 8px 2px 0; }
.telemetry-day { display: grid; grid-template-rows: 18px 130px 18px; align-items: end; justify-items: center; min-width: 28px; flex: 1; }
.telemetry-day-value, .telemetry-day span { color: #9CA3AF; font-size: 9px; }
.telemetry-day-bars { display: flex; align-items: flex-end; gap: 3px; height: 120px; }
.telemetry-day-track { width: 8px; height: 120px; border-radius: 4px; background: #F0F3F7; overflow: hidden; display: flex; align-items: flex-end; }
.telemetry-day-bar { width: 100%; min-height: 2px; border-radius: 4px; background: #2457C5; }
.telemetry-day-bar.chat { background: #75A7E8; }
.telemetry-table-wrap { overflow-x: auto; }
.telemetry-table-wrap table { width: 100%; border-collapse: collapse; font-size: 12px; }
.telemetry-table-wrap th { padding: 10px 12px; border-bottom: 1px solid #DDE3EC; color: #6B7280; font-size: 10px; letter-spacing: .05em; text-align: right; text-transform: uppercase; white-space: nowrap; }
.telemetry-table-wrap th:first-child, .telemetry-table-wrap td:first-child { text-align: left; }
.telemetry-table-wrap td { padding: 12px; border-bottom: 1px solid #EEF1F5; color: #374151; font-family: 'Geist Mono', monospace; text-align: right; }
.telemetry-table-wrap tbody tr:last-child td { border-bottom: 0; }
.telemetry-table-empty { color: #9CA3AF !important; font-family: 'Inter', sans-serif !important; text-align: center !important; }
.telemetry-daily-table { margin-top: 18px; }
.sr-only { position: absolute !important; width: 1px !important; height: 1px !important; padding: 0 !important; margin: -1px !important; overflow: hidden !important; clip: rect(0, 0, 0, 0) !important; white-space: nowrap !important; border: 0 !important; }

@media (max-width: 980px) {
  .telemetry-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 700px) {
  .telemetry-header { align-items: flex-start; flex-direction: column; }
  .telemetry-kpis { grid-template-columns: 1fr; }
  .telemetry-ranges { width: 100%; }
  .telemetry-range { flex: 1; text-align: center; }
  .telemetry-panel-heading { flex-direction: column; }
}

.admin-title {
  font-size: 24px;
  font-weight: 800;
  color: #20232A;
  margin: 0;
  line-height: 1.2;
}

.admin-subtitle {
  font-size: 14px;
  color: #888888;
  margin: 2px 0 0;
}

/* New project button (header) */
.admin-new-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #2457C5;
  color: #FFFFFF;
  border: none;
  border-radius: 10px;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  text-decoration: none;
  box-shadow: 0 2px 8px rgba(46,117,182,0.25);
  transition: background 0.15s;
  white-space: nowrap;
  flex-shrink: 0;
}
.admin-new-btn:hover { background: #2457C5; }

/* Legacy compat — keep admin-body for setup page */
.admin-body {
  max-width: 800px;
  margin: 32px auto;
  padding: 0 24px;
}

.admin-section {
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 16px;
  padding: 24px;
  margin-bottom: 20px;
}

.admin-section-title {
  font-size: 15px;
  font-weight: 600;
  color: #20232A;
  margin: 0 0 16px 0;
}

/* ── Stats bar ──────────────────────────────────────── */
.admin-stats-bar {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
}
.admin-stat-box {
  flex: 1;
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 12px;
  padding: 16px 20px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.admin-stat-val {
  font-size: 28px;
  font-weight: 800;
  color: #20232A;
  font-family: 'Geist Mono', 'Courier New', monospace;
  line-height: 1;
  display: flex;
  align-items: baseline;
  gap: 4px;
}
.admin-stat-frac {
  font-size: 14px;
  font-weight: 500;
  color: #AAB3C2;
  font-family: 'Geist Mono', 'Courier New', monospace;
}
.admin-stat-lbl {
  font-size: 12px;
  color: #888888;
  font-weight: 500;
}

/* ── Project cards ──────────────────────────────────── */
.admin-project-card-v2 {
  display: flex;
  align-items: stretch;
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  overflow: hidden;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.admin-project-card-v2:hover {
  border-color: #C5DFFF;
  box-shadow: 0 4px 16px rgba(46,117,182,0.09);
}

.admin-project-card-top {
  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 20px 24px;
  flex: 1;
}

.admin-project-avatar {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  font-size: 20px;
  font-weight: 800;
  color: #FFFFFF;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: -1px;
}

.admin-project-body { flex: 1; min-width: 0; }

.admin-project-title-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 4px;
}
.admin-project-name-v2 {
  font-size: 15px;
  font-weight: 700;
  color: #20232A;
}
.admin-badge-active {
  font-size: 11px;
  font-weight: 600;
  background: rgba(34,197,94,0.063);
  color: #166534;
  border: 1px solid rgba(34,197,94,0.25);
  padding: 2px 8px;
  border-radius: 9999px;
}
.admin-badge-default-v2 {
  font-size: 11px;
  font-weight: 600;
  background: rgba(46,117,182,0.125);
  color: #2457C5;
  border: 1px solid rgba(46,117,182,0.25);
  padding: 2px 8px;
  border-radius: 9999px;
}
.admin-project-desc-v2 {
  font-size: 13px;
  color: #888888;
  margin-top: 4px;
}
.admin-project-meta-row {
  margin-top: 10px;
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  align-items: center;
}
.admin-meta-tag {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  background: #F4F6F9;
  border: 1px solid #DDE3EC;
  border-radius: 9999px;
  padding: 3px 10px;
  font-size: 12px;
  color: #666666;
}
.admin-meta-tag svg { color: #AAAAAA; flex-shrink: 0; }
.admin-meta-on  {
  background: #EBF5FB;
  border-color: #C5DFFF;
  color: #2457C5;
  font-weight: 600;
}
.admin-meta-off { color: #AAAAAA; }

/* Actions column on project card */
.admin-project-actions {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
  justify-content: center;
  padding: 20px 24px 20px 0;
  flex-shrink: 0;
}

.admin-open-btn {
  display: inline-block;
  padding: 8px 16px;
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 8px;
  color: #20232A;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.15s, border-color 0.15s;
  white-space: nowrap;
}
.admin-open-btn:hover {
  background: #F4F6F9;
  border-color: #C5DFFF;
}

.admin-delete-btn {
  display: inline-block;
  padding: 5px 10px;
  background: transparent;
  border: 1px solid #FCA5A5;
  border-radius: 6px;
  color: #B91C1C;
  font-size: 11px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
  font-family: 'Inter', sans-serif;
}
.admin-delete-btn:hover { background: #FEF2F2; }

/* Create new project card */
.admin-new-project-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px 24px;
  background: #FFFFFF;
  border: 2px dashed #DDE3EC;
  border-radius: 16px;
  color: #888888;
  cursor: pointer;
  text-decoration: none;
  transition: border-color 0.15s, background 0.15s;
}
.admin-new-project-card:hover {
  border-color: #2457C5;
  background: #F0F6FF;
  color: #2457C5;
}
.admin-new-project-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: #F4F6F9;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: #AAAAAA;
  font-size: 22px;
  line-height: 1;
}
.admin-new-project-title {
  font-size: 15px;
  font-weight: 600;
  color: #20232A;
}
.admin-new-project-sub {
  font-size: 13px;
  color: #888888;
  margin-top: 2px;
}

/* Form utilities */
.admin-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.admin-radio-group {
  display: flex;
  gap: 20px;
}

.admin-radio {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #333;
  cursor: pointer;
}

.form-hint {
  font-size: 11px;
  color: #999;
  margin-top: 3px;
}

/* ── Members table ──────────────────────────────────── */
.admin-member-table-wrap {
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 16px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.04);
  overflow: hidden;
  margin-bottom: 24px;
}

.admin-member-table {
  width: 100%;
  border-collapse: collapse;
}
.admin-member-table th {
  font-size: 10px;
  font-weight: 700;
  color: #AAAAAA;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 12px 20px;
  text-align: left;
  background: #F8FAFC;
  border-bottom: 1px solid #EEF1F5;
}
.admin-member-table td {
  padding: 14px 20px;
  border-bottom: 1px solid #F0F3F7;
  vertical-align: middle;
  font-size: 13px;
  color: #4A5568;
}
.admin-member-table tr:last-child td { border-bottom: none; }
.admin-member-table tr.inactive-row { opacity: 0.55; }

.admin-member-cell {
  display: flex;
  align-items: center;
  gap: 12px;
}
.admin-avatar {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  letter-spacing: 0.5px;
}
.admin-member-name-v2 {
  font-size: 14px;
  font-weight: 600;
  color: #20232A;
  line-height: 1.2;
}
.admin-member-email-v2 {
  font-size: 12px;
  color: #888888;
  margin-top: 2px;
}

/* Role badges */
.admin-role-admin {
  display: inline-block;
  font-size: 11px;
  font-weight: 600;
  background: rgba(26,58,92,0.125);
  color: #20232A;
  border: 1px solid rgba(26,58,92,0.19);
  padding: 3px 10px;
  border-radius: 9999px;
}
.admin-role-member {
  font-size: 11px;
  color: #4A5568;
}

/* Auth badges */
.admin-auth-google {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 11px;
  font-weight: 600;
  background: rgba(66,133,244,0.125);
  color: #2457C5;
  border: 1px solid rgba(66,133,244,0.25);
  padding: 3px 10px;
  border-radius: 9999px;
}
.admin-auth-email {
  font-size: 12px;
  color: #555555;
}

/* Status indicators */
.admin-status-active {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
  color: #16A34A;
}
.admin-status-inactive {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 13px;
  font-weight: 500;
  color: #9CA3AF;
}

/* Actions cell */
.admin-actions-cell {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: flex-end;
}

/* Action buttons */
.admin-action-btn {
  padding: 5px 12px;
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 6px;
  font-size: 12px;
  color: #4A5568;
  cursor: pointer;
  transition: background 0.15s;
  white-space: nowrap;
  font-family: 'Inter', sans-serif;
}
.admin-action-btn:hover { background: #F4F6F9; }

.admin-action-btn--danger {
  border-color: #FCA5A5;
  color: #B91C1C;
}
.admin-action-btn--danger:hover { background: #FEF2F2; }

.admin-action-btn--success {
  border-color: #86EFAC;
  color: #166534;
}
.admin-action-btn--success:hover { background: #F0FDF4; }

/* Members — legacy card variants kept for compat */
.admin-member-list { display: flex; flex-direction: column; gap: 10px; }
.admin-member-card {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; padding: 14px 16px; background: #f8fafd;
  border: 1px solid #e8edf5; border-radius: 8px;
}
.admin-member-card--inactive { opacity: 0.6; background: #f5f5f5; }
.admin-member-name { font-size: 14px; font-weight: 600; color: #20232A; display: flex; align-items: center; gap: 6px; margin-bottom: 3px; }
.admin-member-email { font-size: 12px; color: #888; }
.admin-badge--inactive { background: #6b7280; }
.admin-badge--google { background: #2457C5; }
.admin-member-actions { display: flex; gap: 8px; flex-shrink: 0; }
.admin-badge { font-size: 10px; font-weight: 500; background: #2457C5; color: #fff; padding: 2px 7px; border-radius: 10px; }

/* ── File download card ─────────────────────────── */
.chat-file-download { padding: 8px 16px; }
.file-download-link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 16px;
  background: #f9f8f5;
  border: 1px solid #e5e3db;
  border-radius: 10px;
  text-decoration: none;
  color: #1a1917;
  transition: border-color 0.2s, background 0.2s;
}
.file-download-link:hover {
  border-color: #2457C5;
  background: #eff6ff;
}
.file-icon { font-size: 20px; }
.file-name { flex: 1; font-size: 13px; font-weight: 500; }
.file-action {
  font-size: 12px;
  color: #2457C5;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}

/* ── Info note (members page) ───────────────────────── */
.admin-info-note {
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 10px;
  padding: 16px 20px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: #666666;
  line-height: 1.5;
}
.admin-info-note svg { flex-shrink: 0; margin-top: 1px; color: #2457C5; }

/* ── Search box ─────────────────────────────────────── */
.admin-search-box {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 9px 14px;
  background: #FFFFFF;
  border: 1px solid #DDE3EC;
  border-radius: 10px;
  color: #AAAAAA;
  width: 260px;
  height: 36px;
  box-sizing: border-box;
}
.admin-search-box input {
  border: none;
  outline: none;
  font-size: 13px;
  color: #20232A;
  background: transparent;
  flex: 1;
  min-width: 0;
  font-family: 'Inter', sans-serif;
}
.admin-search-box input::placeholder { color: #AAAAAA; }

/* ── Chart export buttons ─────────────────────────── */
.chart-export-buttons {
  display: flex;
  gap: 6px;
  padding: 6px 0 0;
  flex-wrap: wrap;
}
.chart-export-btn {
  font-size: 11px;
  padding: 3px 8px;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  background: #fff;
  color: #374151;
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}
.chart-export-btn:hover {
  border-color: #2457C5;
  color: #2457C5;
}

/* ═══════════════════════════════════════
   Upload progress overlay
   Attached body-level by static/admin-upload-progress.js so it sits above
   admin-page layouts without leaking into them. data-phase drives state.
═══════════════════════════════════════ */
.upload-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 20, 22, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}
.upload-overlay[hidden] { display: none; }
.upload-overlay__panel {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
  padding: 28px 32px;
  min-width: 360px;
  max-width: 480px;
  text-align: center;
}
.upload-overlay__spinner {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 3px solid #e5e7eb;
  border-top-color: #2457C5;
  animation: upload-overlay-spin 0.9s linear infinite;
  margin: 0 auto 16px;
}
.upload-overlay[data-phase="error"] .upload-overlay__spinner { display: none; }
.upload-overlay[data-phase="done"] .upload-overlay__spinner { border-top-color: #237A57; }
.upload-overlay__title {
  font-size: 15px;
  font-weight: 500;
  color: #20232A;
  margin-bottom: 12px;
  line-height: 1.4;
  word-wrap: break-word;
}
.upload-overlay[data-phase="error"] .upload-overlay__title { color: #B94747; }
.upload-overlay__bar-track {
  height: 6px;
  background: #e5e7eb;
  border-radius: 3px;
  overflow: hidden;
  margin: 12px 0 4px;
}
.upload-overlay__bar-fill {
  height: 100%;
  width: 0%;
  background: #2457C5;
  transition: width 0.2s ease;
}
.upload-overlay__dismiss {
  margin-top: 12px;
  padding: 8px 20px;
  background: #f3f4f6;
  border: 1px solid #d9dee6;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
  color: #20232A;
}
.upload-overlay__dismiss:hover { background: #e5e7eb; }
@keyframes upload-overlay-spin { to { transform: rotate(360deg); } }
}

/* Host contract for uploaded dashboards. These rules intentionally sit
   outside the portal scope and are the only shell styles allowed inside it. */
.project-inline-dashboard {
  box-sizing: border-box !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  overflow: hidden !important;
  position: relative !important;
  transform: translateZ(0) !important;
}
.project-inline-dashboard-scrollport {
  box-sizing: border-box !important;
  width: 100% !important;
  height: 100% !important;
  min-height: 0 !important;
  overflow: auto !important;
  position: relative !important;
}

.project-inline-dashboard-warning {
  margin: 10px;
  padding: 10px 12px;
  border: 1px solid #e7b455;
  border-radius: 8px;
  background: #fff9e8;
  color: #664800;
  font-size: 12px;
}

.project-inline-dashboard-warning ul {
  margin: 4px 0 0 18px;
  padding: 0;
}
.project-inline-dashboard:focus-visible {
  outline: 2px solid var(--brand-primary, #2e75b6);
  outline-offset: -2px;
}
.project-inline-dashboard--error {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  overflow: auto !important;
  background: #f7f9fb;
}
.project-inline-dashboard-error-card {
  max-width: 620px;
  padding: 28px;
  border: 1px solid #dde3ec;
  border-radius: 10px;
  background: #fff;
  color: #26323d;
  font-family: Inter, sans-serif;
}
.project-inline-dashboard-error-card h1 {
  margin: 0 0 12px;
  font-size: 20px;
}
.project-inline-dashboard-error-reason {
  padding: 10px 12px;
  border-radius: 6px;
  background: #f2f4f7;
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 12px;
}
