/* 
 * Modern Theme for EffFactor
 * Version: 1.0
 * Created: May 2025
 * Enhanced styling for Django 5 + Python 3.12 upgrade
 */

:root {
  /* Color palette */
  --primary: #2c3e50;
  --primary-light: #34495e;
  --secondary: #3498db;
  --secondary-light: #5dade2;
  --accent: #1abc9c;
  --accent-light: #48c9b0;
  --success: #2ecc71;
  --warning: #f39c12;
  --danger: #e74c3c;
  --light: #ecf0f1;
  --dark: #2c3e50;
  --gray: #95a5a6;
  --gray-light: #bdc3c7;
  
  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 4px 8px rgba(0,0,0,0.1);
  --shadow-lg: 0 10px 20px rgba(0,0,0,0.15);
  
  /* Transitions */
  --transition-fast: all 0.2s ease;
  --transition-normal: all 0.3s ease;
  --transition-slow: all 0.5s ease;
  
  /* Border radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-xl: 20px;
  --radius-full: 50%;
}

/* ===== Base Styles ===== */
body {
  font-family: 'Roboto', 'Segoe UI', Arial, sans-serif;
  color: #333;
  background-color: #f8f9fa;
  transition: var(--transition-normal);
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 500;
  margin-bottom: 1rem;
  color: var(--primary);
}

h1 {
  font-size: 2.5rem;
  font-weight: 300;
  letter-spacing: -0.5px;
}

a {
  color: var(--secondary);
  transition: var(--transition-fast);
  text-decoration: none;
}

a:hover, a:focus {
  color: var(--secondary-light);
  text-decoration: none;
}

/* ===== Layout Improvements ===== */
#wrapper {
  display: flex;
  min-height: 100vh;
  transition: var(--transition-normal);
}

#sidebar-wrapper {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  box-shadow: var(--shadow-md);
  transition: var(--transition-normal);
  z-index: 1000;
}

#page-content-wrapper {
  flex: 1;
  background-color: #f8f9fa;
  transition: var(--transition-normal);
}

/* ===== Sidebar Styling ===== */
.sidebar-nav {
  margin-top: 0;
  padding: 0;
}

.sidebar-nav li {
  transition: var(--transition-fast);
}

.sidebar-nav li a {
  display: flex;
  align-items: center;
  padding: 15px 20px;
  color: rgba(255, 255, 255, 0.8);
  font-weight: 400;
  transition: var(--transition-fast);
}

.sidebar-nav li a:hover,
.sidebar-nav li a.active {
  background-color: rgba(255, 255, 255, 0.1);
  color: #fff;
  border-left: 4px solid var(--accent);
}

.sidebar-nav li a .glyphicon,
.sidebar-nav li a .fa {
  margin-right: 15px;
  width: 20px;
  text-align: center;
  font-size: 16px;
}

/* ===== Cards & Panels ===== */
.panel {
  border: none;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
  overflow: hidden;
  margin-bottom: 24px;
}

.panel:hover {
  box-shadow: var(--shadow-md);
}

.panel-heading {
  border-bottom: none;
  padding: 20px;
  background: white;
}

.panel-default > .panel-heading {
  background-color: white;
  border-color: #f1f1f1;
  color: var(--primary);
  font-weight: 500;
}

.panel-body {
  padding: 20px;
}

/* ===== Tables ===== */
.table {
  margin-bottom: 0;
  border-collapse: separate;
  border-spacing: 0 8px;
  width: 100%;
}

.table > thead > tr > th {
  border: none;
  font-weight: 600;
  color: var(--primary);
  text-transform: uppercase;
  font-size: 12px;
  letter-spacing: 0.8px;
  padding: 15px 15px;
  background-color: #f8f9fa;
  position: relative;
}

.table > thead > tr > th:after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 15px;
  right: 15px;
  height: 2px;
  background: var(--secondary-light);
  transform: scaleX(0.3);
  transform-origin: left;
  transition: transform 0.3s ease;
}

.table > thead > tr > th:hover:after {
  transform: scaleX(1);
}

.table > tbody > tr {
  box-shadow: var(--shadow-sm);
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  background-color: white;
  margin-bottom: 8px;
}

