/* ============================================================
   PRISCO FASHION WORLD — ADMIN CSS
   Premium Rose Gold Admin Dashboard Styling
   ============================================================ */

/* ── Admin Page Structure ────────────────────────────────── */
.admin-body {
  background-color: var(--bg-darker);
  font-family: var(--font-body);
  color: var(--text);
  min-height: 100vh;
  display: flex;
}

/* ── Admin Login Page ────────────────────────────────────── */
.admin-login-wrapper {
  min-height: 100vh;
  width: 100vw;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 50%, rgba(200, 149, 108, 0.12), transparent 60%), var(--bg-dark);
  position: relative;
  overflow: hidden;
}
.admin-login-card {
  width: 100%;
  max-width: 440px;
  padding: 3rem;
  z-index: 10;
  text-align: center;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border);
}
.admin-login-logo {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}
.admin-login-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: 2.5rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

/* ── Admin Panel Layout ──────────────────────────────────── */
.admin-sidebar {
  width: 280px;
  background: rgba(20, 10, 12, 0.95);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  z-index: 100;
  transition: var(--transition);
}
.admin-sidebar-header {
  padding: 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.admin-logo {
  font-family: var(--font-heading);
  font-size: 1.3rem;
  font-weight: 700;
}
.admin-logo span {
  font-size: 0.75rem;
  display: block;
  font-family: var(--font-body);
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.15em;
  font-weight: 600;
  margin-top: 2px;
}
.admin-nav {
  padding: 1.5rem 1rem;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  overflow-y: auto;
}
.admin-nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-sm);
  color: var(--text-muted);
  font-size: 0.95rem;
  font-weight: 500;
  transition: var(--transition);
}
.admin-nav-item i {
  width: 20px;
  font-size: 1.1rem;
  transition: var(--transition);
}
.admin-nav-item:hover, .admin-nav-item.active {
  background: var(--bg-glass);
  color: var(--primary);
}
.admin-nav-item.active {
  border-left: 3px solid var(--primary);
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
}
.admin-sidebar-footer {
  padding: 1.5rem;
  border-top: 1px solid var(--border);
}

.admin-main {
  flex: 1;
  margin-left: 280px;
  padding: 2.5rem;
  min-height: 100vh;
  background-color: var(--bg-darker);
}

.admin-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 2.5rem;
  border-bottom: 1px solid var(--border);
  padding-bottom: 1.5rem;
}
.admin-page-title h2 {
  font-size: 2rem;
  font-weight: 700;
}
.admin-page-title p {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: 4px;
}
.admin-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--bg-glass);
  border: 1px solid var(--border);
  padding: 8px 16px;
  border-radius: var(--radius-xl);
}
.admin-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--primary);
  color: #140A0C;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}
.admin-profile-name {
  font-size: 0.9rem;
  font-weight: 600;
}

