/* ==========================================================================
   WIRED.DEV — DASHBOARD & AI ASSISTANT STYLES
   Exact replica of modern n8n / Avi AI Tools Cloud Assistant Dashboard
   ========================================================================== */

/* Scale the whole page so 100% browser zoom matches the configured 80% view.
   Compensate with 125% min-height so content fills physical viewport without bottom gap. */
html {
  zoom: 0.8;
  min-height: 125%;
  height: 125%;
  background-color: #06070a;
  color-scheme: dark;
}

body {
  margin: 0;
  padding: 0;
  min-height: 125vh;
  height: 125vh;
  background-color: #06070a;
  color: #f8fafc;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  -webkit-font-smoothing: antialiased;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

/* Base resets */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

a {
  text-decoration: none;
  color: inherit;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
  background: none;
  color: inherit;
}

/* ==========================================================================
   1. TOPMOST STATUS BANNER (14 days left • 0/1000 Executions • Upgrade Now)
   ========================================================================== */
.dash-trial-bar {
  height: 38px;
  background: #080a0f;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  font-size: 12px;
  color: #94a3b8;
  flex-shrink: 0;
  z-index: 50;
}

.dash-trial-left {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-trial-countdown {
  display: flex;
  align-items: center;
  gap: 6px;
  color: #cbd5e1;
  font-weight: 500;
}

.dash-trial-countdown svg {
  width: 14px;
  height: 14px;
  color: #94a3b8;
}

.dash-trial-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #64748b;
}

.dash-trial-usage {
  color: #64748b;
  font-weight: 500;
  letter-spacing: 0.2px;
}

.dash-btn-upgrade {
  background: #10b981;
  color: #ffffff;
  font-size: 12px;
  font-weight: 700;
  padding: 5px 12px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.2s ease;
  box-shadow: 0 2px 8px rgba(16, 185, 129, 0.25);
}

.dash-btn-upgrade:hover {
  background: #059669;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.4);
  transform: translateY(-1px);
}

.dash-btn-upgrade svg {
  width: 13px;
  height: 13px;
}

/* ==========================================================================
   2. MAIN APPLICATION HEADER
   ========================================================================== */
.dash-header {
  height: 48px;
  background: #06070a;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0;
  flex-shrink: 0;
  z-index: 40;
}

/* Sidebar Top Brand Header */
.dash-header-brand {
  width: 210px;
  height: 100%;
  background: #090b10;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  align-items: center;
  padding: 0 10px 0 14px;
  gap: 8px;
  flex-shrink: 0;
  transition: width 0.25s cubic-bezier(0.16, 1, 0.3, 1), padding 0.25s ease;
}

.dash-header-brand.collapsed {
  width: auto;
}

/* The bar from chat history all the way to the end on the right side */
.dash-header-workspace {
  flex: 1;
  height: 100%;
  background: #06070a; /* Exact color of "What do you want to automate?" section */
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
}

/* Logo */
.dash-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  padding-right: 10px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-logo-icon {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  background: linear-gradient(135deg, #ff5722 0%, #ff8f00 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 10px rgba(255, 87, 34, 0.4);
}

.dash-logo-icon svg {
  width: 14px;
  height: 14px;
  fill: #ffffff;
}

.dash-logo-text {
  font-size: 15px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.3px;
}

/* Icon Buttons Group (+, 🔍, [|]) */
.dash-header-controls {
  display: flex;
  align-items: center;
  gap: 4px;
}

.dash-icon-btn {
  width: 30px;
  height: 30px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  transition: all 0.16s ease;
}

.dash-icon-btn:hover {
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.06);
}

.dash-icon-btn svg {
  width: 15px;
  height: 15px;
}

/* Chat history trigger button */
.dash-history-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #f8fafc;
  font-size: 13px;
  font-weight: 500;
  padding: 5px 10px;
  border-radius: 6px;
  transition: all 0.16s ease;
  margin-left: 0;
}

.dash-history-btn:hover {
  background: rgba(255, 255, 255, 0.06);
}

.dash-history-btn svg {
  width: 15px;
  height: 15px;
  color: #94a3b8;
}

/* Header Right (Avatar) */
.dash-header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-avatar-btn {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: #1e2433;
  border: 1px solid rgba(255, 255, 255, 0.15);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 700;
  color: #f8fafc;
  transition: all 0.2s ease;
}

.dash-avatar-btn:hover {
  border-color: #ff5722;
  box-shadow: 0 0 10px rgba(255, 87, 34, 0.3);
}

/* ==========================================================================
   3. APP BODY (Split: Sidebar + Main Content Canvas)
   ========================================================================== */
.dash-body {
  flex: 1;
  display: flex;
  overflow: hidden;
  position: relative;
}

/* ==========================================================================
   4. LEFT SIDEBAR
   ========================================================================== */
.dash-sidebar {
  width: 210px;
  background: #090b10;
  border-right: 1px solid rgba(255, 255, 255, 0.06);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 14px 10px;
  flex-shrink: 0;
  transition: width 0.25s cubic-bezier(0.16, 1, 0.3, 1), margin-left 0.25s ease;
  z-index: 30;
}