.table > tbody > tr:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.table > tbody > tr > td {
  padding: 18px 15px;
  vertical-align: middle;
  border: none;
  position: relative;
  background-color: white;
}

.table > tbody > tr > td:first-child {
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.table > tbody > tr > td:last-child {
  border-top-right-radius: var(--radius-md);
  border-bottom-right-radius: var(--radius-md);
}

.table-striped > tbody > tr:nth-of-type(odd) {
  background-color: white;
}

.table-striped > tbody > tr:nth-of-type(odd) > td {
  background-color: white;
}

.table-striped > tbody > tr:nth-of-type(even) {
  background-color: white;
}

.table-hover > tbody > tr:hover > td {
  background-color: white;
}

/* Status colors */
.bg-success {
  position: relative;
  background-color: rgba(46, 204, 113, 0.05) !important;
  color: #27ae60;
}

.bg-success::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: #27ae60;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.bg-danger {
  position: relative;
  background-color: rgba(231, 76, 60, 0.05) !important;
  color: #c0392b;
}

.bg-danger::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: #c0392b;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.bg-warning {
  position: relative;
  background-color: rgba(243, 156, 18, 0.05) !important;
  color: #d35400;
}

.bg-warning::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: #d35400;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.bg-info {
  position: relative;
  background-color: rgba(52, 152, 219, 0.05) !important;
  color: #2980b9;
}

.bg-info::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: #2980b9;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

.bg-grey10 {
  position: relative;
  background-color: rgba(149, 165, 166, 0.05) !important;
  color: #7f8c8d;
}

.bg-grey10::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background-color: #95a5a6;
  border-top-left-radius: var(--radius-md);
  border-bottom-left-radius: var(--radius-md);
}

/* ===== Forms ===== */
.form-control {
  height: 42px;
  border-radius: var(--radius-sm);
  border: 1px solid #e0e0e0;
  box-shadow: none;
  transition: var(--transition-fast);
  font-size: 14px;
}

.form-control:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
}

.input-lg {
  height: 50px;
  font-size: 16px;
}

.select2-container--default .select2-selection--single {
  height: 42px;
  border-radius: var(--radius-sm);
  border: 1px solid #e0e0e0;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
  line-height: 42px;
  padding-left: 15px;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
  height: 40px;
}

/* ===== Buttons ===== */
.btn {
  border-radius: var(--radius-sm);
  font-weight: 500;
  padding: 8px 16px;
  transition: var(--transition-fast);
  text-transform: uppercase;
  font-size: 13px;
  letter-spacing: 0.5px;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 12px;
}

.btn-lg {
  padding: 12px 20px;
  font-size: 15px;
}

.btn-primary {
  background-color: var(--secondary);
  border-color: var(--secondary);
}

.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background-color: var(--secondary-light);
  border-color: var(--secondary-light);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.25);
}

.btn-success {
  background-color: var(--success);
  border-color: var(--success);
}

.btn-warning {
  background-color: var(--warning);
  border-color: var(--warning);
}

.btn-danger {
  background-color: var(--danger);
  border-color: var(--danger);
}

/* ===== Tabs ===== */
.nav-tabs {
  border-bottom: 2px solid #f1f1f1;
}

.nav-tabs > li > a {
  border: none;
  color: var(--gray);
  font-weight: 500;
  padding: 15px 20px;
  border-radius: 0;
  transition: var(--transition-fast);
}

.nav-tabs > li > a:hover {
  background-color: transparent;
  color: var(--primary);
}

.nav-tabs > li.active > a,
.nav-tabs > li.active > a:focus,
.nav-tabs > li.active > a:hover {
  border: none;
  color: var(--secondary);
  background-color: transparent;
  border-bottom: 2px solid var(--secondary);
  margin-bottom: -2px;
}

/* ===== Admin Page Specific ===== */
.admin-dashboard {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 25px;
  margin-bottom: 30px;
}

.admin-category {
  background: white;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  padding: 20px;
  transition: var(--transition-normal);
  position: relative;
  overflow: hidden;
  border-top: 4px solid var(--secondary);
}

.admin-category:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-5px);
}

