/* ===== PAGINATION STYLES ===== */

.pagination-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 15px;
  padding: 20px 15px;
  background: white;
  border-radius: 12px;
  border: 2px solid #e0e0e0;
  margin-top: 20px;
  flex-wrap: wrap;
}

.pagination-info {
  color: #666;
  font-size: 0.95rem;
  font-weight: 500;
}

.pagination-controls {
  display: flex;
  gap: 10px;
  align-items: center;
  flex-wrap: wrap;
}

.btn-pagination {
  padding: 8px 12px;
  background: white;
  border: 1px solid #ddd;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.2s ease;
  color: #333;
}

.btn-pagination:hover:not(:disabled) {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%);
  border-color: #5849c4;
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(91, 73, 196, 0.3);
}

.btn-pagination:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.page-number {
  min-width: 36px;
  height: 36px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: white;
  border: 1px solid #ddd;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.2s ease;
  color: #333;
}

.page-number:hover {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%);
  border-color: #5849c4;
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(91, 73, 196, 0.3);
}

.page-number.active {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%);
  border-color: #5849c4;
  color: white;
  box-shadow: 0 3px 12px rgba(91, 73, 196, 0.4);
}

.records-per-page {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.9rem;
  font-weight: 500;
  color: #333;
}

.records-select {
  padding: 6px 10px;
  border: 1px solid #ddd;
  border-radius: 6px;
  background: white;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  color: #333;
  transition: all 0.2s ease;
}

.records-select:focus {
  outline: none;
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(139, 127, 245, 0.1);
}

.records-select:hover {
  border-color: var(--primary-purple);
}

/* ===== SIMPLE HEADER PAGE SIZE SELECTOR ===== */

.header-page-size {
  padding: 10px 15px;
  background: linear-gradient(145deg, #ffffff 0%, #f8fafb 100%);
  border: 2px solid #ddd;
  border-radius: var(--radius-lg);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 10px;
}

.header-page-size:hover {
  border-color: var(--primary-purple);
  box-shadow: 0 4px 12px rgba(139, 127, 245, 0.1);
}

.header-page-size label {
  font-weight: 600;
  color: var(--primary-navy);
  margin: 0;
}

.header-page-size select {
  padding: 6px 10px;
  border: 1px solid #ddd;
  border-radius: 6px;
  font-weight: 600;
  color: var(--primary-navy);
  background-color: white;
  cursor: pointer;
  transition: all 0.2s ease;
}

.header-page-size select:hover {
  border-color: var(--primary-purple);
}

.header-page-size select:focus {
  outline: none;
  border-color: var(--primary-purple);
  box-shadow: 0 0 0 3px rgba(139, 127, 245, 0.1);
}

/* ===== SIMPLE HEADER PAGINATION ===== */

.header-pagination {
  padding: 10px 8px !important;
  background: linear-gradient(145deg, #ffffff 0%, #f8fafb 100%);
  border: 2px solid #ddd;
  border-radius: var(--radius-lg);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.header-pagination:hover {
  border-color: var(--primary-purple);
  box-shadow: 0 4px 12px rgba(139, 127, 245, 0.1);
}

.header-pagination-btn {
  padding: 8px 12px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%);
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  color: white;
  transition: all 0.3s ease;
  box-shadow: 0 3px 12px rgba(91, 73, 196, 0.4);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
}

.header-pagination-btn:hover:not(:disabled):not(.header-pagination-btn-active) {
  background: linear-gradient(135deg, #5849c4 0%, #3f34a8 100%) !important;
  box-shadow: 0 5px 20px rgba(91, 73, 196, 0.6) !important;
  transform: translateY(-2px);
  color: white !important;
}

.header-pagination-btn:active:not(:disabled) {
  transform: translateY(0);
}

.header-pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  color: rgba(255, 255, 255, 0.6);
}

.header-pagination-btn-active {
  background: linear-gradient(135deg, #5849c4 0%, #3f34a8 100%) !important;
  border-color: transparent !important;
  color: white !important;
  box-shadow: 0 5px 20px rgba(91, 73, 196, 0.6) !important;
}

.header-pagination-btn-active:hover:not(:disabled) {
  background: linear-gradient(135deg, #4a3ba8 0%, #2f268f 100%) !important;
  box-shadow: 0 6px 25px rgba(91, 73, 196, 0.7) !important;
  color: white !important;
}

.header-pagination .page-number {
  min-width: 30px;
  height: 30px;
  padding: 0;
}

.header-pagination .page-number.active {
  background: var(--primary-purple);
  border-color: var(--primary-purple);
  color: white;
}

.pagination-info-text {
  font-size: 0.85rem;
  color: #666;
  font-weight: 500;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .pagination-wrapper {
    flex-direction: column;
    gap: 10px;
  }

  .pagination-controls {
    width: 100%;
    justify-content: center;
  }

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


/* ===== BOTTOM PAGINATION BUTTONS ===== */

.pagination-btn {
  padding: 8px 12px !important;
  background: white !important;
  border: 1px solid #ddd !important;
  border-radius: 8px !important;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all 0.2s ease;
  color: #333 !important;
}

.pagination-btn:hover:not(:disabled) {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%) !important;
  border-color: #5849c4 !important;
  color: white !important;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(91, 73, 196, 0.3) !important;
}

.pagination-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.pagination-btn-icon {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
}

/* Override next button to match new color scheme */
#nextPageBtn {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%) !important;
  border: none !important;
  color: white !important;
  font-weight: 600;
  padding: 8px 12px !important;
}

#nextPageBtn:hover {
  background: linear-gradient(135deg, #5849c4 0%, #3f34a8 100%) !important;
  box-shadow: 0 5px 20px rgba(91, 73, 196, 0.6) !important;
}

#nextPageBtn:active {
  transform: translateY(0) !important;
}

/* Last button styling */
#lastPageBtn {
  background: white !important;
  border: 1px solid #ddd !important;
  color: #333 !important;
  border-radius: 8px !important;
  padding: 8px 12px !important;
}

#lastPageBtn:hover {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%) !important;
  border-color: #5849c4 !important;
  color: white !important;
  box-shadow: 0 4px 12px rgba(91, 73, 196, 0.3) !important;
}