.dash-sidebar.collapsed {
  width: 0;
  padding: 0;
  margin-left: -1px;
  overflow: hidden;
  border-right: none;
}

.dash-sidebar-top,
.dash-sidebar-bottom {
  display: flex;
  flex-direction: column;
  gap: 3px;
}

.dash-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 12px;
  border-radius: 7px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 500;
  transition: all 0.16s ease;
  user-select: none;
  cursor: pointer;
  position: relative;
}

.dash-nav-item:hover {
  color: #f8fafc;
  background: rgba(255, 255, 255, 0.05);
}

.dash-nav-item.active {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  font-weight: 600;
}

.dash-nav-item svg {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
}

/* Purple preview badge next to Assistant */
.dash-preview-badge {
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  background: rgba(168, 85, 247, 0.18);
  border: 1px solid rgba(168, 85, 247, 0.35);
  color: #c084fc;
  letter-spacing: 0.3px;
  margin-left: auto;
}

.dash-nav-chevron {
  width: 12px;
  height: 12px;
  margin-left: auto;
  opacity: 0.5;
}

/* ==========================================================================
   5. MAIN WORKSPACE CANVAS
   ========================================================================== */
.dash-main {
  flex: 1;
  background: #06070a;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 0;
}

/* Assistant Starter Hub */
.dash-assistant-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 680px;
  margin: auto 0;
  text-align: center;
  animation: heroFadeIn 0.35s ease;
}

@keyframes heroFadeIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-hero-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 26px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin-bottom: 24px;
}

.dash-hero-title svg {
  width: 22px;
  height: 22px;
  color: #ff9800;
}

/* Centered Prompt Input Card */
.dash-input-card {
  width: 100%;
  background: #131622;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 16px 18px 12px;
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.6),
    0 0 30px rgba(255, 87, 34, 0.05);
  display: flex;
  flex-direction: column;
  transition: all 0.2s ease;
  margin-bottom: 16px;
  text-align: left;
}

.dash-input-card:focus-within {
  border-color: rgba(255, 87, 34, 0.5);
  box-shadow: 
    0 20px 50px rgba(0, 0, 0, 0.7),
    0 0 25px rgba(255, 87, 34, 0.2);
}

.dash-textarea {
  width: 100%;
  height: 64px;
  background: transparent;
  border: none;
  outline: none;
  color: #ffffff;
  font-family: inherit;
  font-size: 15px;
  font-weight: 400;
  resize: none;
  line-height: 1.5;
}

.dash-textarea::placeholder {
  color: #64748b;
}

.dash-input-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 10px;
}

.dash-input-actions-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.dash-tool-btn {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.16s ease;
}

.dash-tool-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.dash-tool-btn svg {
  width: 14px;
  height: 14px;
}

.dash-input-actions-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-mic-btn {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
  transition: all 0.16s ease;
}

.dash-mic-btn:hover {
  color: #ffffff;
}

.dash-mic-btn svg {
  width: 15px;
  height: 15px;
}

.dash-mic-btn.recording {
  color: #ef4444;
  animation: pulse 1.2s infinite;
}

@keyframes pulse {
  0% { transform: scale(1); }
  50% { transform: scale(1.15); }
  100% { transform: scale(1); }
}

/* Orange Up-Arrow Submit Button */
.dash-submit-btn {
  width: 32px;
  height: 32px;
  border-radius: 7px;
  background: #ff5722;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  box-shadow: 0 2px 10px rgba(255, 87, 34, 0.4);
}

.dash-submit-btn:hover {
  background: #f4511e;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px rgba(255, 87, 34, 0.55);
}

.dash-submit-btn svg {
  width: 16px;
  height: 16px;
  stroke-width: 2.5;
}

/* Suggestion Pills */
.dash-suggestions-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  justify-content: center;
}

.dash-suggestion-pill {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.09);
  padding: 7px 13px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 500;
  color: #cbd5e1;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: all 0.16s ease;
  cursor: pointer;
}

.dash-suggestion-pill:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 87, 34, 0.4);
  color: #ffffff;
  transform: translateY(-1px);
}

.dash-suggestion-pill svg {
  width: 13px;
  height: 13px;
  color: #94a3b8;
}

.dash-see-all-link {
  font-size: 12.5px;
  color: #94a3b8;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: 4px;
  transition: color 0.16s ease;
}

.dash-see-all-link:hover {
  color: #ff9800;
}

/* ==========================================================================
   6. ACTIVE CHAT CONVERSATION VIEW (When user starts a session)
   ========================================================================== */
.dash-conversation-view {
  display: none;
  width: 100%;
  max-width: 760px;
  margin: 0 auto;
  flex: 1;
  flex-direction: column;
  padding: 10px 0 20px;
  min-width: 0;
  overflow-x: hidden;
}

.dash-conversation-view.active {
  display: flex;
}

.dash-message-stream {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 22px;
  padding-bottom: 20px;
  min-width: 0;
  width: 100%;
}