/* ── Dashboard Stats ─────────────────────────────────────── */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}
.stat-card {
  padding: 1.75rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
  overflow: hidden;
}
.stat-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.stat-label {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.stat-value {
  font-family: var(--font-heading);
  font-size: 2rem;
  font-weight: 700;
  color: var(--primary);
}
.stat-trend {
  font-size: 0.75rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
}
.stat-trend.up { color: #22c55e; }
.stat-trend.down { color: #ef4444; }
.stat-icon {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  background: var(--bg-glass);
  border: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.25rem;
}

/* ── Tables & Lists ──────────────────────────────────────── */
.admin-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow);
  margin-bottom: 2rem;
}
.admin-card-header {
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.admin-card-title {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 600;
}
.admin-card-body {
  padding: 2rem;
}

.table-wrapper {
  overflow-x: auto;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
}
.admin-table th {
  padding: 1rem 1.5rem;
  border-bottom: 2px solid var(--border);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  font-weight: 600;
}
.admin-table td {
  padding: 1.2rem 1.5rem;
  border-bottom: 1px solid var(--border);
  font-size: 0.9rem;
  vertical-align: middle;
}
.admin-table tbody tr:last-child td {
  border-bottom: none;
}
.admin-table tbody tr:hover td {
  background: rgba(200, 149, 108, 0.03);
}

.admin-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 10px;
  border-radius: var(--radius-xs);
  text-transform: uppercase;
}
.admin-badge.success { background: rgba(34, 197, 94, 0.15); color: #22c55e; }
.admin-badge.warning { background: rgba(245, 158, 11, 0.15); color: #f59e0b; }
.admin-badge.danger  { background: rgba(239, 68, 68, 0.15); color: #ef4444; }
.admin-badge.info    { background: rgba(200, 149, 108, 0.15); color: var(--primary); }

.table-actions {
  display: flex;
  gap: 8px;
}
.action-btn {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-xs);
  border: 1px solid var(--border);
  background: var(--bg-glass);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
  cursor: pointer;
}
.action-btn:hover {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--bg-glass-hover);
}
.action-btn.delete:hover {
  border-color: #ef4444;
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
}

/* ── Admin Specific Forms & Media Upload ────────────────── */
.image-uploader-box {
  border: 2px dashed var(--border);
  border-radius: var(--radius-md);
  background: var(--bg-glass);
  padding: 2.5rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}
.image-uploader-box:hover {
  border-color: var(--primary);
  background: var(--bg-glass-hover);
}
.image-uploader-icon {
  font-size: 2.5rem;
  color: var(--primary);
  margin-bottom: 1rem;
}
.image-uploader-text h5 {
  font-family: var(--font-body);
  font-size: 0.95rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.image-uploader-text p {
  font-size: 0.8rem;
  color: var(--text-muted);
}
.image-uploader-input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}
.image-preview-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
  gap: 1rem;
  margin-top: 1.5rem;
}
.image-preview-item {
  width: 100px;
  height: 100px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}
.image-preview-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.image-preview-delete {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: rgba(239, 68, 68, 0.8);
  border: none;
  color: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  cursor: pointer;
}

.admin-grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
}
.admin-grid-sidebar {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 2rem;
}

/* ── Rich Text Editor mock ───────────────────────────────── */
.rich-text-editor {
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  overflow: hidden;
  background: var(--bg-glass);
}
.editor-toolbar {
  background: rgba(20, 10, 12, 0.5);
  border-bottom: 1px solid var(--border);
  padding: 8px 12px;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.editor-btn {
  background: none;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: var(--radius-xs);
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: var(--transition);
}
.editor-btn:hover, .editor-btn.active {
  background: var(--bg-glass);
  color: var(--primary);
}
.editor-content {
  min-height: 250px;
  padding: 1rem;
  outline: none;
  color: var(--text);
  font-size: 0.95rem;
  line-height: 1.6;
}

/* ── Settings Controls ───────────────────────────────────── */
.setting-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border);
}
.setting-row:last-child {
  border-bottom: none;
}
.setting-info {
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.setting-title {
  font-size: 0.95rem;
  font-weight: 600;
}
.setting-desc {
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* Switch Toggle Component */
.switch {
  position: relative;
  display: inline-block;
  width: 46px;
  height: 24px;
}
.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}
.switch-slider {
  position: absolute;
  cursor: pointer;
  top: 0; left: 0; right: 0; bottom: 0;
  background-color: var(--border);
  transition: .4s;
  border-radius: 34px;
}
.switch-slider:before {
  position: absolute;
  content: "";
  height: 16px;
  width: 16px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  transition: .4s;
  border-radius: 50%;
}
.switch input:checked + .switch-slider {
  background-color: var(--primary);
}
.switch input:checked + .switch-slider:before {
  transform: translateX(22px);
  background-color: #140A0C;
}

/* ── Mobile Sidebar Responsive ───────────────────────────── */
@media (max-width: 992px) {
  .admin-sidebar {
    transform: translateX(-100%);
  }
  .admin-sidebar.open {
    transform: translateX(0);
  }
  .admin-main {
    margin-left: 0;
    padding: 1.5rem;
  }
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .admin-grid-two, .admin-grid-sidebar {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 576px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}
