/* TRUSOF Books Platform - Admin Studio Stylesheet */

:root {
  --admin-primary: #2563eb;
  --admin-primary-hover: #1d4ed8;
  --admin-dark-bg: #0b1120;
  --admin-card-bg: #151e33;
  --admin-border: rgba(255, 255, 255, 0.08);
  --admin-text-main: #f8fafc;
  --admin-text-muted: #94a3b8;
}

body.admin-body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background-color: #0b1120;
  color: #f1f5f9;
  min-height: 100vh;
}

.admin-navbar {
  background-color: #070d18;
  border-bottom: 1px solid var(--admin-border);
  padding: 0.85rem 1.5rem;
}

.admin-card {
  background: var(--admin-card-bg);
  border: 1px solid var(--admin-border);
  border-radius: 12px;
  box-shadow: 0 4px 20px rgba(0,0,0,0.25);
  margin-bottom: 1.5rem;
}

.admin-card-header {
  padding: 1rem 1.25rem;
  border-bottom: 1px solid var(--admin-border);
  background: rgba(255,255,255,0.02);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.admin-stat-card {
  background: linear-gradient(135deg, #151e33 0%, #1e293b 100%);
  border: 1px solid var(--admin-border);
  border-radius: 12px;
  padding: 1.25rem;
  position: relative;
  overflow: hidden;
}

.admin-stat-card::after {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  width: 80px;
  height: 80px;
  background: radial-gradient(circle, rgba(37,99,235,0.15) 0%, transparent 70%);
}

.stat-val {
  font-family: 'Outfit', sans-serif;
  font-size: 2rem;
  font-weight: 800;
  color: #fff;
  line-height: 1.2;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--admin-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 600;
}

/* Page List & Reordering */
.page-sort-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--admin-border);
  border-radius: 8px;
  padding: 10px 14px;
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.2s ease;
  cursor: pointer;
}

.page-sort-item:hover, .page-sort-item.active {
  background: rgba(37, 99, 235, 0.15);
  border-color: rgba(59, 130, 246, 0.5);
}

.drag-handle {
  cursor: grab;
  color: var(--admin-text-muted);
  padding: 4px 8px;
  user-select: none;
}

.drag-handle:active {
  cursor: grabbing;
}

.page-sort-badge {
  background: #2563eb;
  color: #fff;
  font-weight: 700;
  font-size: 11px;
  padding: 3px 8px;
  border-radius: 6px;
  margin-right: 10px;
}

/* Rich Text Editor Container */
.ql-toolbar {
  background: #1e293b !important;
  border-color: var(--admin-border) !important;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
}
.ql-toolbar .ql-stroke {
  stroke: #cbd5e1 !important;
}
.ql-toolbar .ql-fill {
  fill: #cbd5e1 !important;
}
.ql-toolbar .ql-picker {
  color: #cbd5e1 !important;
}

.ql-container {
  background: #0f172a !important;
  border-color: var(--admin-border) !important;
  border-bottom-left-radius: 8px;
  border-bottom-right-radius: 8px;
  color: #f8fafc !important;
  font-size: 15px;
  min-height: 250px;
}

/* Form Controls */
.form-control, .form-select {
  background-color: #0f172a;
  border-color: rgba(255, 255, 255, 0.15);
  color: #f8fafc;
}
.form-control:focus, .form-select:focus {
  background-color: #0f172a;
  border-color: #3b82f6;
  color: #ffffff;
  box-shadow: 0 0 0 0.25rem rgba(37, 99, 235, 0.25);
}

/* Tables */
.table-dark-custom {
  --bs-table-bg: transparent;
  --bs-table-striped-bg: rgba(255, 255, 255, 0.02);
  --bs-table-border-color: var(--admin-border);
  color: #e2e8f0;
}
