/*
 * Global design-system styles for aistockrobotA.
 * These component classes (.btn, .card, .input, .loading, .badge) and the
 * supplementary color utilities are referenced across every page but were
 * absent from the compiled Tailwind output, so they are defined here in plain
 * CSS to restore the intended styling on the deployed site.
 */

:root {
  --color-primary-50: #eff6ff;
  --color-primary-100: #dbeafe;
  --color-primary-500: #3b82f6;
  --color-primary-600: #2563eb;
  --color-primary-700: #1d4ed8;
  --color-primary-800: #1e40af;
  --color-success-600: #16a34a;
  --color-success-700: #15803d;
  --color-danger-600: #dc2626;
  --color-danger-700: #b91c1c;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  border-radius: 0.5rem;
  border: 1px solid transparent;
  font-weight: 500;
  font-size: 0.875rem;
  line-height: 1.25rem;
  text-decoration: none;
  cursor: pointer;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}
.btn:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.4);
}
.btn:disabled,
.btn[disabled] {
  opacity: 0.6;
  cursor: not-allowed;
}
.btn-primary {
  background-color: var(--color-primary-600);
  color: #ffffff;
}
.btn-primary:hover {
  background-color: var(--color-primary-700);
  color: #ffffff;
}
.btn-secondary {
  background-color: #ffffff;
  color: #374151;
  border-color: #d1d5db;
}
.btn-secondary:hover {
  background-color: #f9fafb;
}
.btn-success {
  background-color: var(--color-success-600);
  color: #ffffff;
}
.btn-success:hover {
  background-color: var(--color-success-700);
}
.btn-danger {
  background-color: var(--color-danger-600);
  color: #ffffff;
}
.btn-danger:hover {
  background-color: var(--color-danger-700);
}
.btn-lg {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  line-height: 1.5rem;
}
.btn-sm {
  padding: 0.25rem 0.75rem;
  font-size: 0.75rem;
  line-height: 1rem;
}

/* ---------- Cards ---------- */
.card {
  background-color: #ffffff;
  border: 1px solid #f3f4f6;
  border-radius: 0.75rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1), 0 1px 2px rgba(0, 0, 0, 0.06);
  overflow: hidden;
}
.card-header {
  padding: 1.25rem 1.5rem;
  border-bottom: 1px solid #f3f4f6;
}
.card-body {
  padding: 1.5rem;
}
.card-footer {
  padding: 1.25rem 1.5rem;
  border-top: 1px solid #f3f4f6;
}

/* ---------- Form inputs ---------- */
.input {
  display: block;
  width: 100%;
  padding: 0.5rem 0.75rem;
  border: 1px solid #d1d5db;
  border-radius: 0.5rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  color: #111827;
  background-color: #ffffff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}
.input::placeholder {
  color: #9ca3af;
}
.input:focus {
  outline: none;
  border-color: var(--color-primary-500);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.25);
}

/* ---------- Loading spinner ---------- */
.loading {
  display: inline-block;
  border: 2px solid #e5e7eb;
  border-top-color: var(--color-primary-600);
  border-radius: 9999px;
  animation: spin 0.6s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

/* ---------- Badge ---------- */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 0.125rem 0.625rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1rem;
}

/* ---------- Supplementary color utilities missing from compiled CSS ---------- */
.bg-success-50 { background-color: #f0fdf4; }
.bg-success-100 { background-color: #dcfce7; }
.bg-danger-50 { background-color: #fef2f2; }
.border-danger-200 { border-color: #fecaca; }
.border-success-200 { border-color: #bbf7d0; }
.text-danger-700 { color: #b91c1c; }
.text-success-600 { color: #16a34a; }
.text-success-700 { color: #15803d; }
