/* ================================================================
   SELLGENIUS.AI — COMPONENTS
   components.css

   Shared component styles: buttons, badges, tables, modals.
   ================================================================ */

/* ── BUTTONS ── */
.btn-primary {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 8px 16px;
  background: linear-gradient(135deg, #7c3aed, #a855f7);
  border: none; border-radius: 9px;
  color: #fff; font-size: 13px; font-weight: 700;
  cursor: pointer; font-family: inherit;
  transition: all .15s;
  white-space: nowrap;
}
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 4px 16px rgba(124,58,237,.4); }

.btn-ghost {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 9px;
  color: rgba(255,255,255,.6); font-size: 13px; font-weight: 600;
  cursor: pointer; font-family: inherit;
  transition: all .15s;
  white-space: nowrap;
}
.btn-ghost:hover { background: rgba(255,255,255,.09); color: #fff; }

.btn-danger {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 7px 14px;
  background: rgba(239,68,68,.1);
  border: 1px solid rgba(239,68,68,.25);
  border-radius: 9px;
  color: #f87171; font-size: 13px; font-weight: 600;
  cursor: pointer; font-family: inherit;
  transition: all .15s;
}
.btn-danger:hover { background: rgba(239,68,68,.2); }

/* ── BADGES ── */
.badge {
  display: inline-block;
  padding: 2px 8px; border-radius: 4px;
  font-size: 10.5px; font-weight: 700;
}
.badge-green { background: rgba(52,211,153,.12); color: #34d399; }
.badge-red   { background: rgba(248,113,113,.12); color: #f87171; }
.badge-yellow{ background: rgba(252,211,77,.1);   color: #fcd34d; }
.badge-purple{ background: rgba(124,58,237,.15);  color: #c4b5fd; }
.badge-blue  { background: rgba(6,182,212,.1);    color: #67e8f9; }

/* ── TABLES ── */
.data-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 12.5px;
}
.data-table th {
  font-size: 10px; font-weight: 700;
  text-transform: uppercase; letter-spacing: .08em;
  color: rgba(255,255,255,.3);
  padding: 8px 12px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  text-align: left;
  white-space: nowrap;
}
.data-table td {
  padding: 10px 12px;
  border-bottom: 1px solid rgba(255,255,255,.04);
  vertical-align: middle;
}
.data-table tr:hover td { background: rgba(255,255,255,.02); }
.data-table .r { text-align: right; }
.data-table .c { text-align: center; }

/* ── MODALS ── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.6);
  backdrop-filter: blur(4px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal {
  background: #111128;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 16px;
  padding: 24px;
  width: 100%;
  max-width: 480px;
  max-height: 90vh;
  overflow-y: auto;
}

/* ── FORMS ── */
.form-input {
  width: 100%;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  padding: 9px 12px;
  color: #fff; font-size: 13px; font-family: inherit;
  outline: none;
  transition: border-color .15s;
}
.form-input:focus { border-color: rgba(124,58,237,.5); }

/* ── KPI TILES ── */
.kpi-tile {
  background: rgba(22,22,42,.8);
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  padding: 14px 16px;
  cursor: pointer;
  transition: border-color .15s;
}
.kpi-tile:hover { border-color: rgba(124,58,237,.3); }

/* ── EMPTY STATE ── */
.empty-state {
  padding: 48px 24px;
  text-align: center;
  color: rgba(255,255,255,.3);
}
.empty-state h4 { font-size: 15px; margin-bottom: 6px; color: rgba(255,255,255,.5); }
.empty-state p  { font-size: 13px; }

/* ── TOAST ── */
.sg-toast {
  position: fixed; bottom: 24px; right: 24px;
  background: #1a1a2e;
  border: 1px solid rgba(124,58,237,.3);
  border-radius: 11px;
  padding: 11px 18px;
  font-size: 13px; color: #c4b5fd; font-weight: 600;
  z-index: 9999;
  box-shadow: 0 8px 32px rgba(0,0,0,.5);
  animation: toastIn .2s ease;
}
@keyframes toastIn {
  from { opacity:0; transform: translateY(8px); }
  to   { opacity:1; transform: translateY(0); }
}
