/* ==========================================================================
   styles.css — Bot Control Center (OLED Dark + Glassmorphism + Bento)
   Imports unified design tokens from /var/www/development/theme.css
   ========================================================================== */

@import url('theme.css');

/* ── App Shell ── */
.app {
  display: grid;
  grid-template-columns: var(--sidebar-width) 1fr;
  min-height: 100vh;
  background: var(--bg-main);
}

/* ── Sidebar ── */
.sidebar {
  position: sticky;
  top: 0;
  height: 100vh;
  background: var(--bg-sidebar);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-right: var(--border-subtle);
  display: flex;
  flex-direction: column;
  padding: var(--space-6);
  gap: var(--space-8);
  z-index: var(--z-sidebar);
  overflow-y: auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding-bottom: var(--space-5);
  border-bottom: var(--border-subtle);
}

.brand__logo {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--primary), var(--accent-purple));
  color: var(--text-primary);
  font-weight: 800;
  font-size: 15px;
  letter-spacing: -0.02em;
  box-shadow: var(--shadow-glow-primary);
}

.brand__title {
  font-weight: 700;
  font-size: 16px;
  color: var(--text-primary);
  line-height: 1.2;
}

.brand__subtitle {
  font-size: 11px;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1.2;
}

/* ── Sidebar Navigation ── */
.nav {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
}

.nav__btn {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  width: 100%;
  padding: 10px 14px;
  border: none;
  border-radius: var(--radius-md);
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  font-weight: 500;
  text-align: left;
  transition: all var(--transition-fast);
  position: relative;
}

.nav__btn::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  background: var(--primary);
  transition: height var(--transition-normal);
}

.nav__btn:hover {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-primary);
}

.nav__btn--active {
  background: var(--primary-muted);
  color: var(--primary);
  font-weight: 600;
}

.nav__btn--active::before {
  height: 20px;
}

.nav__separator {
  padding: var(--space-4) 14px 6px;
  font-size: 10px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.12em;
  user-select: none;
}

.sidebar__footer {
  margin-top: auto;
  padding-top: var(--space-4);
  border-top: var(--border-subtle);
}

.sidebar__footer p {
  font-size: 11px;
  color: var(--text-muted);
  opacity: 0.6;
}

/* ── Main Content ── */
.main {
  padding: var(--space-8) var(--space-10);
  min-height: 100vh;
  overflow-x: hidden;
}

.header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-6);
  margin-bottom: var(--space-8);
  padding-bottom: var(--space-6);
  border-bottom: var(--border-subtle);
  animation: fadeInUp var(--transition-slow) ease-out;
}

.header h1 {
  font-size: 26px;
  font-weight: 800;
  color: var(--text-primary);
  letter-spacing: -0.03em;
  margin-bottom: 2px;
}

.header p {
  font-size: 13px;
  color: var(--text-muted);
}

.header__actions {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  flex-shrink: 0;
}

/* ── System State Pills ── */
.system-state {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-3);
  flex-wrap: wrap;
}

.state-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-secondary);
  border: var(--border-subtle);
  transition: all var(--transition-fast);
}

.state-pill:hover {
  border-color: var(--primary);
  color: var(--primary);
}

/* ── Language Switch ── */
.lang-switch {
  display: flex;
  border-radius: var(--radius-md);
  overflow: hidden;
  border: var(--border-subtle);
  background: var(--bg-input);
}

.lang-switch .btn--ghost {
  border-radius: 0;
  border: none;
}

/* ── Auth State ── */
.auth-state {
  font-size: 12px;
  color: var(--text-muted);
  padding: 6px 12px;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.03);
  border: var(--border-subtle);
}

/* ── Tab System ── */
.tab {
  display: none;
  animation: fadeInUp var(--transition-slow) ease-out;
}

.tab--active {
  display: block;
}

/* ── Grid Systems ── */
.grid {
  display: grid;
  gap: var(--space-6);
}

/* ── Bento KPI Grid ── */
.kpi-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-3);
}

.kpi-card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-bento);
  padding: var(--space-4) var(--space-5);
  transition: all var(--transition-normal);
}

.kpi-card:hover {
  background: var(--bg-card-hover);
  border: var(--glass-border-hover);
  /* transform: translateY(-2px) removed — handled by magnetic-cursor.js Canvas engine */
  box-shadow: var(--shadow-md), 0 0 20px rgba(129, 140, 248, 0.06);
}

.kpi-card:nth-child(1) { grid-column: span 2; }

