/* PeePloYee Enhanced Styles */

:root {
  --primary-color: #2563eb;
  --primary-dark: #1d4ed8;
  --primary-light: #3b82f6;
  --secondary-color: #7c3aed;
  --secondary-dark: #6d28d9;
  --success-color: #10b981;
  --success-light: #34d399;
  --danger-color: #ef4444;
  --danger-light: #f87171;
  --warning-color: #f59e0b;
  --warning-light: #fbbf24;
  --info-color: #3b82f6;
  --dark-color: #1f2937;
  --gray-50: #f9fafb;
  --gray-100: #f3f4f6;
  --gray-200: #e5e7eb;
  --gray-300: #d1d5db;
  --gray-400: #9ca3af;
  --gray-500: #6b7280;
  --gray-600: #4b5563;
  --gray-700: #374151;
  --gray-800: #1f2937;
  --gray-900: #111827;
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
  
  --transition-fast: 150ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-base: 300ms cubic-bezier(0.4, 0, 0.2, 1);
  --transition-slow: 500ms cubic-bezier(0.4, 0, 0.2, 1);
  
  /* Background colors */
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --bg-tertiary: #f3f4f6;
  
  /* Text colors */
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --text-tertiary: #9ca3af;
  
  /* Border colors */
  --border-color: #e5e7eb;
  --border-color-dark: #d1d5db;
}

/* Dark Mode Theme */
[data-theme="dark"] {
  --primary-color: #3b82f6;
  --primary-dark: #2563eb;
  --primary-light: #60a5fa;
  --gray-50: #1f2937;
  --gray-100: #374151;
  --gray-200: #4b5563;
  --gray-300: #6b7280;
  --gray-400: #9ca3af;
  --gray-500: #d1d5db;
  --gray-600: #e5e7eb;
  --gray-700: #f3f4f6;
  --gray-800: #f9fafb;
  --gray-900: #ffffff;
  
  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.3);
  --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.3), 0 1px 2px 0 rgba(0, 0, 0, 0.2);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.3), 0 2px 4px -1px rgba(0, 0, 0, 0.2);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.3), 0 4px 6px -2px rgba(0, 0, 0, 0.2);
  --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.3), 0 10px 10px -5px rgba(0, 0, 0, 0.2);
  
  /* Background colors for dark mode */
  --bg-primary: #1f2937;
  --bg-secondary: #111827;
  --bg-tertiary: #374151;
  
  /* Text colors for dark mode */
  --text-primary: #f9fafb;
  --text-secondary: #d1d5db;
  --text-tertiary: #9ca3af;
  
  /* Border colors for dark mode */
  --border-color: #374151;
  --border-color-dark: #4b5563;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color: var(--text-primary);
  background-color: var(--bg-secondary);
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  transition: background-color var(--transition-base), color var(--transition-base);
}

/* Default headings - but allow utility classes to override */
h1:not([class*="text-"]), 
h2:not([class*="text-"]), 
h3:not([class*="text-"]), 
h4:not([class*="text-"]), 
h5:not([class*="text-"]), 
h6:not([class*="text-"]) {
  color: var(--text-primary);
}

p:not([class*="text-"]) {
  color: var(--text-secondary);
}

/* ============================================
   BUTTONS
   ============================================ */

.btn {
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all var(--transition-base);
  border: none;
  cursor: pointer;
  font-size: 0.875rem;
  line-height: 1.25rem;
  white-space: nowrap;
  position: relative;
}

.btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  pointer-events: none;
}

.btn.loading {
  pointer-events: none;
}

