/* ===== CSS Variables / Design System ===== */
:root {
  --bg-primary: #060a13;
  --bg-secondary: #0c1222;
  --bg-tertiary: #111a2e;
  --bg-card: rgba(17, 26, 46, 0.85);
  --bg-card-hover: rgba(25, 38, 66, 0.9);
  --bg-input: rgba(15, 23, 42, 0.8);
  --bg-overlay: rgba(6, 10, 19, 0.85);

  --accent-primary: #8b5cf6;
  --accent-secondary: #06b6d4;
  --accent-gradient: linear-gradient(135deg, #8b5cf6 0%, #06b6d4 100%);
  --accent-gradient-alt: linear-gradient(135deg, #a78bfa 0%, #22d3ee 100%);
  --accent-glow: 0 0 20px rgba(139, 92, 246, 0.3);

  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --text-accent: #a78bfa;

  --border: rgba(148, 163, 184, 0.08);
  --border-hover: rgba(148, 163, 184, 0.15);
  --border-accent: rgba(139, 92, 246, 0.3);

  --success: #10b981;
  --success-bg: rgba(16, 185, 129, 0.1);
  --warning: #f59e0b;
  --warning-bg: rgba(245, 158, 11, 0.1);
  --error: #ef4444;
  --error-bg: rgba(239, 68, 68, 0.1);
  --info: #3b82f6;
  --info-bg: rgba(59, 130, 246, 0.1);

  --sidebar-width: 260px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 16px;
  --radius-xl: 20px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-glow: 0 0 30px rgba(139, 92, 246, 0.15);

  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* ===== Reset & Base ===== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  font-size: 14px;
  scroll-behavior: smooth;
}

body {
  font-family: "Inter", -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  min-height: 100vh;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ===== App Layout ===== */
.app {
  display: flex;
  min-height: 100vh;
}

/* ===== Sidebar ===== */
.sidebar {
  width: var(--sidebar-width);
  height: 100vh;
  position: fixed;
  left: 0;
  top: 0;
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  z-index: 100;
  transition: var(--transition);
}

.sidebar-header {
  padding: 24px 20px;
  border-bottom: 1px solid var(--border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo-icon {
  width: 42px;
  height: 42px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: var(--accent-glow);
}

.logo-icon .material-symbols-outlined {
  font-size: 22px;
  color: white;
}

.logo-text h1 {
  font-size: 1.3rem;
  font-weight: 700;
  background: var(--accent-gradient-alt);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.version {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Sidebar Navigation */
.sidebar-nav {
  flex: 1;
  padding: 16px 12px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  color: var(--text-secondary);
  text-decoration: none;
  font-weight: 500;
  font-size: 0.93rem;
  transition: var(--transition);
  position: relative;
  overflow: hidden;
}

.nav-item::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: var(--accent-gradient);
  border-radius: 0 4px 4px 0;
  opacity: 0;
  transition: var(--transition);
}

.nav-item:hover {
  background: rgba(139, 92, 246, 0.08);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(139, 92, 246, 0.12);
  color: var(--accent-primary);
}

.nav-item.active::before {
  opacity: 1;
}

.nav-item .material-symbols-outlined {
  font-size: 22px;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 16px 16px 20px;
  border-top: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.02);
  font-size: 0.8rem;
  color: var(--text-muted);
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

.status-dot.online {
  background: var(--success);
  box-shadow: 0 0 8px var(--success);
  animation: pulse 2s infinite;
}

.status-dot.offline {
  background: var(--text-muted);
}

.status-dot.warning {
  background: var(--warning);
  box-shadow: 0 0 8px var(--warning);
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.5;
  }
}

/* ===== Mobile Header ===== */
.mobile-header {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 56px;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border);
  align-items: center;
  gap: 12px;
  padding: 0 16px;
  z-index: 90;
}

.mobile-header h1 {
  font-size: 1.1rem;
  font-weight: 700;
  background: var(--accent-gradient-alt);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.menu-toggle {
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
  padding: 4px;
}

/* ===== Main Content ===== */
.content {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 32px;
  min-height: 100vh;
}

/* ===== Page Header ===== */
.page-header {
  margin-bottom: 28px;
}

.page-header h2 {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 6px;
}

.page-header p {
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* ===== Cards ===== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px;
  backdrop-filter: blur(12px);
  transition: var(--transition);
}

.card:hover {
  border-color: var(--border-hover);
}

.card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.card-title {
  font-size: 1.1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 10px;
}

.card-title .material-symbols-outlined {
  color: var(--accent-primary);
  font-size: 22px;
}

/* ===== Stat Cards Grid ===== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 16px;
  margin-bottom: 28px;
}

.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
}

.stat-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--accent-gradient);
  opacity: 0;
  transition: var(--transition);
}

.stat-card:hover {
  border-color: var(--border-accent);
  transform: translateY(-2px);
  box-shadow: var(--shadow-glow);
}

.stat-card:hover::before {
  opacity: 1;
}

.stat-card .stat-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  font-size: 22px;
}

.stat-card .stat-icon.purple {
  background: rgba(139, 92, 246, 0.15);
  color: var(--accent-primary);
}

.stat-card .stat-icon.cyan {
  background: rgba(6, 182, 212, 0.15);
  color: var(--accent-secondary);
}

.stat-card .stat-icon.green {
  background: var(--success-bg);
  color: var(--success);
}

.stat-card .stat-icon.orange {
  background: var(--warning-bg);
  color: var(--warning);
}

.stat-value {
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1;
  margin-bottom: 6px;
}

.stat-label {
  color: var(--text-secondary);
  font-size: 0.85rem;
  font-weight: 500;
}

/* ===== Forms ===== */
.form-group {
  margin-bottom: 20px;
}

.form-label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.form-input {
  width: 100%;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  color: var(--text-primary);
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
  outline: none;
}

.form-input::placeholder {
  color: var(--text-muted);
}

.form-input:focus {
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.15);
}

.form-hint {
  margin-top: 6px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* ===== Buttons ===== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: var(--radius-md);
  font-family: inherit;
  font-size: 0.93rem;
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-decoration: none;
  white-space: nowrap;
}

.btn .material-symbols-outlined {
  font-size: 20px;
}

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

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 30px rgba(139, 92, 246, 0.4);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: rgba(148, 163, 184, 0.15);
  color: var(--text-primary);
}

.btn-success {
  background: rgba(16, 185, 129, 0.15);
  color: var(--success);
  border: 1px solid rgba(16, 185, 129, 0.2);
}

.btn-success:hover {
  background: rgba(16, 185, 129, 0.25);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.15);
  color: var(--error);
  border: 1px solid rgba(239, 68, 68, 0.2);
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.25);
}

.btn-warning {
  background: rgba(245, 158, 11, 0.15);
  color: var(--warning);
  border: 1px solid rgba(245, 158, 11, 0.2);
}

.btn-warning:hover {
  background: rgba(245, 158, 11, 0.25);
}

.btn-sm {
  padding: 8px 16px;
  font-size: 0.85rem;
}

.btn-lg {
  padding: 14px 32px;
  font-size: 1rem;
}

.btn-group {
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}

/* ===== Progress Bar ===== */
.progress-container {
  margin: 16px 0;
}

.progress-bar-bg {
  width: 100%;
  height: 10px;
  background: rgba(148, 163, 184, 0.1);
  border-radius: 10px;
  overflow: hidden;
  position: relative;
}

.progress-bar-fill {
  height: 100%;
  background: var(--accent-gradient);
  border-radius: 10px;
  transition: width 0.5s ease;
  position: relative;
}

.progress-bar-fill::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: linear-gradient(
    90deg,
    rgba(255, 255, 255, 0) 0%,
    rgba(255, 255, 255, 0.2) 50%,
    rgba(255, 255, 255, 0) 100%
  );
  animation: shimmer 2s infinite;
}