.kpi-label {
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.kpi-value {
  font-size: 28px;
  font-weight: 800;
  margin-top: var(--space-1);
  color: var(--text-primary);
  letter-spacing: -0.02em;
  font-variant-numeric: tabular-nums;
}

/* ── Widgets Grid ── */
.widgets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--space-3);
}

.widget-box {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  transition: all var(--transition-normal);
}

.widget-box:hover {
  background: var(--bg-card-hover);
  border: var(--glass-border-hover);
}

.widget-box h3 {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin: 0 0 var(--space-2) 0;
}

/* ── Glass Card ── */
.card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-bento);
  box-shadow: var(--glass-shadow);
  overflow: hidden;
  transition: all var(--transition-normal);
}

.card:hover {
  border: var(--glass-border-hover);
  box-shadow: var(--glass-shadow), 0 0 30px rgba(129, 140, 248, 0.04);
}

.card__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6);
  border-bottom: var(--border-subtle);
}

.card__header h2 {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 2px;
}

.card__header p {
  font-size: 12px;
  color: var(--text-muted);
}

.card__body {
  padding: var(--space-5) var(--space-6);
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 18px;
  font-family: var(--font-sans);
  font-size: 13px;
  font-weight: 600;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all var(--transition-fast);
  white-space: nowrap;
  user-select: none;
}

.btn:hover {
  /* transform removed — visual feedback handled by magnetic-cursor.js Canvas engine */
}

.btn:active {
  /* transform removed */
}

.btn--primary {
  background: linear-gradient(135deg, var(--primary), var(--accent-purple));
  color: #fff;
  box-shadow: 0 2px 8px var(--primary-glow);
}

.btn--primary:hover {
  box-shadow: 0 4px 16px var(--primary-glow);
}

.btn--ghost {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  border: var(--border-subtle);
}

.btn--ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  color: var(--text-primary);
  border-color: rgba(255, 255, 255, 0.14);
}

.btn--accent {
  background: var(--accent-cyan-glow);
  color: var(--accent-cyan);
  border: 1px solid rgba(34, 211, 238, 0.20);
}

.btn--accent:hover {
  background: rgba(34, 211, 238, 0.16);
}

.btn--sm {
  padding: 6px 12px;
  font-size: 12px;
  border-radius: var(--radius-sm);
}

.btn--icon {
  min-width: 32px;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: var(--radius-sm);
}

.btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
  pointer-events: none;
  transform: none;
  box-shadow: none;
}

.btn--saved {
  background: var(--success-muted);
  border-color: rgba(52, 211, 153, 0.25);
  color: var(--success);
}

/* ── Inputs & Selects ── */
.input,
.select,
.textarea {
  width: 100%;
  padding: 10px 14px;
  border: var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  transition: all var(--transition-fast);
}

.input::placeholder {
  color: var(--text-muted);
  opacity: 0.7;
}

.input:focus,
.select:focus,
.textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.input--small {
  padding: 7px 10px;
  font-size: 12px;
  width: auto;
}

.textarea {
  resize: vertical;
  min-height: 80px;
  line-height: 1.5;
}