.btn.loading::after {
  content: '';
  position: absolute;
  width: 16px;
  height: 16px;
  top: 50%;
  left: 50%;
  margin-left: -8px;
  margin-top: -8px;
  border: 2px solid currentColor;
  border-radius: 50%;
  border-top-color: transparent;
  animation: spin 0.6s linear infinite;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

.btn-primary {
  background-color: var(--primary-color);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-primary:hover:not(:disabled) {
  background-color: var(--primary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-primary:active:not(:disabled) {
  transform: translateY(0);
  box-shadow: var(--shadow-sm);
}

.btn-secondary {
  background-color: var(--secondary-color);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-secondary:hover:not(:disabled) {
  background-color: var(--secondary-dark);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-success {
  background-color: var(--success-color);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-success:hover:not(:disabled) {
  background-color: #059669;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-danger {
  background-color: var(--danger-color);
  color: white;
  box-shadow: var(--shadow-sm);
}

.btn-danger:hover:not(:disabled) {
  background-color: #dc2626;
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-outline {
  background-color: transparent;
  color: var(--primary-color);
  border: 2px solid var(--primary-color);
}

.btn-outline:hover:not(:disabled) {
  background-color: var(--primary-color);
  color: white;
}

.btn-ghost {
  background-color: transparent;
  color: var(--gray-700);
}

.btn-ghost:hover:not(:disabled) {
  background-color: var(--gray-100);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.8125rem;
}

.btn-lg {
  padding: 1rem 2rem;
  font-size: 1rem;
}

.btn-icon {
  padding: 0.5rem;
  width: 2.5rem;
  height: 2.5rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* ============================================
   CARDS
   ============================================ */

.card {
  background: var(--bg-primary);
  border-radius: 0.75rem;
  box-shadow: var(--shadow);
  padding: 1.5rem;
  transition: all var(--transition-base);
  border: 1px solid var(--border-color);
}

.card:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.card-header {
  padding-bottom: 1rem;
  margin-bottom: 1rem;
  border-bottom: 1px solid var(--gray-200);
}

.card-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--gray-900);
  margin: 0;
}

.card-body {
  padding: 0;
}

.card-footer {
  padding-top: 1rem;
  margin-top: 1rem;
  border-top: 1px solid var(--gray-200);
}

.card-stat {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.card-stat-value {
  font-size: 2rem;
  font-weight: 700;
  color: var(--gray-900);
  line-height: 1;
}

.card-stat-label {
  font-size: 0.875rem;
  color: var(--gray-500);
  font-weight: 500;
}

.card-stat-change {
  font-size: 0.875rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.card-stat-change.positive {
  color: var(--success-color);
}

.card-stat-change.negative {
  color: var(--danger-color);
}

/* ============================================
   FORMS
   ============================================ */

.form-group {
  margin-bottom: 1.5rem;
}

.form-label {
  display: block;
  font-weight: 600;
  margin-bottom: 0.5rem;
  color: var(--gray-700);
  font-size: 0.875rem;
}

.form-input,
.form-select,
.form-textarea {
  width: 100%;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  font-size: 1rem;
  transition: all var(--transition-fast);
  background-color: var(--bg-primary);
  color: var(--text-primary);
}

.form-input:focus,
.form-select:focus,
.form-textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-input:disabled,
.form-select:disabled,
.form-textarea:disabled {
  background-color: var(--bg-secondary);
  cursor: not-allowed;
  opacity: 0.6;
}

.form-input.error,
.form-select.error,
.form-textarea.error {
  border-color: var(--danger-color);
}

.form-input.error:focus,
.form-select.error:focus,
.form-textarea.error:focus {
  box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.form-error {
  color: var(--danger-color);
  font-size: 0.875rem;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.form-helper {
  color: var(--gray-500);
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

.form-textarea {
  min-height: 100px;
  resize: vertical;
}

/* ============================================
   LOADING STATES
   ============================================ */

.spinner {
  border: 3px solid var(--gray-200);
  border-top: 3px solid var(--primary-color);
  border-radius: 50%;
  width: 40px;
  height: 40px;
  animation: spin 1s linear infinite;
}

.spinner-sm {
  width: 20px;
  height: 20px;
  border-width: 2px;
}

.spinner-lg {
  width: 60px;
  height: 60px;
  border-width: 4px;
}

@keyframes spin {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* Skeleton Loading */
.skeleton {
  background: linear-gradient(
    90deg,
    var(--gray-200) 0%,
    var(--gray-300) 50%,
    var(--gray-200) 100%
  );
  background-size: 200% 100%;
  animation: skeleton-loading 1.5s ease-in-out infinite;
  border-radius: 0.5rem;
}

@keyframes skeleton-loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

.skeleton-text {
  height: 1rem;
  margin-bottom: 0.5rem;
}

.skeleton-text:last-child {
  width: 60%;
}

.skeleton-title {
  height: 1.5rem;
  width: 40%;
  margin-bottom: 1rem;
}

.skeleton-avatar {
  width: 3rem;
  height: 3rem;
  border-radius: 50%;
}

.skeleton-card {
  height: 200px;
  border-radius: 0.75rem;
}

/* Loading Overlay */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  animation: fadeIn 0.2s ease-out;
}

.loading-content {
  text-align: center;
}

.loading-text {
  margin-top: 1rem;
  color: var(--gray-600);
  font-weight: 500;
}

/* ============================================
   BADGES & TAGS
   ============================================ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1;
}

.badge-primary {
  background-color: #dbeafe;
  color: var(--primary-color);
}

.badge-success {
  background-color: #d1fae5;
  color: var(--success-color);
}

.badge-warning {
  background-color: #fef3c7;
  color: #d97706;
}

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

.badge-info {
  background-color: #dbeafe;
  color: var(--info-color);
}

.badge-gray {
  background-color: var(--gray-200);
  color: var(--gray-700);
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */

.toast-container {
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 400px;
}

.toast {
  background: var(--bg-primary);
  border-radius: 0.5rem;
  box-shadow: var(--shadow-xl);
  padding: 1rem 1.25rem;
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  border-left: 4px solid;
  animation: slideInRight 0.3s ease-out;
  min-width: 300px;
}

.toast.toast-success {
  border-left-color: var(--success-color);
}

.toast.toast-error {
  border-left-color: var(--danger-color);
}

.toast.toast-warning {
  border-left-color: var(--warning-color);
}

.toast.toast-info {
  border-left-color: var(--info-color);
}

.toast-icon {
  flex-shrink: 0;
  width: 1.25rem;
  height: 1.25rem;
}

.toast-content {
  flex: 1;
}

.toast-title {
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.toast-message {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.toast-close {
  flex-shrink: 0;
  background: none;
  border: none;
  color: var(--gray-400);
  cursor: pointer;
  padding: 0;
  font-size: 1.25rem;
  line-height: 1;
  transition: color var(--transition-fast);
}

.toast-close:hover {
  color: var(--gray-600);
}

@keyframes slideInRight {
  from {
    opacity: 0;
    transform: translateX(100%);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

@keyframes slideOutRight {
  from {
    opacity: 1;
    transform: translateX(0);
  }
  to {
    opacity: 0;
    transform: translateX(100%);
  }
}

.toast.toast-exit {
  animation: slideOutRight 0.3s ease-out forwards;
}

/* ============================================
   TABLES
   ============================================ */

.table-container {
  overflow-x: auto;
  border-radius: 0.75rem;
  box-shadow: var(--shadow);
  border: 1px solid var(--border-color);
}

.table {
  width: 100%;
  border-collapse: collapse;
  background: var(--bg-primary);
}

.table th,
.table td {
  padding: 1rem;
  text-align: left;
  border-bottom: 1px solid var(--border-color);
}

.table th {
  background-color: var(--bg-secondary);
  font-weight: 600;
  color: var(--text-secondary);
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.table tbody tr {
  transition: background-color var(--transition-fast);
}

.table tbody tr:hover {
  background-color: var(--bg-secondary);
}

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

/* ============================================
   MODALS
   ============================================ */

.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9998;
  animation: fadeIn 0.2s ease-out;
  padding: 1rem;
  overflow-y: auto;
}

.modal {
  background: var(--bg-primary);
  border-radius: 0.75rem;
  box-shadow: var(--shadow-xl);
  width: 100%;
  max-width: 500px;
  max-height: 90vh;
  overflow-y: auto;
  animation: scaleIn 0.2s ease-out;
}

.modal-header {
  padding: 1.5rem;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.modal-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0;
}

.modal-close {
  background: none;
  border: none;
  color: var(--gray-400);
  cursor: pointer;
  padding: 0;
  font-size: 1.5rem;
  line-height: 1;
  transition: color var(--transition-fast);
}

.modal-close:hover {
  color: var(--gray-600);
}

.modal-body {
  padding: 1.5rem;
}

.modal-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border-color);
  display: flex;
  gap: 0.75rem;
  justify-content: flex-end;
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* ============================================
   PROGRESS BARS
   ============================================ */

.progress-bar {
  width: 100%;
  height: 0.5rem;
  background-color: var(--gray-200);
  border-radius: 9999px;
  overflow: hidden;
}

.progress-bar-fill {
  height: 100%;
  background-color: var(--primary-color);
  transition: width var(--transition-base);
  border-radius: 9999px;
}

.progress-bar-fill.success {
  background-color: var(--success-color);
}

.progress-bar-fill.warning {
  background-color: var(--warning-color);
}

.progress-bar-fill.danger {
  background-color: var(--danger-color);
}

/* ============================================
   AVATARS
   ============================================ */

.avatar {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  color: white;
  background-color: var(--primary-color);
  font-size: 1rem;
}

.avatar-sm {
  width: 2rem;
  height: 2rem;
  font-size: 0.75rem;
}

.avatar-lg {
  width: 3.5rem;
  height: 3.5rem;
  font-size: 1.25rem;
}

.avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 50%;
}

/* ============================================
   NAVBAR & SIDEBAR
   ============================================ */

.navbar {
  background: var(--bg-primary);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid var(--border-color);
}

.sidebar {
  background: var(--bg-primary);
  border-right: 1px solid var(--border-color);
  height: 100vh;
  position: sticky;
  top: 0;
  overflow-y: auto;
}

.sidebar-nav {
  padding: 1rem;
}

.sidebar-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  color: var(--text-secondary);
  text-decoration: none;
  border-radius: 0.5rem;
  transition: all var(--transition-fast);
  margin-bottom: 0.25rem;
  font-weight: 500;
}

.sidebar-item:hover {
  background-color: var(--bg-secondary);
  color: var(--text-primary);
}

.sidebar-item.active {
  background-color: var(--primary-color);
  color: white;
}

.sidebar-item i {
  width: 1.25rem;
  text-align: center;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

/* Mobile First - Extra Small devices (phones, less than 640px) */
@media (max-width: 639px) {
  .card {
    padding: 1rem;
  }
  
  .card-stat-value {
    font-size: 1.5rem;
  }
  
  .btn {
    padding: 0.625rem 1.25rem;
    font-size: 0.8125rem;
  }
  
  .modal {
    max-width: calc(100vw - 2rem);
    margin: 1rem;
  }
  
  .toast-container {
    left: 1rem;
    right: 1rem;
    max-width: none;
  }
  
  .toast {
    min-width: auto;
  }
  
  .table th,
  .table td {
    padding: 0.75rem 0.5rem;
    font-size: 0.875rem;
  }
  
  .sidebar {
    position: fixed;
    left: -100%;
    transition: left var(--transition-base);
    z-index: 100;
  }
  
  .sidebar.open {
    left: 0;
  }
}

/* Small devices (tablets, 640px and up) */
@media (min-width: 640px) {
  .modal {
    max-width: 500px;
  }
}

/* Medium devices (tablets, 768px and up) */
@media (min-width: 768px) {
  .card-stat-value {
    font-size: 2.25rem;
  }
  
  .modal-lg {
    max-width: 768px;
  }
}

/* Large devices (desktops, 1024px and up) */
@media (min-width: 1024px) {
  .container {
    max-width: 1024px;
  }
  
  .modal-xl {
    max-width: 1024px;
  }
}

/* Extra large devices (large desktops, 1280px and up) */
@media (min-width: 1280px) {
  .container {
    max-width: 1280px;
  }
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

/* Dark Mode Toggle */
.theme-toggle {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  width: 3.5rem;
  height: 3.5rem;
  border-radius: 50%;
  background: var(--bg-primary);
  border: 2px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-base);
  z-index: 100;
}

.theme-toggle:hover {
  transform: scale(1.1) rotate(10deg);
  box-shadow: var(--shadow-xl);
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.theme-toggle i {
  font-size: 1.25rem;
  transition: transform var(--transition-base);
}

.theme-toggle:hover i {
  transform: rotate(-10deg);
}

@media (max-width: 640px) {
  .theme-toggle {
    bottom: 1rem;
    right: 1rem;
    width: 3rem;
    height: 3rem;
  }
  
  .theme-toggle i {
    font-size: 1rem;
  }
}

.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.font-bold { font-weight: 700; }
.font-semibold { font-weight: 600; }
.font-medium { font-weight: 500; }

.text-xs { font-size: 0.75rem; }
.text-sm { font-size: 0.875rem; }
.text-base { font-size: 1rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }

.text-primary { color: var(--primary-color); }
.text-success { color: var(--success-color); }
.text-danger { color: var(--danger-color); }
.text-warning { color: var(--warning-color); }
.text-gray-500 { color: var(--gray-500); }
.text-gray-600 { color: var(--gray-600); }
.text-gray-700 { color: var(--gray-700); }
.text-gray-900 { color: var(--gray-900); }

.bg-primary { background-color: var(--primary-color); }
.bg-success { background-color: var(--success-color); }
.bg-danger { background-color: var(--danger-color); }
.bg-warning { background-color: var(--warning-color); }
.bg-gray-50 { background-color: var(--gray-50); }
.bg-gray-100 { background-color: var(--gray-100); }

.rounded { border-radius: 0.25rem; }
.rounded-md { border-radius: 0.375rem; }
.rounded-lg { border-radius: 0.5rem; }
.rounded-xl { border-radius: 0.75rem; }
.rounded-full { border-radius: 9999px; }

.shadow-sm { box-shadow: var(--shadow-sm); }
.shadow { box-shadow: var(--shadow); }
.shadow-md { box-shadow: var(--shadow-md); }
.shadow-lg { box-shadow: var(--shadow-lg); }
.shadow-xl { box-shadow: var(--shadow-xl); }

.transition { transition: all var(--transition-base); }
.transition-fast { transition: all var(--transition-fast); }

.line-clamp-1 {
  display: -webkit-box;
  -webkit-line-clamp: 1;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-2 {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.line-clamp-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.truncate {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.fade-in {
  animation: fadeIn 0.5s ease-out;
}

.slide-in-right {
  animation: slideInRight 0.5s ease-out;
}

/* Hide scrollbar but keep functionality */
.scrollbar-hide {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.scrollbar-hide::-webkit-scrollbar {
  display: none;
}

/* ============================================
   EMPTY STATES
   ============================================ */

.empty-state {
  text-align: center;
  padding: 3rem 1.5rem;
}

.empty-state-icon {
  font-size: 3rem;
  color: var(--gray-400);
  margin-bottom: 1rem;
}

.empty-state-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--gray-900);
  margin-bottom: 0.5rem;
}

.empty-state-description {
  color: var(--gray-500);
  margin-bottom: 1.5rem;
}

/* ============================================
   DRAG & DROP STYLES
   ============================================ */

.dragging {
  opacity: 0.5;
  cursor: move !important;
  transform: scale(0.98);
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.drag-over {
  border: 2px dashed var(--primary-color) !important;
  background-color: rgba(37, 99, 235, 0.05);
  transition: all 0.2s ease;
}

.drag-handle {
  cursor: move;
  color: var(--gray-400);
  transition: color 0.2s ease;
}

.drag-handle:hover {
  color: var(--primary-color);
}

/* Sortable table row styles */
tr[draggable="true"] {
  transition: all 0.2s ease;
}

tr[draggable="true"]:hover {
  background-color: var(--gray-50);
}

tr.dragging {
  background-color: var(--gray-100);
  box-shadow: var(--shadow-lg);
}

tr.drag-over {
  border-top: 3px solid var(--primary-color);
}

/* Sortable widget styles */
.widget {
  transition: all 0.3s ease;
}

.widget.dragging {
  box-shadow: var(--shadow-xl);
  transform: rotate(2deg) scale(1.02);
}

.widget.drag-over {
  transform: scale(1.05);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.3);
}

.widget-header {
  cursor: move;
  user-select: none;
}

/* Chart containers */
.chart-container {
  position: relative;
  height: 300px;
  width: 100%;
  padding: 1rem;
}

.chart-card {
  background: white;
  border-radius: 0.75rem;
  padding: 1.5rem;
  box-shadow: var(--shadow);
  margin-bottom: 1.5rem;
}

.chart-card .chart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--border-color);
}

.chart-card .chart-title {
  font-size: 1.125rem;
  font-weight: 600;
  color: var(--text-primary);
}

.chart-card .chart-subtitle {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-top: 0.25rem;
}

/* Filter dropdown styles */
.filter-dropdown-item:hover {
  background-color: var(--gray-50);
}

.filter-tag {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.375rem 0.75rem;
  background: var(--primary-color);
  color: white;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 500;
}

.filter-tag button {
  background: none;
  border: none;
  color: white;
  cursor: pointer;
  padding: 0;
  margin-left: 0.25rem;
  opacity: 0.8;
  transition: opacity 0.2s;
}

.filter-tag button:hover {
  opacity: 1;
}

.filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  align-items: center;
  padding: 1rem;
  background: var(--bg-secondary);
  border-radius: 0.5rem;
  margin-bottom: 1.5rem;
}

.filter-group {
  flex: 1;
  min-width: 200px;
}

.filter-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-primary);
  margin-bottom: 0.5rem;
}

/* Active filters display */
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1rem;
}

.clear-filters-btn {
  background: none;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 0.375rem 0.75rem;
  border-radius: 0.375rem;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s;
}

.clear-filters-btn:hover {
  background: var(--danger-color);
  border-color: var(--danger-color);
  color: white;
}

/* ============================================
   LANDING PAGE STYLES
   ============================================ */

.stat-counter {
  font-size: 3rem;
  font-weight: 700;
  color: var(--primary-color);
  line-height: 1;
}

/* Gradient text */
.gradient-bg {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bg-clip-text {
  -webkit-background-clip: text;
  background-clip: text;
}

.text-transparent {
  color: transparent;
}

/* Ensure white text stays white */
.text-white {
  color: #ffffff !important;
}

/* Ensure colored backgrounds have proper text colors */
section.gradient-bg h1,
section.gradient-bg h2,
section.gradient-bg h3,
section.gradient-bg p {
  color: inherit;
}

/* Footer text colors */
.footer {
  background-color: #1f2937;
  color: #ffffff;
  padding: 3rem 0;
}

.footer h3,
.footer h4 {
  color: #ffffff;
}

.footer p {
  color: #d1d5db;
}

.footer a {
  color: #d1d5db;
  text-decoration: none;
  transition: color 0.2s;
}

.footer a:hover {
  color: #ffffff;
}