.dash-msg {
  display: flex;
  gap: 12px;
  width: 100%;
  min-width: 0;
  animation: msgSlideIn 0.25s ease;
}

@keyframes msgSlideIn {
  from { opacity: 0; transform: translateY(6px); }
  to   { opacity: 1; transform: translateY(0); }
}

.dash-msg-user {
  justify-content: flex-end;
}

.dash-msg-bubble-user {
  background: #ff5722;
  color: #ffffff;
  padding: 12px 18px;
  border-radius: 14px 14px 2px 14px;
  font-size: 13.5px;
  line-height: 1.5;
  max-width: 78%;
  word-break: break-word;
  box-shadow: 0 4px 14px rgba(255, 87, 34, 0.25);
}

.dash-msg-avatar {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: linear-gradient(135deg, #ff5722 0%, #ff8f00 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 0 10px rgba(255, 87, 34, 0.35);
}

.dash-msg-avatar svg {
  width: 16px;
  height: 16px;
  fill: #ffffff;
}

.dash-msg-body-ai {
  flex: 1;
  min-width: 0;
}

/* Status / Stage indicator */
.dash-ai-waiting-badge {
  font-size: 12px;
  font-weight: 500;
  color: #94a3b8;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 8px;
}

.dash-waiting-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ff9800;
  box-shadow: 0 0 8px #ff9800;
  animation: waitingPulse 1.2s infinite alternate;
}

@keyframes waitingPulse {
  from { opacity: 0.4; }
  to   { opacity: 1; }
}

.dash-ai-pre-question {
  font-size: 14.5px;
  font-weight: 500;
  color: #f8fafc;
  line-height: 1.5;
  margin-bottom: 14px;
}

/* ── Interactive Questionnaire / Proposed Answers Card (n8n Style) ─────── */
.dash-question-card {
  background: #111420;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 12px;
  padding: 18px 20px;
  width: 100%;
  max-width: 640px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.4);
}

.dash-question-title {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 14px;
}

.dash-question-options {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.dash-q-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 9px 12px;
  border-radius: 8px;
  background: #161a29;
  border: 1px solid rgba(255, 255, 255, 0.06);
  cursor: pointer;
  color: #cbd5e1;
  font-size: 13.5px;
  transition: all 0.16s ease;
  user-select: none;
}

.dash-q-option:hover {
  background: #1e243a;
  border-color: rgba(255, 87, 34, 0.4);
  color: #ffffff;
}

.dash-q-option.selected {
  background: rgba(255, 87, 34, 0.12);
  border-color: #ff5722;
  color: #ffffff;
  box-shadow: 0 0 14px rgba(255, 87, 34, 0.15);
}

.dash-q-opt-left {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.dash-q-num {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background: rgba(255, 255, 255, 0.08);
  color: #94a3b8;
  font-size: 11px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: all 0.16s ease;
}

.dash-q-option.selected .dash-q-num {
  background: #ff5722;
  color: #ffffff;
}

.dash-q-label {
  font-size: 13.5px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.dash-q-arrow {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: transparent;
  display: flex;
  align-items: center;
  justify-content: center;
  color: transparent;
  flex-shrink: 0;
  transition: all 0.16s ease;
}

.dash-q-option:hover .dash-q-arrow,
.dash-q-option.selected .dash-q-arrow {
  background: #ff5722;
  color: #ffffff;
}

/* Custom write-in input inside option */
.dash-q-custom-wrap {
  display: flex;
  align-items: center;
  flex: 1;
  min-width: 0;
  gap: 8px;
}

.dash-q-custom-input {
  flex: 1;
  background: #090c14;
  border: 1px solid rgba(255, 87, 34, 0.4);
  border-radius: 6px;
  padding: 5px 10px;
  font-size: 13px;
  color: #ffffff;
  outline: none;
}

.dash-q-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 12px;
  margin-top: 14px;
  border-top: 1px solid rgba(255, 255, 255, 0.06);
}

.dash-q-steps {
  font-size: 11.5px;
  color: #64748b;
  font-weight: 500;
}

.dash-q-submit-btn {
  background: #181d2c;
  color: #64748b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 6px;
  padding: 6px 16px;
  font-size: 12.5px;
  font-weight: 600;
  cursor: not-allowed;
  transition: all 0.2s ease;
}

.dash-q-submit-btn.ready {
  background: #ff5722;
  color: #ffffff;
  border-color: #ff5722;
  cursor: pointer;
  box-shadow: 0 2px 10px rgba(255, 87, 34, 0.4);
}

.dash-q-submit-btn.ready:hover {
  background: #f4511e;
  transform: translateY(-1px);
}

/* Disclaimer text */
.dash-chat-disclaimer {
  font-size: 11px;
  color: #64748b;
  text-align: center;
  margin-top: 10px;
}

/* Workflow node builder preview card inside AI response */
.dash-workflow-preview {
  margin-top: 16px;
  background: #0a0d16;
  border: 1px solid rgba(255, 87, 34, 0.25);
  border-radius: 8px;
  padding: 14px;
}

.dash-workflow-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
  font-size: 13px;
  font-weight: 600;
  color: #f8fafc;
}