/* ── Native <option> inside <select> dropdowns ── */
select.select option,
select option {
  background: var(--bg-elevated, #161622);
  color: var(--text-primary, #e0e0e8);
  padding: 8px 12px;
}

select.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2394A3B8' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}

.select--small {
  padding: 7px 32px 7px 10px;
  font-size: 12px;
}

/* ── Custom Dropdown (replaces native <select>) ── */
.custom-select-root {
  position: relative;
  width: 100%;
}

/* ── Full-viewport transparent backdrop — captures all pointer events ── */
.custom-select__backdrop {
  display: none;
  position: fixed;
  inset: 0;
  z-index: calc(var(--z-dropdown) - 1);
  background: transparent;
  cursor: default;
}

.custom-select__backdrop--active {
  display: block;
}

.custom-select__trigger {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-2);
  width: 100%;
  padding: 10px 14px;
  border: var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  text-align: left;
  transition: all var(--transition-fast);
}

.custom-select__trigger:hover {
  border-color: rgba(255, 255, 255, 0.16);
}

.custom-select--open .custom-select__trigger {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.custom-select__label {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.custom-select__chevron {
  flex-shrink: 0;
  color: var(--text-muted);
  transition: transform var(--transition-fast);
  pointer-events: none;
}

.custom-select--open .custom-select__chevron {
  transform: rotate(180deg);
}

/* ── Dropdown menu (iOS-style animation) ── */
.custom-select__menu {
  position: absolute;
  top: calc(100% + 4px);
  left: 0;
  right: 0;
  z-index: var(--z-dropdown);
  margin: 0;
  padding: var(--space-1);
  list-style: none;
  border: var(--glass-border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-xl);
  max-height: min(420px, 65vh);
  overflow-y: auto;

  /* Closed state */
  opacity: 0;
  transform: scale(0.96) translateY(-6px);
  filter: blur(4px);
  pointer-events: none;
  transition:
    opacity 0.22s cubic-bezier(0.16, 1, 0.3, 1),
    transform 0.25s cubic-bezier(0.16, 1, 0.3, 1),
    filter 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.custom-select--open .custom-select__menu {
  opacity: 1;
  transform: scale(1) translateY(0);
  filter: blur(0);
  pointer-events: auto;
}

/* ── Menu items ── */
.custom-select__item {
  display: flex;
  align-items: center;
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 10px;
  line-height: 1.3;
  cursor: pointer;
  user-select: none;
  transition: background var(--transition-fast), color var(--transition-fast);
}

.custom-select__item:hover,
.custom-select__item:focus-visible {
  background: var(--accent-subtle);
  color: var(--text-primary);
}

.custom-select__item--selected {
  background: var(--primary-muted);
  color: var(--primary);
  font-weight: 600;
}

.custom-select__item--selected::after {
  content: "✓";
  margin-left: auto;
  font-size: 9px;
  font-weight: 700;
  opacity: 0.7;
}

/* ── Form Layouts ── */
.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: var(--space-3);
  margin-bottom: var(--space-4);
  align-items: end;
}

.form-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-3);
}

.form-grid--campaign {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

.form-row--calls {
  grid-template-columns: repeat(4, minmax(160px, 1fr));
}

.form-row--csv {
  grid-template-columns: 1fr auto auto auto;
}

.form-row--crm-bulk {
  grid-template-columns: minmax(260px, 1fr) auto auto;
}

.form-row--runtime-pass {
  grid-template-columns: minmax(320px, 1fr) 1fr;
}

.field-stack {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.field-stack .hint {
  margin-top: 0;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
}

.inline-picker {
  display: flex;
  gap: var(--space-2);
  align-items: center;
}

.inline-picker .input {
  flex: 1;
}

/* ── Multi Select ── */
.multi-select {
  position: relative;
}

.multi-select__toggle {
  width: 100%;
  padding: 10px 14px;
  border: var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  text-align: left;
  transition: all var(--transition-fast);
}

.multi-select__toggle:hover {
  border-color: rgba(255, 255, 255, 0.16);
}

.multi-select__menu {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  margin-top: 4px;
  border: var(--glass-border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-lg);
  z-index: var(--z-dropdown);
  max-height: 240px;
  overflow-y: auto;
  padding: var(--space-1);
  display: none;
  transform-origin: top center;
}

.multi-select__menu:not([aria-hidden="true"]) {
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: menuIn 0.25s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

/* ── Multi-select items ── */
.multi-select__item {
  display: flex;
  align-items: center;
  gap: var(--space-2);
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13px;
  cursor: pointer;
  transition: background var(--transition-fast);
  user-select: none;
}

.multi-select__item:hover {
  background: var(--accent-subtle);
  color: var(--text-primary);
}

.multi-select__item input[type="checkbox"] {
  accent-color: var(--primary);
  width: 15px;
  height: 15px;
  margin: 0;
  flex-shrink: 0;
}

/* ── Hint ── */
.hint {
  font-size: 12px;
  color: var(--text-muted);
  margin-top: var(--space-3);
  line-height: 1.5;
}

/* ── Tables ── */
.table-wrapper {
  overflow-x: auto;
  border-radius: var(--radius-bento);
  border: var(--border-subtle);
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
}

.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.table thead {
  position: sticky;
  top: 0;
  z-index: 10;
}

.table thead th {
  background: rgba(15, 15, 22, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: var(--border-strong);
}

.table th {
  padding: 12px 14px;
  text-align: left;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  white-space: nowrap;
  border-bottom: var(--border-subtle);
}

.table td {
  padding: 11px 14px;
  border-bottom: var(--border-subtle);
  color: var(--text-secondary);
  white-space: nowrap;
}

.table tbody tr {
  transition: background var(--transition-fast);
  animation: rowIn 0.35s ease-out forwards;
}

.table tbody tr:hover {
  background: rgba(255, 255, 255, 0.03);
}

.table tbody tr:last-child td {
  border-bottom: none;
}

.table th:first-child,
.table td:first-child {
  padding-left: var(--space-5);
}

.table th:last-child,
.table td:last-child {
  padding-right: var(--space-5);
}

/* ── Badges ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.02em;
  white-space: nowrap;
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
}

.badge--warn {
  background: var(--warning-muted);
  color: var(--warning);
}

.badge--ok {
  background: var(--success-muted);
  color: var(--success);
}

.badge--new {
  background: rgba(34, 211, 238, 0.12);
  color: var(--accent-cyan);
}

.badge--danger {
  background: var(--danger-muted);
  color: var(--danger);
}

/* ── Status Dot (replaces emoji indicators) ── */
.status-dot {
  display: inline-block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  vertical-align: middle;
  flex-shrink: 0;
}
.status-dot--ok {
  background: var(--accent-emerald);
  box-shadow: 0 0 6px var(--accent-emerald);
}
.status-dot--err {
  background: var(--danger);
  box-shadow: 0 0 6px var(--danger);
}

/* ── Preflight item ── */
.preflight-item {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: var(--text-secondary);
  white-space: nowrap;
}

/* ── Alerts List ── */
.alerts-list {
  margin: 0;
  padding: 0;
  display: grid;
  gap: var(--space-2);
  list-style: none;
}

.alerts-list li {
  padding: var(--space-3) var(--space-4);
  border-radius: var(--radius-md);
  font-size: 13px;
  background: rgba(255, 255, 255, 0.03);
  border: var(--border-subtle);
  border-left: 3px solid var(--warning);
}

/* ── Infrastructure ── */
.infra-summary {
  font-weight: 600;
  font-size: 14px;
  color: var(--text-primary);
  margin-bottom: var(--space-4);
}

.advanced-box {
  margin: var(--space-4) 0;
  border: var(--border-subtle);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
}

.advanced-box > summary {
  font-weight: 600;
  font-size: 13px;
  color: var(--text-secondary);
}

/* ── CRM Docs ── */
.crm-docs {
  border: 1px dashed rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  margin-bottom: var(--space-4);
}

.crm-docs ul {
  margin: var(--space-2) 0 0;
  padding-left: 18px;
}

/* ── Logs ── */
.logs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: var(--space-4);
  align-items: stretch;
}

.logs-grid--compact {
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
}

.log-card {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-bento);
  padding: var(--space-5);
  display: flex;
  flex-direction: column;
  gap: var(--space-3);
  min-height: 380px;
  transition: all var(--transition-normal);
}

.log-card:hover {
  border: var(--glass-border-hover);
}

.logs-grid--compact .log-card {
  min-height: 300px;
}

.log-output {
  flex: 1;
  background: var(--bg-deep);
  color: #E2E8F0;
  padding: var(--space-4);
  border-radius: var(--radius-md);
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.6;
  overflow-y: auto;
  overflow-x: auto;
  white-space: pre;
  border: var(--border-subtle);
  min-height: 200px;
}

.logs-grid--compact .log-output {
  height: 240px;
  max-height: 380px;
  font-size: 11px;
}

.log-output--wrap {
  white-space: pre-wrap;
  word-break: break-word;
}

.log-card__header {
  display: flex;
  justify-content: space-between;
  gap: var(--space-3);
  align-items: stretch;
  flex-wrap: wrap;
}

.log-card__header > div {
  min-width: 0;
  flex: 1 1 180px;
}

.log-card__title {
  font-weight: 700;
  font-size: 14px;
  color: var(--text-primary);
}

.log-card__subtitle {
  color: var(--text-muted);
  font-size: 11px;
}

.log-card__status {
  margin-top: 2px;
  font-size: 11px;
  color: var(--text-muted);
}

.status--info  { color: var(--primary); }
.status--error { color: var(--danger); }
.status--warn  { color: var(--warning); }

.log-card__actions {
  display: flex;
  gap: var(--space-1);
  flex-wrap: wrap;
  justify-content: flex-end;
  max-width: 100%;
}

/* ── Service Pills ── */
.service-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 12px;
  border-radius: var(--radius-full);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.service-pill--running {
  color: var(--success);
  background: var(--success-muted);
}

.service-pill--reloading {
  color: var(--warning);
  background: var(--warning-muted);
}

.service-pill--stopped {
  color: var(--danger);
  background: var(--danger-muted);
}

/* ── Pod Controls ── */
.pod-controls {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  flex-wrap: wrap;
}

.pod-controls input {
  width: 90px;
  padding: 10px 14px;
  border: var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  transition: all var(--transition-fast);
}

.pod-controls input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.pod-controls select {
  min-width: 360px;
  max-width: 520px;
  padding: 10px 14px;
  border: var(--border-default);
  border-radius: var(--radius-md);
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  transition: all var(--transition-fast);
}

/* ── Control Toggle ── */
.control-toggle {
  display: inline-flex;
  align-items: center;
  gap: var(--space-2);
  font-size: 12px;
  color: var(--text-secondary);
  cursor: pointer;
  user-select: none;
}

.control-toggle input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: var(--primary);
  cursor: pointer;
}

/* ── GPU Controls ── */
.gpu-auto-controls {
  display: flex;
  gap: var(--space-2);
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: var(--space-3);
}

.gpu-balancer-controls {
  display: flex;
  gap: var(--space-2);
  margin: var(--space-3) 0;
}

/* ── Row Actions ── */
.row-actions {
  display: flex;
  gap: var(--space-2);
  flex-wrap: wrap;
}

/* ── Controls Container ── */
.controls {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  flex-wrap: wrap;
}

/* ── Modal System (Glassmorphism) ── */
.modal {
  position: fixed;
  inset: 0;
  display: none;
  align-items: center;
  justify-content: center;
  z-index: var(--z-modal);
}

.modal:not([aria-hidden="true"]) {
  display: flex;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  animation: fadeIn var(--transition-normal) ease-out;
  pointer-events: auto;
  z-index: -1;
}

.modal__card {
  position: relative;
  width: min(880px, calc(100vw - 48px));
  max-height: calc(100vh - 80px);
  display: flex;
  flex-direction: column;
  background: var(--bg-elevated);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  border: var(--glass-border);
  border-radius: var(--radius-xl);
  box-shadow: var(--shadow-lg), 0 0 60px rgba(129, 140, 248, 0.05);
  animation: modalIn var(--transition-slow) ease-out;
  overflow: hidden;
}

.modal__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-5) var(--space-6);
  border-bottom: var(--border-subtle);
}