@keyframes shimmer {
  0% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(100%);
  }
}

.progress-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.progress-percentage {
  font-weight: 700;
  color: var(--accent-primary);
  font-size: 0.95rem;
}

/* ===== Auth Steps ===== */
.auth-steps {
  display: flex;
  gap: 0;
  margin-bottom: 32px;
  position: relative;
}

.auth-step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  position: relative;
  z-index: 1;
}

.auth-step::before {
  content: "";
  position: absolute;
  top: 18px;
  left: 50%;
  width: 100%;
  height: 2px;
  background: var(--border);
}

.auth-step:last-child::before {
  display: none;
}

.step-circle {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-tertiary);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  font-weight: 700;
  transition: var(--transition);
  position: relative;
  z-index: 2;
}

.auth-step.active .step-circle {
  border-color: var(--accent-primary);
  background: rgba(139, 92, 246, 0.2);
  color: var(--accent-primary);
  box-shadow: 0 0 12px rgba(139, 92, 246, 0.3);
}

.auth-step.completed .step-circle {
  border-color: var(--success);
  background: rgba(16, 185, 129, 0.2);
  color: var(--success);
}

.step-label {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

.auth-step.active .step-label {
  color: var(--accent-primary);
}

.auth-step.completed .step-label {
  color: var(--success);
}

/* ===== Channel List ===== */
.channel-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.channel-item {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: var(--transition);
}

.channel-item:hover {
  border-color: var(--border-accent);
  background: var(--bg-card-hover);
  transform: translateX(4px);
}

.channel-item.selected {
  border-color: var(--accent-primary);
  background: rgba(139, 92, 246, 0.08);
}

.channel-avatar {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  color: white;
  flex-shrink: 0;
}

.channel-info {
  flex: 1;
  min-width: 0;
}

.channel-name {
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.channel-meta {
  display: flex;
  gap: 12px;
  margin-top: 4px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ===== Log / Activity Feed ===== */
.activity-log {
  max-height: 400px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 4px;
}

.log-entry {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
  background: rgba(255, 255, 255, 0.02);
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    opacity: 0;
    transform: translateY(-8px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.log-entry .log-icon {
  font-size: 18px;
  flex-shrink: 0;
  margin-top: 1px;
}

.log-entry .log-icon.success {
  color: var(--success);
}
.log-entry .log-icon.error {
  color: var(--error);
}
.log-entry .log-icon.info {
  color: var(--info);
}
.log-entry .log-icon.warning {
  color: var(--warning);
}

.log-entry .log-text {
  flex: 1;
  color: var(--text-secondary);
  line-height: 1.5;
  word-break: break-word;
}

.log-entry .log-time {
  font-size: 0.75rem;
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ===== Badge ===== */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 0.75rem;
  font-weight: 600;
}

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

.badge-warning {
  background: var(--warning-bg);
  color: var(--warning);
}

.badge-error {
  background: var(--error-bg);
  color: var(--error);
}

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

.badge-default {
  background: rgba(148, 163, 184, 0.1);
  color: var(--text-secondary);
}

/* ===== Toast Notifications ===== */
.toast-container {
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.toast {
  padding: 14px 20px;
  border-radius: var(--radius-md);
  background: var(--bg-tertiary);
  border: 1px solid var(--border);
  color: var(--text-primary);
  font-size: 0.9rem;
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 300px;
  max-width: 450px;
  box-shadow: var(--shadow-lg);
  animation: toastIn 0.4s ease;
  backdrop-filter: blur(12px);
}

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

.toast.success {
  border-color: rgba(16, 185, 129, 0.3);
}
.toast.error {
  border-color: rgba(239, 68, 68, 0.3);
}
.toast.warning {
  border-color: rgba(245, 158, 11, 0.3);
}
.toast.info {
  border-color: rgba(59, 130, 246, 0.3);
}

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

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

/* ===== Empty State ===== */
.empty-state {
  text-align: center;
  padding: 48px 24px;
  color: var(--text-muted);
}

.empty-state .material-symbols-outlined {
  font-size: 56px;
  margin-bottom: 16px;
  opacity: 0.4;
}

.empty-state h3 {
  font-size: 1.15rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

.empty-state p {
  font-size: 0.9rem;
  max-width: 400px;
  margin: 0 auto;
}

/* ===== Loading Spinner ===== */
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(139, 92, 246, 0.2);
  border-top-color: var(--accent-primary);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

.spinner-lg {
  width: 40px;
  height: 40px;
  border-width: 3px;
}

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

/* ===== Table ===== */
.table-container {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
}

table {
  width: 100%;
  border-collapse: collapse;
}

th {
  padding: 12px 16px;
  text-align: left;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  background: rgba(255, 255, 255, 0.02);
  border-bottom: 1px solid var(--border);
}

td {
  padding: 14px 16px;
  font-size: 0.9rem;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}

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

tr:hover td {
  background: rgba(255, 255, 255, 0.02);
}

/* ===== Section Divider ===== */
.section-divider {
  height: 1px;
  background: var(--border);
  margin: 28px 0;
}

/* ===== Grid Layouts ===== */
.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

/* ===== Connection Status Card ===== */
.connection-status {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 20px;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
}

.connection-status .status-icon {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
}

.connection-status .status-icon.connected {
  background: var(--success-bg);
  color: var(--success);
}

.connection-status .status-icon.disconnected {
  background: var(--error-bg);
  color: var(--error);
}

.connection-status .status-info h4 {
  font-size: 1rem;
  margin-bottom: 4px;
}

.connection-status .status-info p {
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ===== Download File Item ===== */
.download-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: rgba(255, 255, 255, 0.02);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  margin-bottom: 8px;
  animation: slideIn 0.3s ease;
}

.download-item .file-icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.download-item .file-icon.video {
  background: rgba(139, 92, 246, 0.15);
  color: var(--accent-primary);
}

.download-item .file-icon.photo {
  background: rgba(6, 182, 212, 0.15);
  color: var(--accent-secondary);
}

.download-item .file-info {
  flex: 1;
  min-width: 0;
}

.download-item .file-name {
  font-weight: 500;
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.download-item .file-meta {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.download-item .file-progress {
  width: 120px;
  flex-shrink: 0;
}

.download-item .file-progress .progress-bar-bg {
  height: 6px;
}

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

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: rgba(148, 163, 184, 0.15);
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: rgba(148, 163, 184, 0.25);
}

/* ===== Page Transitions ===== */
.page-enter {
  animation: fadeIn 0.3s ease;
}

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

/* ===== Responsive ===== */
@media (max-width: 1024px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
  .form-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
    box-shadow: var(--shadow-lg);
  }

  .mobile-header {
    display: flex;
  }

  .content {
    margin-left: 0;
    padding: 72px 16px 24px;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .stat-value {
    font-size: 1.4rem;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* ===== Utility ===== */
.mt-16 {
  margin-top: 16px;
}
.mt-24 {
  margin-top: 24px;
}
.mb-16 {
  margin-bottom: 16px;
}
.mb-24 {
  margin-bottom: 24px;
}
.text-center {
  text-align: center;
}
.text-success {
  color: var(--success);
}
.text-error {
  color: var(--error);
}
.text-warning {
  color: var(--warning);
}
.text-muted {
  color: var(--text-muted);
}
.flex-center {
  display: flex;
  align-items: center;
  justify-content: center;
}
.gap-8 {
  gap: 8px;
}
.gap-12 {
  gap: 12px;
}
.w-full {
  width: 100%;
}

/* ===== Current Download Card ===== */
.current-download {
  padding: 20px;
  background: rgba(139, 92, 246, 0.05);
  border: 1px solid var(--border-accent);
  border-radius: var(--radius-lg);
  margin-bottom: 20px;
}

.current-download .dl-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

.current-download .dl-title {
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 8px;
}

.current-download .dl-title .spinner {
  width: 16px;
  height: 16px;
}

.current-download .dl-stats {
  display: flex;
  gap: 24px;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 12px;
}

.current-download .dl-stats span {
  display: flex;
  align-items: center;
  gap: 6px;
}