.admin-category::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 150px;
  height: 150px;
  background: radial-gradient(circle at top right, rgba(52, 152, 219, 0.1), transparent 70%);
  z-index: 0;
  border-radius: 50%;
}

.admin-category h3 {
  margin-top: 0;
  margin-bottom: 20px;
  font-size: 18px;
  color: var(--primary);
  border-bottom: 1px solid #f1f1f1;
  padding-bottom: 12px;
  display: flex;
  align-items: center;
  position: relative;
  z-index: 1;
}

.admin-category h3::after {
  content: '';
  position: absolute;
  bottom: -1px;
  left: 0;
  width: 50px;
  height: 3px;
  background: var(--secondary);
  border-radius: var(--radius-sm);
}

.admin-category h3 i {
  margin-right: 10px;
  font-size: 22px;
  background: var(--secondary-light);
  color: white;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
}

.admin-links {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.admin-links a {
  display: flex;
  align-items: center;
  background-color: #f8f9fa;
  border-radius: var(--radius-md);
  padding: 12px 15px;
  color: var(--primary);
  transition: var(--transition-normal);
  font-size: 14px;
  margin-bottom: 8px;
  flex: 1 0 auto;
  min-width: 140px;
  max-width: 100%;
  position: relative;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(0,0,0,0.03);
}

.admin-links a:hover {
  background-color: var(--secondary);
  color: white;
  transform: translateY(-3px);
  box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.admin-links a::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 4px;
  height: 100%;
  background: var(--secondary);
  opacity: 0;
  transition: var(--transition-fast);
}

.admin-links a:hover::before {
  opacity: 1;
}

.admin-links a .glyphicon,
.admin-links a .fa {
  margin-right: 10px;
  font-size: 16px;
  min-width: 20px;
  text-align: center;
  transition: var(--transition-fast);
}

.admin-links a:hover .glyphicon,
.admin-links a:hover .fa {
  transform: scale(1.2);
}

/* Legacy shortcuts style for backward compatibility */
.shortcuts {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 8px;
  margin-bottom: 20px;
}

.shortcuts a {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  background-color: white;
  border-radius: var(--radius-md);
  padding: 10px 5px;
  color: var(--primary);
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
  height: 100px;
  font-size: 13px;
}

.shortcuts a:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  color: var(--secondary);
}

.shortcuts a .glyphicon,
.shortcuts a .fa {
  font-size: 32px;
  margin-bottom: 15px;
  color: var(--secondary);
}

/* ===== Donut Chart Progress Visualization ===== */
.donut-chart-container {
  position: relative;
  width: 80px;
  height: 80px;
  margin: 0 auto;
}

.donut-chart {
  position: relative;
  width: 100%;
  height: 100%;
}

.donut-chart .circle {
  width: 100%;
  height: 100%;
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  transform: rotate(-90deg);
  transform-origin: center;
}

.donut-chart .circle-bg {
  stroke: #f0f0f0;
}

.donut-chart .circle-progress {
  stroke: var(--secondary);
  stroke-dasharray: 0, 283; /* Initial state, 283 is approx 2*PI*45 (circumference of circle with r=45) */
  transition: stroke-dasharray 1.5s ease;
}

.donut-chart-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 18px;
  font-weight: 600;
  color: var(--primary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  width: 100%;
}

/* Gradient effect for the progress circle */
.donut-chart .circle-progress-gradient {
  stroke: url(#donutGradient);
}

/* Project List Item Styling */
.list-group-item {
  margin-bottom: 15px;
  border-radius: var(--radius-md) !important;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
  border: 1px solid #f1f1f1;
  padding: 20px;
}

.list-group-item:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
}

.project-actions {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.project-actions form {
  margin-bottom: 5px;
}

.project-actions .btn {
  width: 36px;
  height: 36px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-full);
  transition: var(--transition-fast);
}

.project-actions .btn:hover {
  transform: scale(1.1);
}

.project-customer {
  color: green;
  font-weight: 500;
}

.project-title {
  margin-top: 5px;
  margin-bottom: 10px;
  font-weight: 500;
}

/* ===== Projects Page Styling ===== */
.project-controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.filter-section,
.search-section,
.action-buttons {
  background-color: white;
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
}