.modal__head h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-primary);
}

.modal__body {
  padding: var(--space-5) var(--space-6);
  overflow-y: auto;
  flex: 1;
}

.modal-actions {
  padding: var(--space-4) var(--space-6);
  border-top: var(--border-subtle);
  justify-content: flex-end;
}

/* ── Collapsible Filter Box ── */
.filter-box {
  margin-bottom: 10px;
  border: var(--border-subtle);
  border-radius: var(--radius-lg);
  background: var(--bg-card);
  overflow: hidden;
}

.filter-box[open] {
  border-color: var(--border-strong);
}

.filter-box__summary {
  padding: 10px 16px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  user-select: none;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color var(--transition-fast);
}

.filter-box__summary::-webkit-details-marker {
  display: none;
}

.filter-box__summary::before {
  content: "▶";
  font-family: monospace;
  font-size: 10px;
  transition: transform var(--transition-fast);
}

.filter-box[open] > .filter-box__summary::before {
  transform: rotate(90deg);
}

.filter-box__summary:hover {
  color: var(--text-primary);
}

.filter-box > .form-row,
.filter-box > .form-grid,
.filter-box[open] > .form-row,
.filter-box[open] > .form-grid {
  padding: 0 16px 14px;
  animation: detailsReveal 0.35s cubic-bezier(0.22, 1, 0.36, 1) both;
}