/* First and Prev buttons */
#firstPageBtn,
#prevPageBtn {
  background: white !important;
  border: 1px solid #ddd !important;
  color: #333 !important;
  border-radius: 8px !important;
  padding: 8px 12px !important;
}

#firstPageBtn:hover:not(:disabled),
#prevPageBtn:hover:not(:disabled) {
  background: linear-gradient(135deg, #6b5fd9 0%, #5849c4 100%) !important;
  border-color: #5849c4 !important;
  color: white !important;
  box-shadow: 0 4px 12px rgba(91, 73, 196, 0.3) !important;
}


/* ===== PAGE SIZE SELECTOR ===== */

.pagination-size {
  display: flex;
  align-items: center;
  gap: 8px;
}

.pagination-size label {
  font-size: 13px !important;
  color: #666 !important;
  font-weight: 500;
  margin-right: 8px !important;
  white-space: nowrap;
}

.pagination-select {
  padding: 8px 12px !important;
  border: 1px solid #ddd !important;
  border-radius: 8px !important;
  background: white !important;
  font-size: 0.9rem;
  font-weight: 600;
  color: #333 !important;
  cursor: pointer;
  transition: all 0.2s ease;
  box-shadow: none !important;
}

.pagination-select:hover {
  border-color: #6b5fd9 !important;
  box-shadow: 0 2px 8px rgba(91, 73, 196, 0.2) !important;
  background: #f9f9fb !important;
}

.pagination-select:focus {
  outline: none !important;
  border-color: #6b5fd9 !important;
  box-shadow: 0 0 0 3px rgba(91, 73, 196, 0.15) !important;
  background: white !important;
}

.pagination-select option {
  padding: 8px 12px;
  color: #333;
  background: white;
}

/* Direct ID selector for more specificity */
#pageSizeSelect {
  padding: 8px 12px !important;
  border: 1px solid #ddd !important;
  border-radius: 8px !important;
  background: white !important;
  font-size: 0.9rem !important;
  font-weight: 600 !important;
  color: #333 !important;
  cursor: pointer !important;
  transition: all 0.2s ease !important;
  box-shadow: none !important;
}

#pageSizeSelect:hover {
  border-color: #6b5fd9 !important;
  box-shadow: 0 2px 8px rgba(91, 73, 196, 0.2) !important;
  background: #f9f9fb !important;
}

#pageSizeSelect:focus {
  outline: none !important;
  border-color: #6b5fd9 !important;
  box-shadow: 0 0 0 3px rgba(91, 73, 196, 0.15) !important;
  background: white !important;
}