.dash-workflow-nodes {
  display: flex;
  align-items: center;
  gap: 12px;
  overflow-x: auto;
  padding: 6px 0;
}

.dash-node-box {
  background: #171b29;
  border: 1px solid rgba(255, 255, 255, 0.1);
  padding: 8px 12px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
}

.dash-node-arrow {
  color: #ff9800;
  font-weight: bold;
}

/* Chat Input Bar Pinned at Bottom of Conversation */
.dash-chat-input-container {
  width: 100%;
  max-width: 760px;
  margin: auto auto 0;
  min-width: 0;
}

/* ==========================================================================
   7. CHAT HISTORY SLIDE-OUT DRAWER
   ========================================================================== */
.dash-drawer-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  z-index: 90;
}

.dash-drawer-overlay.active {
  display: block;
}

.dash-history-drawer {
  position: fixed;
  top: 0;
  left: -320px;
  width: 300px;
  height: 100%;
  background: #0d0f17;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: 10px 0 40px rgba(0, 0, 0, 0.7);
  z-index: 100;
  transition: left 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.dash-history-drawer.active {
  left: 0;
}

.dash-drawer-header {
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-drawer-header h3 {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
  display: flex;
  align-items: center;
  gap: 8px;
}

.dash-drawer-close {
  color: #94a3b8;
  padding: 4px;
  border-radius: 4px;
}

.dash-drawer-close:hover {
  color: #ffffff;
}

.dash-drawer-list {
  flex: 1;
  overflow-y: auto;
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.dash-history-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: 6px;
  color: #cbd5e1;
  font-size: 13px;
  cursor: pointer;
  transition: all 0.16s ease;
}

.dash-history-item:hover {
  background: rgba(255, 255, 255, 0.05);
  color: #ffffff;
}

.dash-history-item svg {
  width: 14px;
  height: 14px;
  color: #64748b;
  flex-shrink: 0;
}

/* ==========================================================================
   8. MODALS (Templates / Upgrade Plan)
   ========================================================================== */
.dash-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.75);
  backdrop-filter: blur(6px);
  z-index: 120;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.dash-modal-overlay.active {
  display: flex;
}

.dash-modal-card {
  width: 100%;
  max-width: 600px;
  background: #0f121d;
  border: 1px solid rgba(255, 87, 34, 0.35);
  border-radius: 14px;
  padding: 28px 32px;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.8), 0 0 35px rgba(255, 87, 34, 0.12);
  position: relative;
  animation: modalPop 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes modalPop {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

.dash-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.dash-modal-header h3 {
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
}

.dash-modal-close {
  color: #94a3b8;
  font-size: 18px;
}

.dash-modal-close:hover {
  color: #ffffff;
}

.dash-template-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 14px;
}

.dash-template-card {
  background: #171b29;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 14px;
  cursor: pointer;
  transition: all 0.2s ease;
  text-align: left;
}

.dash-template-card:hover {
  border-color: rgba(255, 87, 34, 0.5);
  background: #1e2436;
  transform: translateY(-2px);
}

.dash-template-card h4 {
  font-size: 14px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 4px;
}

.dash-template-card p {
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.4;
}

/* ==========================================================================
   9. TAB PANE SWITCHER
   ========================================================================== */
.dash-tab-pane {
  display: none;
  width: 100%;
  height: 100%;
  flex-direction: column;
  animation: tabFadeIn 0.2s ease;
}

.dash-tab-pane.active {
  display: flex;
}

#paneAssistant {
  align-items: center;
  justify-content: flex-start;
  padding: 24px 20px;
  overflow-y: auto;
  overflow-x: hidden;
  min-width: 0;
}

#paneOverview {
  align-items: center;
  justify-content: center;
  padding: 40px 24px;
  overflow-y: auto;
}

#panePersonal {
  padding: 24px 32px;
  overflow-y: auto;
}

#paneInsights {
  padding: 24px 32px;
  overflow-y: auto;
}

@keyframes tabFadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ==========================================================================
   10. OVERVIEW VIEW (Screenshot 1: "Let's build your first automation")
   ========================================================================== */
.dash-overview-view {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px 20px;
}

.dash-overview-title {
  font-size: 26px;
  font-weight: 700;
  color: #ffffff;
  letter-spacing: -0.5px;
  margin-bottom: 32px;
}

.dash-overview-cards {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  flex-wrap: wrap;
}

.dash-overview-card {
  width: 175px;
  height: 140px;
  background: #111420;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.dash-overview-card:hover {
  background: #181d2e;
  border-color: rgba(255, 87, 34, 0.45);
  transform: translateY(-3px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.6), 0 0 24px rgba(255, 87, 34, 0.16);
}

.dash-overview-card svg {
  width: 28px;
  height: 28px;
  color: #94a3b8;
  transition: color 0.2s ease;
}

.dash-overview-card:hover svg {
  color: #ff9800;
}

.dash-overview-card span {
  font-size: 13.5px;
  font-weight: 600;
  color: #f8fafc;
}