/* ── Monospace table cells ── */
.table td {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  font-size: 12px;
}

/* ── Auth Login Modal (Glassmorphism + Tilt + Border Glow + Shimmer) ── */
.auth-login-card {
  width: min(420px, calc(100vw - 48px));
  background: var(--bg-glass);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-2xl);
  box-shadow: var(--shadow-xl), 0 0 80px rgba(99, 102, 241, 0.06);
  transform-style: preserve-3d;
  perspective: 800px;
  transition: transform 0.15s ease-out;
  /* Override default modal__card animation for auth */
  animation: authModalIn 0.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

@keyframes authModalIn {
  0%   { opacity: 0; transform: scale(0.88) translateY(20px) rotateX(4deg); }
  100% { opacity: 1; transform: scale(1) translateY(0) rotateX(0deg); }
}

/* ── Glassmorphism inner glow ring (pseudo-element) ── */
.auth-login-card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(
    135deg,
    rgba(99, 102, 241, 0.25) 0%,
    rgba(139, 92, 246, 0.12) 40%,
    rgba(34, 211, 238, 0.08) 70%,
    rgba(99, 102, 241, 0.25) 100%
  );
  background-size: 300% 300%;
  animation: authBorderGlow 6s ease-in-out infinite;
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  z-index: 0;
}

@keyframes authBorderGlow {
  0%, 100% { background-position: 0% 50%; }
  25%      { background-position: 100% 0%; }
  50%      { background-position: 100% 100%; }
  75%      { background-position: 0% 100%; }
}

/* Ensure content sits above ::before */
.auth-login-card > * {
  position: relative;
  z-index: 1;
}