.filter-section:hover,
.search-section:hover {
  box-shadow: var(--shadow-md);
}

.filter-header,
.search-header {
  display: flex;
  align-items: center;
  margin-bottom: 15px;
  font-weight: 500;
  color: var(--primary);
}

.filter-header i,
.search-header i {
  margin-right: 10px;
  font-size: 18px;
  color: var(--secondary);
}

.search-input-container {
  position: relative;
}

.search-button {
  position: absolute;
  right: 0;
  top: 0;
  height: 100%;
  background: transparent;
  border: none;
  padding: 0 15px;
  color: var(--secondary);
  font-size: 18px;
}

.action-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  justify-content: center;
}

.action-buttons .btn {
  padding: 10px 15px;
  display: flex;
  align-items: center;
  gap: 8px;
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  flex: 1;
  justify-content: center;
}

.action-buttons .btn i {
  font-size: 18px;
}

.action-buttons .btn:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

/* Projects Summary Stats */
.projects-summary-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 20px;
  margin-bottom: 30px;
}

.stat-card {
  background: white;
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  transition: var(--transition-fast);
}

.stat-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.stat-icon {
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--secondary) 0%, var(--accent) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 20px;
}

.stat-icon i {
  font-size: 24px;
  color: white;
}

.stat-content {
  flex: 1;
}

.stat-value {
  font-size: 24px;
  font-weight: 600;
  color: var(--primary);
  margin-bottom: 5px;
}

.stat-label {
  font-size: 14px;
  color: var(--gray);
}

.stat-subtext {
  font-size: 12px;
  color: var(--gray-light);
  margin-top: 2px;
}

.percentage-value {
  font-size: 12px;
  margin-top: 2px;
  opacity: 0.8;
}

/* Project List */
.project-list {
  margin-bottom: 30px;
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  background: white;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  margin: 30px 0;
}

.empty-state-icon {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: #f5f5f5;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
}

.empty-state-icon i {
  font-size: 36px;
  color: var(--gray);
}

.empty-state h3 {
  margin-bottom: 10px;
  color: var(--primary);
}

.empty-state p {
  color: var(--gray);
  margin-bottom: 20px;
}

/* Pagination */
.pagination-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 30px;
  flex-wrap: wrap;
  gap: 15px;
}

.pagination-info {
  color: var(--gray);
  font-size: 14px;
}

.pagination {
  display: flex;
  list-style: none;
  padding: 0;
  margin: 0;
}

.pagination li {
  margin: 0 3px;
}

.pagination li a {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: white;
  color: var(--primary);
  text-decoration: none;
  transition: var(--transition-fast);
  box-shadow: var(--shadow-sm);
}

.pagination li.active a {
  background: var(--secondary);
  color: white;
  box-shadow: var(--shadow-md);
}

.pagination li a:hover {
  background: var(--secondary-light);
  color: white;
  box-shadow: var(--shadow-md);
}

/* ===== Index Page Specific ===== */
.search-container {
  position: relative;
  margin: 0 auto 30px;
  max-width: 600px;
}

.prsearch {
  margin: 0 auto;
  max-width: 600px;
  background-color: white;
  box-shadow: var(--shadow-md);
  border: none;
  border-radius: var(--radius-lg);
  padding: 15px 20px;
  height: 60px;
  background-image: linear-gradient(to right, rgba(52, 152, 219, 0.05), rgba(52, 152, 219, 0.1));
}

.prsearch:focus {
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.2), var(--shadow-md);
  border: none;
  outline: none;
}

.search-container:before {
  content: '\f002';
  font-family: 'FontAwesome';
  position: absolute;
  right: 20px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--secondary);
  font-size: 18px;
  z-index: 2;
  pointer-events: none;
}

#ptask_container {
  background-color: white;
  border-radius: var(--radius-md);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  margin-top: 20px;
  transition: var(--transition-normal);
}

#ptask_container:hover {
  box-shadow: var(--shadow-md);
}

#ptasks {
  max-width: 600px;
  margin: 20px auto 0;
}

.list-group-item {
  border-radius: var(--radius-sm) !important;
  margin-bottom: 5px;
  border: 1px solid #f1f1f1;
  transition: var(--transition-fast);
}