/* ==========================================================================
   11. PERSONAL VIEW (Screenshot 2: Workflows, sub-tabs & dashed container)
   ========================================================================== */
.dash-personal-view {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 20px;
  height: 100%;
  overflow-y: auto;
}

.dash-personal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
}

.dash-personal-title {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 4px;
}

.dash-personal-sub {
  font-size: 13px;
  color: #94a3b8;
}

/* Split Action Button: Create workflow ▾ */
.dash-btn-create-split {
  background: #ff5722;
  color: #ffffff;
  font-weight: 600;
  font-size: 13px;
  border-radius: 6px;
  display: flex;
  align-items: center;
  box-shadow: 0 2px 10px rgba(255, 87, 34, 0.4);
  transition: all 0.16s ease;
  overflow: hidden;
}

.dash-btn-create-split:hover {
  background: #f4511e;
  box-shadow: 0 4px 14px rgba(255, 87, 34, 0.6);
  transform: translateY(-1px);
}

.dash-btn-create-split-label {
  padding: 8px 14px;
  display: flex;
  align-items: center;
  gap: 6px;
}

.dash-btn-create-split-dropdown {
  padding: 8px 10px;
  border-left: 1px solid rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-btn-create-split-dropdown svg {
  width: 12px;
  height: 12px;
}

/* Sub-Navigation Tabs */
.dash-subtabs-bar {
  display: flex;
  align-items: center;
  gap: 26px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  padding-bottom: 0;
  overflow-x: auto;
}

.dash-subtab-item {
  font-size: 13px;
  font-weight: 500;
  color: #94a3b8;
  padding: 10px 2px;
  border-bottom: 2px solid transparent;
  cursor: pointer;
  transition: all 0.16s ease;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.dash-subtab-item:hover {
  color: #ffffff;
}

.dash-subtab-item.active {
  color: #ffffff;
  font-weight: 600;
  border-bottom-color: #ff5722;
}

/* Dashed Empty State Box */
.dash-empty-dashed-box {
  border: 1px dashed rgba(255, 255, 255, 0.14);
  border-radius: 10px;
  width: 100%;
  min-height: 400px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 40px;
  background: rgba(255, 255, 255, 0.008);
  margin-top: 8px;
}

.dash-empty-icon {
  width: 38px;
  height: 38px;
  color: #64748b;
  margin-bottom: 18px;
}

.dash-empty-title {
  font-size: 18px;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 6px;
}

.dash-empty-sub {
  font-size: 13px;
  color: #94a3b8;
  margin-bottom: 22px;
  max-width: 440px;
  line-height: 1.5;
}

.dash-btn-create-action {
  background: #ff5722;
  color: #ffffff;
  padding: 10px 22px;
  border-radius: 6px;
  font-weight: 600;
  font-size: 13px;
  transition: all 0.2s ease;
  box-shadow: 0 4px 14px rgba(255, 87, 34, 0.35);
}

.dash-btn-create-action:hover {
  background: #f4511e;
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(255, 87, 34, 0.5);
}

/* ==========================================================================
   12. INSIGHTS VIEW (Screenshot 3: KPI Metrics, Chart & Table)
   ========================================================================== */
.dash-insights-view {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 24px 32px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  height: 100%;
  overflow-y: auto;
}

.dash-insights-header {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.dash-insights-title {
  font-size: 22px;
  font-weight: 700;
  color: #ffffff;
}

.dash-insights-filters {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-filter-pill {
  background: #111420;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 6px 12px;
  font-size: 12px;
  color: #cbd5e1;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  transition: all 0.16s ease;
}

.dash-filter-pill:hover {
  border-color: rgba(255, 87, 34, 0.4);
  background: #181c2c;
  color: #ffffff;
}

.dash-filter-pill svg {
  width: 14px;
  height: 14px;
  color: #94a3b8;
}

/* KPI Container Card */
.dash-insights-kpi-container {
  background: #0f121d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4);
}

.dash-kpi-row {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-kpi-item {
  padding: 16px 20px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  position: relative;
  background: transparent;
  cursor: pointer;
  transition: background 0.16s ease;
}

.dash-kpi-item:last-child {
  border-right: none;
}

.dash-kpi-item.active {
  border-bottom: 2px solid #ff5722;
  background: rgba(255, 87, 34, 0.03);
}

.dash-kpi-title {
  font-size: 12px;
  font-weight: 600;
  color: #cbd5e1;
  margin-bottom: 2px;
}

.dash-kpi-sub {
  font-size: 11px;
  color: #64748b;
  margin-bottom: 12px;
}

.dash-kpi-val {
  font-size: 26px;
  font-weight: 700;
  color: #ffffff;
}

/* Breakdown by Day Chart */
.dash-chart-section {
  padding: 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-chart-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
}

.dash-chart-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #ffffff;
}

.dash-chart-legend {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 11.5px;
  color: #94a3b8;
}

.dash-legend-dot {
  width: 8px;
  height: 8px;
  border-radius: 2px;
  display: inline-block;
  margin-right: 5px;
}

.dash-legend-dot.success { background: #38bdf8; }
.dash-legend-dot.failed { background: #ff5722; }

/* SVG Graph Area */
.dash-chart-canvas {
  width: 100%;
  height: 180px;
  position: relative;
}

.dash-chart-y-axis {
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  font-size: 11px;
  color: #64748b;
  width: 30px;
}

.dash-chart-grid-area {
  margin-left: 35px;
  height: 100%;
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.dash-grid-line {
  width: 100%;
  height: 1px;
  background: rgba(255, 255, 255, 0.06);
}

/* Breakdown by Workflow Table */
.dash-table-section {
  padding: 20px;
}

.dash-table-title {
  font-size: 13.5px;
  font-weight: 600;
  color: #ffffff;
  margin-bottom: 16px;
}

.dash-workflow-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
}

.dash-workflow-table th {
  text-align: left;
  font-weight: 500;
  color: #64748b;
  padding: 8px 12px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-workflow-table th:first-child {
  padding-left: 4px;
}

.dash-table-scroll-track {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 14px;
  padding: 4px 0;
}

.dash-scroll-arrow {
  color: #64748b;
  background: transparent;
  border: none;
  font-size: 16px;
  line-height: 1;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  transition: all 0.16s ease;
}

.dash-scroll-arrow:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

.dash-scroll-thumb-bar {
  flex: 1;
  height: 6px;
  background: rgba(255, 255, 255, 0.05);
  border-radius: 4px;
  position: relative;
  overflow: hidden;
}

.dash-scroll-thumb {
  width: 100%;
  height: 100%;
  background: rgba(255, 255, 255, 0.12);
  border-radius: 4px;
}

/* Responsive */
@media (max-width: 900px) {
  .dash-kpi-row {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .dash-sidebar {
    position: fixed;
    top: 86px;
    bottom: 0;
    left: -220px;
    height: calc(100% - 86px);
  }
  .dash-sidebar.mobile-open {
    left: 0;
  }
  .dash-trial-bar {
    font-size: 11px;
  }
}

/* ==========================================================================
   13. VISUAL WORKFLOW CANVAS (Screenshot 1: Visual workflow editor)
   ========================================================================== */
.dash-canvas-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: #080a11;
  z-index: 200;
  flex-direction: column;
  animation: canvasFadeIn 0.25s ease;
}

.dash-canvas-modal.active {
  display: flex;
}

@keyframes canvasFadeIn {
  from { opacity: 0; transform: scale(0.99); }
  to   { opacity: 1; transform: scale(1); }
}

.dash-canvas-header {
  height: 54px;
  background: #0f121d;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 20px;
  flex-shrink: 0;
}

.dash-canvas-header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}

.dash-canvas-back-btn {
  color: #94a3b8;
  padding: 6px 10px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  cursor: pointer;
  transition: all 0.16s ease;
}

.dash-canvas-back-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
}

.dash-canvas-title-group {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-canvas-title {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.dash-canvas-status-badge {
  font-size: 11px;
  font-weight: 600;
  color: #10b981;
  background: rgba(16, 185, 129, 0.12);
  border: 1px solid rgba(16, 185, 129, 0.3);
  padding: 2px 8px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  gap: 5px;
}

.dash-canvas-status-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 8px #10b981;
}

.dash-canvas-header-right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.dash-btn-canvas-add {
  background: #171c2c;
  border: 1px solid rgba(255, 255, 255, 0.12);
  color: #ffffff;
  padding: 7px 14px;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.16s ease;
}

.dash-btn-canvas-add:hover {
  background: #20273d;
  border-color: rgba(255, 87, 34, 0.5);
}

.dash-btn-canvas-run {
  background: #ff5722;
  color: #ffffff;
  padding: 7px 16px;
  border-radius: 6px;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 6px;
  cursor: pointer;
  transition: all 0.16s ease;
  box-shadow: 0 2px 10px rgba(255, 87, 34, 0.4);
}

.dash-btn-canvas-run:hover {
  background: #f4511e;
  transform: translateY(-1px);
}

.dash-btn-canvas-run.running {
  background: #e65100;
  opacity: 0.8;
  cursor: wait;
}

/* Canvas Viewport */
.dash-canvas-workspace {
  flex: 1;
  position: relative;
  overflow: auto;
  background-color: #090b12;
  background-image: radial-gradient(rgba(255, 255, 255, 0.08) 1.2px, transparent 1.2px);
  background-size: 24px 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 60px 40px;
}

.dash-canvas-nodes-container {
  display: flex;
  align-items: center;
  gap: 40px;
  position: relative;
  z-index: 10;
}

/* Canvas Node Card */
.dash-cnode {
  width: 200px;
  background: #111422;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  padding: 14px;
  position: relative;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  user-select: none;
}

.dash-cnode:hover {
  border-color: rgba(255, 87, 34, 0.5);
  transform: translateY(-2px);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.7), 0 0 20px rgba(255, 87, 34, 0.15);
}

.dash-cnode.active-selected {
  border-color: #ff5722;
  box-shadow: 0 0 25px rgba(255, 87, 34, 0.3);
}

.dash-cnode.pulse-running {
  border-color: #38bdf8;
  animation: nodePulse 0.8s infinite alternate;
}

.dash-cnode.pulse-success {
  border-color: #10b981;
  box-shadow: 0 0 20px rgba(16, 185, 129, 0.4);
}

@keyframes nodePulse {
  from { box-shadow: 0 0 10px rgba(56, 189, 248, 0.2); }
  to   { box-shadow: 0 0 25px rgba(56, 189, 248, 0.6); }
}

.dash-cnode-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.dash-cnode-icon {
  width: 28px;
  height: 28px;
  border-radius: 6px;
  background: #1c2236;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ff9800;
  flex-shrink: 0;
}

.dash-cnode-icon.trigger { color: #38bdf8; background: rgba(56, 189, 248, 0.12); }
.dash-cnode-icon.ai { color: #c084fc; background: rgba(192, 132, 252, 0.12); }
.dash-cnode-icon.logic { color: #f59e0b; background: rgba(245, 158, 11, 0.12); }
.dash-cnode-icon.db { color: #ff5722; background: rgba(255, 87, 34, 0.12); }
.dash-cnode-icon.sync { color: #10b981; background: rgba(16, 185, 129, 0.12); }

.dash-cnode-title {
  font-size: 13px;
  font-weight: 700;
  color: #ffffff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.dash-cnode-type {
  font-size: 11px;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.dash-cnode-desc {
  font-size: 11.5px;
  color: #94a3b8;
  line-height: 1.4;
  margin-top: 4px;
}

/* Ports on nodes */
.dash-cnode-port {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #64748b;
  border: 2px solid #111422;
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  transition: all 0.16s ease;
}

.dash-cnode-port.input { left: -6px; }
.dash-cnode-port.output { right: -6px; background: #ff5722; }

/* SVG Connection Wire Connector between nodes */
.dash-wire-svg {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* Right-side Node Configuration Drawer */
.dash-node-drawer {
  position: absolute;
  top: 54px;
  right: -360px;
  width: 350px;
  bottom: 0;
  background: #0f121d;
  border-left: 1px solid rgba(255, 255, 255, 0.08);
  box-shadow: -10px 0 35px rgba(0, 0, 0, 0.6);
  z-index: 30;
  transition: right 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.dash-node-drawer.active {
  right: 0;
}

.dash-node-drawer-header {
  padding: 16px 20px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dash-node-drawer-header h4 {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.dash-node-drawer-body {
  flex: 1;
  overflow-y: auto;
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dash-field-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.dash-field-group label {
  font-size: 11.5px;
  font-weight: 600;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.dash-field-input {
  background: #171b29;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 13px;
  color: #ffffff;
  outline: none;
  font-family: inherit;
}

.dash-field-input:focus {
  border-color: #ff5722;
}

/* Bottom Execution Output Drawer */
.dash-canvas-bottom-tray {
  height: 160px;
  background: #0b0e17;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: none;
  flex-direction: column;
  z-index: 25;
  flex-shrink: 0;
}

.dash-canvas-bottom-tray.active {
  display: flex;
}

.dash-bottom-tray-header {
  height: 36px;
  background: #0f121d;
  padding: 0 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  font-size: 12px;
  font-weight: 600;
  color: #cbd5e1;
}

.dash-bottom-tray-content {
  flex: 1;
  overflow-y: auto;
  padding: 12px 16px;
  font-family: monospace;
  font-size: 12px;
  color: #94a3b8;
  background: #06070a;
}

/* ==========================================================================
   14. EXECUTIONS TABLE (Screenshot 4: Execution and recovery engine)
   ========================================================================== */
.dash-executions-container {
  display: flex;
  flex-direction: column;
  gap: 16px;
  width: 100%;
}

.dash-executions-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12.5px;
  background: #0f121d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  overflow: hidden;
}

.dash-executions-table th {
  text-align: left;
  font-weight: 600;
  color: #64748b;
  padding: 12px 16px;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.dash-executions-table td {
  padding: 12px 16px;
  color: #cbd5e1;
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.dash-status-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 9px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.dash-status-pill.success {
  background: rgba(16, 185, 129, 0.12);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.25);
}

.dash-status-pill.running {
  background: rgba(56, 189, 248, 0.12);
  color: #38bdf8;
  border: 1px solid rgba(56, 189, 248, 0.25);
}

.dash-status-pill.error {
  background: rgba(244, 63, 94, 0.12);
  color: #f43f5e;
  border: 1px solid rgba(244, 63, 94, 0.25);
}

.dash-btn-retry {
  background: rgba(255, 87, 34, 0.12);
  color: #ff9800;
  border: 1px solid rgba(255, 87, 34, 0.3);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11px;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.16s ease;
}

.dash-btn-retry:hover {
  background: #ff5722;
  color: #ffffff;
}

/* ==========================================================================
   15. AI & RAG BUILDER (Screenshot 3: AI and RAG builder)
   ========================================================================== */
.dash-rag-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  width: 100%;
}

.dash-rag-card {
  background: #0f121d;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.dash-rag-card-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-rag-card-icon {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.dash-rag-card-icon.ingest {
  background: rgba(56, 189, 248, 0.15);
  color: #38bdf8;
}

.dash-rag-card-icon.retrieve {
  background: rgba(192, 132, 252, 0.15);
  color: #c084fc;
}

.dash-rag-card-title {
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
}

.dash-rag-card-sub {
  font-size: 12px;
  color: #94a3b8;
}

.dash-rag-pipeline-step {
  background: #171c2c;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
  color: #cbd5e1;
}

.dash-rag-step-num {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: rgba(255, 87, 34, 0.2);
  color: #ff9800;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 10.5px;
  font-weight: 700;
  margin-right: 8px;
}

/* ==========================================================================
   16. INTEGRATION & API SYSTEM MODAL (Screenshot 2: Connect anything to everything)
   ========================================================================== */
.dash-integrations-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(12px);
  z-index: 250;
  align-items: center;
  justify-content: center;
  padding: 24px;
  animation: canvasFadeIn 0.2s ease;
}

.dash-integrations-modal.active {
  display: flex;
}

.dash-integrations-dialog {
  width: 100%;
  max-width: 960px;
  height: 640px;
  background: #0d101b;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 14px;
  box-shadow: 0 25px 60px rgba(0, 0, 0, 0.8), 0 0 40px rgba(255, 87, 34, 0.08);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.dash-integrations-top {
  padding: 24px 28px 18px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #111524;
}

.dash-integrations-title {
  font-size: 20px;
  font-weight: 800;
  color: #ffffff;
  letter-spacing: -0.3px;
}

.dash-integrations-search-wrap {
  position: relative;
  width: 380px;
}

.dash-integrations-search {
  width: 100%;
  background: #191f33;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 8px;
  padding: 8px 14px 8px 36px;
  color: #ffffff;
  font-size: 13px;
  outline: none;
  transition: border-color 0.16s ease;
}

.dash-integrations-search:focus {
  border-color: #ff5722;
}

.dash-integrations-search-icon {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: #64748b;
  pointer-events: none;
}

.dash-integrations-body {
  flex: 1;
  display: flex;
  overflow: hidden;
}

.dash-integrations-sidebar {
  width: 220px;
  border-right: 1px solid rgba(255, 255, 255, 0.08);
  padding: 16px 12px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 3px;
  background: #0f1220;
}

.dash-int-category-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 12px;
  border-radius: 6px;
  color: #94a3b8;
  font-size: 13px;
  font-weight: 500;
  border: none;
  background: transparent;
  cursor: pointer;
  text-align: left;
  transition: all 0.16s ease;
}

.dash-int-category-btn:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.05);
}

.dash-int-category-btn.active {
  color: #ff9800;
  background: rgba(255, 87, 34, 0.12);
  font-weight: 600;
}

.dash-integrations-grid {
  flex: 1;
  padding: 24px;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 16px;
  align-content: start;
}

.dash-int-card {
  background: #14192b;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 10px;
  padding: 16px;
  cursor: pointer;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
}

.dash-int-card:hover {
  transform: translateY(-2px);
  border-color: rgba(255, 87, 34, 0.5);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.4);
}

.dash-int-card-top {
  display: flex;
  align-items: center;
  gap: 12px;
}

.dash-int-card-icon {
  width: 36px;
  height: 36px;
  border-radius: 8px;
  background: #1f2742;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ff9800;
  font-weight: 700;
  font-size: 16px;
  flex-shrink: 0;
}

.dash-int-card-name {
  font-size: 14px;
  font-weight: 700;
  color: #ffffff;
}

.dash-int-card-category {
  font-size: 11px;
  color: #64748b;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

.dash-int-card-desc {
  font-size: 12px;
  color: #94a3b8;
  line-height: 1.45;
}

/* SVG Connecting Wires */
.dash-wire-path {
  fill: none;
  stroke: rgba(255, 87, 34, 0.45);
  stroke-width: 2.5px;
  stroke-linecap: round;
  transition: stroke 0.3s ease;
}

.dash-wire-path.active {
  stroke: #ff9800;
  stroke-width: 3px;
  filter: drop-shadow(0 0 6px rgba(255, 152, 0, 0.8));
}

.dash-wire-pulse {
  fill: none;
  stroke: #38bdf8;
  stroke-width: 3.5px;
  stroke-linecap: round;
  stroke-dasharray: 12 16;
  animation: wireDash 1s linear infinite;
  filter: drop-shadow(0 0 8px #38bdf8);
}

@keyframes wireDash {
  from { stroke-dashoffset: 28; }
  to   { stroke-dashoffset: 0; }
}

/* RAG Benchmark Output Box */
.dash-rag-benchmark-box {
  margin-top: 18px;
  background: #090b12;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 8px;
  padding: 16px;
  font-size: 12.5px;
  color: #cbd5e1;
  display: none;
}

.dash-rag-benchmark-box.active {
  display: block;
}