.auth-login-body {
  padding: var(--space-10) var(--space-8);
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.auth-login-label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.auth-login-row {
  display: flex;
  gap: var(--space-2);
  margin-top: var(--space-4);
}

.auth-login-row .input {
  flex: 1;
}

/* ── Border Glow for inputs inside auth card ── */
.auth-login-card .input {
  background: rgba(15, 15, 22, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.08);
  transition: all 0.3s ease, box-shadow 0.4s ease;
}

.auth-login-card .input:focus {
  outline: none;
  border-color: transparent;
  background: rgba(18, 18, 26, 0.7);
  box-shadow:
    0 0 0 2px var(--accent-soft),
    0 0 24px rgba(99, 102, 241, 0.12),
    0 0 0 1px var(--accent),
    inset 0 0 20px rgba(99, 102, 241, 0.04);
}

/* ── Shimmer Submit Button ── */
.auth-login-card .btn--primary {
  position: relative;
  overflow: hidden;
  background: linear-gradient(
    135deg,
    var(--accent) 0%,
    var(--accent-purple) 50%,
    var(--accent) 100%
  );
  background-size: 200% 200%;
  animation: shimmer 4s ease infinite;
  box-shadow:
    0 4px 16px rgba(99, 102, 241, 0.25),
    0 0 40px rgba(99, 102, 241, 0.08);
  border-radius: var(--radius-md);
  padding: 11px 24px;
  font-weight: 700;
  letter-spacing: 0.02em;
  transition: all 0.3s ease;
  z-index: 0;
}

.auth-login-card .btn--primary::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    135deg,
    transparent 30%,
    rgba(255, 255, 255, 0.08) 50%,
    transparent 70%
  );
  background-size: 200% 200%;
  animation: shimmer 3s ease infinite;
  pointer-events: none;
  z-index: 1;
}

.auth-login-card .btn--primary:hover {
  box-shadow:
    0 6px 24px rgba(99, 102, 241, 0.35),
    0 0 60px rgba(99, 102, 241, 0.12);
  /* transform: translateY(-2px) removed — handled by magnetic-cursor.js Canvas engine */
}

.auth-login-card .btn--primary:active {
  /* transform: translateY(0) removed */
  box-shadow:
    0 2px 8px rgba(99, 102, 241, 0.2),
    0 0 20px rgba(99, 102, 241, 0.06);
}

/* Disabled shimmer */
.auth-login-card .btn--primary:disabled {
  animation: none;
  background: rgba(255, 255, 255, 0.06);
  box-shadow: none;
  opacity: 0.35;
}

.auth-login-error {
  margin-top: var(--space-3);
  font-size: 13px;
  color: var(--danger);
  min-height: 20px;
  text-align: center;
}

/* ── Lead Panel (Slide-over) ── */
.lead-panel {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  width: min(560px, calc(100vw - 32px));
  max-height: calc(100vh - 32px);
  border: var(--glass-border);
  border-radius: var(--radius-bento);
  background: var(--bg-elevated);
  backdrop-filter: blur(24px);
  -webkit-backdrop-filter: blur(24px);
  box-shadow: var(--shadow-lg);
  display: none;
  z-index: var(--z-dropdown);
  animation: slideInRight var(--transition-slow) ease-out;
}

.lead-panel--open {
  display: flex;
  flex-direction: column;
}

.lead-panel__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  padding: var(--space-3) var(--space-4);
  border-bottom: var(--border-subtle);
}

.lead-panel__header h3 {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text-primary);
}

.lead-panel__body {
  padding: var(--space-4);
  overflow: auto;
}

.lead-timeline {
  display: grid;
  gap: var(--space-2);
}

.lead-timeline__item {
  border: var(--border-subtle);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  background: rgba(255, 255, 255, 0.02);
  font-size: 13px;
}

.lead-transcript {
  margin: 0;
  min-height: 120px;
  border: var(--border-subtle);
  border-radius: var(--radius-md);
  background: var(--bg-deep);
  padding: var(--space-3);
  white-space: pre-wrap;
  word-break: break-word;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
}

/* ── Config Sections ── */
.config-sections {
  display: grid;
  gap: var(--space-4);
}

.config-block {
  background: var(--bg-card);
  backdrop-filter: blur(var(--glass-blur));
  -webkit-backdrop-filter: blur(var(--glass-blur));
  border: var(--glass-border);
  border-radius: var(--radius-md);
  padding: var(--space-4);
}

.config-block__header {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  margin-bottom: var(--space-3);
  border-bottom: var(--border-subtle);
  padding-bottom: var(--space-2);
}

.config-block__header h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.config-block__body {
  display: grid;
  gap: var(--space-3);
}