.list-group-item:hover {
  background-color: #f9f9f9;
}

/* ===== Animations ===== */
@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

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

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

.slide-in-up {
  animation: slideInUp 0.5s ease forwards;
}

/* Apply animations to elements */
.panel, .shortcuts a, .form-control, .btn {
  animation: slideInUp 0.5s ease forwards;
}

.table > thead > tr {
  animation: fadeIn 0.5s ease forwards;
}

.table > tbody > tr {
  animation: slideInUp 0.5s ease forwards;
  animation-fill-mode: both;
}

/* Staggered animation for table rows */
.table > tbody > tr:nth-child(1) { animation-delay: 0.05s; }
.table > tbody > tr:nth-child(2) { animation-delay: 0.1s; }
.table > tbody > tr:nth-child(3) { animation-delay: 0.15s; }
.table > tbody > tr:nth-child(4) { animation-delay: 0.2s; }
.table > tbody > tr:nth-child(5) { animation-delay: 0.25s; }
.table > tbody > tr:nth-child(6) { animation-delay: 0.3s; }
.table > tbody > tr:nth-child(7) { animation-delay: 0.35s; }
.table > tbody > tr:nth-child(8) { animation-delay: 0.4s; }
.table > tbody > tr:nth-child(9) { animation-delay: 0.45s; }
.table > tbody > tr:nth-child(10) { animation-delay: 0.5s; }

/* ===== Responsive Adjustments ===== */
@media (max-width: 768px) {
  .shortcuts {
    grid-template-columns: repeat(2, 1fr);
  }
  
  .panel {
    margin-bottom: 15px;
  }
  
  .table-responsive {
    border: none;
  }
  
  .prsearch {
    width: 100% !important;
  }
}

/* ===== DataTables Styling ===== */
.dataTables_wrapper .dataTables_length,
.dataTables_wrapper .dataTables_filter,
.dataTables_wrapper .dataTables_info,
.dataTables_wrapper .dataTables_processing,
.dataTables_wrapper .dataTables_paginate {
  color: var(--gray);
  margin-bottom: 15px;
}

.dataTables_wrapper .dataTables_filter input {
  border: 1px solid #e0e0e0;
  border-radius: var(--radius-md);
  padding: 8px 12px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition-fast);
  margin-left: 10px;
}

.dataTables_wrapper .dataTables_filter input:focus {
  border-color: var(--secondary);
  box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.15);
  outline: none;
}

.dataTables_wrapper .dataTables_length select {
  border: 1px solid #e0e0e0;
  border-radius: var(--radius-md);
  padding: 6px 10px;
  box-shadow: var(--shadow-sm);
  margin: 0 5px;
}

.dataTables_wrapper .dataTables_paginate {
  margin-top: 15px;
}

.dataTables_wrapper .dataTables_paginate .paginate_button {
  border-radius: var(--radius-md);
  transition: var(--transition-fast);
  padding: 8px 14px;
  margin: 0 3px;
  border: none;
  background: #f8f9fa;
  box-shadow: var(--shadow-sm);
}

.dataTables_wrapper .dataTables_paginate .paginate_button:hover {
  background: var(--secondary-light);
  color: white !important;
  border: none;
}

.dataTables_wrapper .dataTables_paginate .paginate_button.current,
.dataTables_wrapper .dataTables_paginate .paginate_button.current:hover {
  background: var(--secondary);
  border: none;
  color: white !important;
  box-shadow: var(--shadow-md);
}

.dataTables_wrapper .dataTables_paginate .paginate_button.disabled,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:hover,
.dataTables_wrapper .dataTables_paginate .paginate_button.disabled:active {
  color: var(--gray-light) !important;
  background: #f8f9fa;
  border: none;
  box-shadow: none;
}

/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
  background: var(--gray-light);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gray);
}

/* ===== Loading Indicators ===== */
.loading {
  position: relative;
}

.loading:after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(255, 255, 255, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10;
}

.loading:before {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  margin-top: -15px;
  margin-left: -15px;
  width: 30px;
  height: 30px;
  border: 3px solid var(--secondary);
  border-top-color: transparent;
  border-radius: 50%;
  z-index: 11;
  animation: spin 0.8s linear infinite;
}

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