/* ── Input Group ── */
.input-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.input-group label {
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.input-with-action {
  position: relative;
  display: flex;
  align-items: center;
}

.input-with-action .input {
  padding-right: 44px;
}

.btn-toggle-eye {
  position: absolute;
  right: 8px;
  width: 28px;
  height: 28px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  opacity: 0.5;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity var(--transition-fast);
}

.btn-toggle-eye:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.06);
}

/* ── Runtime Grid ── */
.runtime-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-4);
  align-items: start;
}

.runtime-col {
  display: grid;
  gap: var(--space-2);
}

.minimal-header {
  margin: 0 0 2px;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
}

.field {
  display: grid;
  gap: 4px;
}

.field label {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 600;
  letter-spacing: 0.04em;
}

.input-wrapper {
  position: relative;
  display: flex;
  align-items: center;
}

.minimal-input {
  width: 100%;
  border: var(--border-default);
  border-radius: var(--radius-md);
  padding: 10px 38px 10px 12px;
  min-height: 42px;
  background: var(--bg-input);
  color: var(--text-primary);
  font-family: var(--font-sans);
  font-size: 13.5px;
  transition: all var(--transition-fast);
}

.minimal-input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--primary-glow);
}

.icon-btn {
  position: absolute;
  right: 6px;
  width: 28px;
  height: 28px;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
  opacity: 0.55;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all var(--transition-fast);
}

.icon-btn:hover {
  opacity: 1;
  background: rgba(255, 255, 255, 0.06);
}

/* ── Docs Layout ── */
.docs-layout {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 0;
  height: 70vh;
  border: var(--border-subtle);
  border-radius: var(--radius-md);
  overflow: hidden;
  background: var(--bg-card);
}

.docs-list-wrap {
  background: rgba(255, 255, 255, 0.02);
  border-right: var(--border-subtle);
  padding: var(--space-4) 0;
}

.docs-list {
  display: grid;
  gap: 2px;
  max-height: 100%;
  overflow: auto;
}

.doc-nav-item {
  display: flex;
  align-items: center;
  width: 100%;
  border: 0;
  background: transparent;
  padding: 10px 20px;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-sans);
  font-size: 13.5px;
  color: var(--text-secondary);
  transition: background var(--transition-fast);
  border-left: 3px solid transparent;
}

.doc-nav-item:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

.doc-nav-item--active {
  background: var(--primary-muted);
  border-left-color: var(--primary);
  font-weight: 600;
  color: var(--primary);
}

.doc-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  margin-right: 12px;
  flex: 0 0 auto;
}

.doc-dot--api          { background: var(--primary); }
.doc-dot--requirements { background: var(--success); }
.doc-dot--debug        { background: var(--warning); }
.doc-dot--error        { background: var(--danger); }

.docs-content-wrap {
  background: transparent;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.docs-content-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-3) var(--space-5);
  border-bottom: var(--border-subtle);
  background: rgba(255, 255, 255, 0.02);
}

.docs-content-title {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 600;
}

.docs-version-badge {
  display: inline-flex;
  align-items: center;
  border-radius: var(--radius-full);
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-muted);
}

.docs-content {
  padding: var(--space-6) var(--space-8);
  overflow-y: auto;
  line-height: 1.7;
  color: var(--text-secondary);
  font-size: 14px;
  flex: 1;
}

.docs-content h1 {
  border-bottom: 2px solid rgba(255, 255, 255, 0.08);
  padding-bottom: var(--space-3);
  margin: 0 0 var(--space-6);
  color: var(--text-primary);
  font-size: 22px;
}

.docs-content h2 {
  margin: var(--space-8) 0 var(--space-3);
  padding-bottom: var(--space-1);
  border-bottom: var(--border-subtle);
  color: var(--text-primary);
  font-size: 17px;
}

.docs-content h3 {
  margin: var(--space-5) 0 var(--space-2);
  color: var(--text-primary);
  font-size: 15px;
}

.docs-content p {
  margin: 0 0 var(--space-3);
}

.docs-content code {
  background: rgba(255, 255, 255, 0.06);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
}

.docs-content .code-block {
  background: var(--bg-deep);
  color: #F8FAFC;
  padding: var(--space-4);
  border-radius: var(--radius-md);
  margin: var(--space-4) 0;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 12.5px;
}

.docs-content .code-block code {
  background: transparent;
  padding: 0;
  color: inherit;
}

.docs-spacer {
  height: var(--space-2);
}

/* ── Resource Tabs ── */
.resource-tabs {
  display: flex;
  gap: var(--space-1);
  margin-bottom: var(--space-4);
}

.resource-tab-btn {
  border-bottom: 2px solid transparent;
  transition: all var(--transition-fast);
}

.resource-tab-btn--active {
  border-bottom-color: var(--primary);
  color: var(--primary);
  background: var(--primary-muted);
}

.resource-panel {
  display: none;
}

.resource-panel--active {
  display: block;
}

.resource-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: var(--space-4);
}

.resource-col {
  min-width: 0;
}

.resource-tree-col {
  border-right: var(--border-subtle);
  padding-right: var(--space-4);
}

.resource-tree {
  background: var(--bg-deep);
  border: var(--border-subtle);
  border-radius: var(--radius-md);
  padding: var(--space-3);
  min-height: 420px;
  max-height: 60vh;
  overflow: auto;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.8;
}

.resource-editor {
  min-height: 50vh;
  font-family: var(--font-mono);
  font-size: 13px;
}

/* ── Context Menu ── */
.context-menu {
  position: fixed;
  z-index: var(--z-context);
  border: var(--glass-border);
  border-radius: var(--radius-md);
  background: var(--bg-elevated);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-lg);
  padding: var(--space-1);
  min-width: 180px;
  display: none;
}

.context-menu:not([aria-hidden="true"]) {
  display: flex;
  flex-direction: column;
  gap: 1px;
}

.context-menu button {
  width: 100%;
  padding: 8px 14px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--text-secondary);
  font-family: var(--font-sans);
  font-size: 13px;
  text-align: left;
  transition: all var(--transition-fast);
}

.context-menu button:hover {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
}

/* ── Pagination ── */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-3);
  font-size: 13px;
  color: var(--text-muted);
}

.pagination .btn:disabled {
  opacity: 0.25;
  pointer-events: none;
}

/* ── Muted ── */
.muted {
  color: var(--text-muted);
  font-style: italic;
  text-align: center;
  padding: var(--space-6) 0;
}

/* ── Toast Container ── */
.toast-container {
  position: fixed;
  top: var(--space-4);
  right: var(--space-4);
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  pointer-events: none;
}

/* ── Animations — defined in theme.css (no duplicates) ── */

/* ── Setup Wizard ── */
.setup-steps {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.setup-card {
  background: var(--bg-card);
  border: var(--border-subtle);
  border-radius: var(--radius-lg);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
}

.setup-card h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
}

.setup-card--done {
  border-color: rgba(34,197,94,0.3);
  background: rgba(34,197,94,0.05);
  opacity: 0.82;
}

.setup-card--done h3 {
  color: #22c55e;
}

/* ── Form group (shared: setup wizard, campaigns, etc.) ── */
.form-group {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}

.form-group label {
  font-size: 12px;
  font-weight: 500;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

/* ── Responsive: Tablet (≤1024px) ── */
@media (max-width: 1024px) {
  .app {
    grid-template-columns: 1fr;
  }

  .sidebar {
    position: static;
    height: auto;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-4);
  }

  .nav {
    flex-direction: row;
  }

  .sidebar__footer {
    display: none;
  }
}

/* ── Responsive: Mobile (≤768px) ── */
@media (max-width: 768px) {
  .main {
    padding: var(--space-6);
  }

  .header {
    flex-direction: column;
    align-items: flex-start;
  }

  .header__actions {
    width: 100%;
    flex-direction: column;
  }

  .btn {
    width: 100%;
  }

  .card__header {
    flex-direction: column;
    align-items: flex-start;
  }

  .controls {
    width: 100%;
    flex-direction: column;
    align-items: stretch;
  }

  .form-row,
  .form-grid,
  .form-grid--campaign {
    grid-template-columns: 1fr;
  }

  .inline-picker,
  .resource-layout {
    grid-template-columns: 1fr;
  }

  .resource-tree {
    min-height: 420px;
    max-height: 60vh;
  }

  .pod-controls {
    flex-direction: column;
    align-items: stretch;
  }

  .pod-controls input {
    width: 100%;
  }

  .pod-controls select {
    width: 100%;
    min-width: 100%;
    max-width: 100%;
  }

  .table {
    min-width: 640px;
  }

  .docs-layout {
    grid-template-columns: 1fr;
    height: auto;
  }

  .docs-list-wrap {
    border-right: 0;
    border-bottom: var(--border-subtle);
    padding: var(--space-2) 0;
  }

  .form-row--crm-bulk {
    grid-template-columns: 1fr;
  }

  .lead-panel {
    top: var(--space-2);
    right: var(--space-2);
    width: calc(100vw - 16px);
    max-height: calc(100vh - 16px);
  }

  .runtime-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 1200px) {
  .form-row--calls {
    grid-template-columns: repeat(3, minmax(160px, 1fr));
  }
}
