/* ============================================
   ANIVORA — COMPONENTS
============================================ */

/* ============================================
   BUTTONS
============================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 10px 22px;
  border-radius: var(--radius-sm);
  font-size: 13.5px;
  font-weight: 600;
  transition: var(--transition);
  white-space: nowrap;
}
.btn-primary {
  background: var(--accent);
  color: #fff;
}
.btn-primary:hover {
  background: var(--accent-hover);
  transform: translateY(-1px);
}
.btn-ghost {
  background: rgba(255,255,255,0.07);
  color: var(--text-primary);
  border: 1px solid var(--border-hover);
}
.btn-ghost:hover {
  background: rgba(255,255,255,0.11);
  transform: translateY(-1px);
}
.btn-icon {
  width: 40px;
  height: 40px;
  padding: 0;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}
.btn-sm {
  padding: 6px 14px;
  font-size: 12px;
}

/* BUTTON STATES (Add / Like) */
.btn-ghost.is-added,
.card-list-btn.is-added {
  background: rgba(76,175,128,0.14) !important;
  color: var(--success) !important;
  border-color: rgba(76,175,128,0.35) !important;
}
.btn-ghost.is-liked {
  background: rgba(255,120,160,0.15) !important;
  color: #ff78a0 !important;
  border-color: rgba(255,120,160,0.4) !important;
}
.btn-ghost.is-liked svg,
.btn-ghost.is-liked svg use {
  fill: #ff78a0;
  stroke: #ff78a0;
}

/* ============================================
   BADGES
============================================ */
.badge {
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.4px;
  text-transform: uppercase;
}
.badge-genre {
  background: rgba(255,255,255,0.07);
  color: var(--text-secondary);
  border: 1px solid var(--border-hover);
}
.badge-accent {
  background: var(--accent);
  color: #fff;
}
.badge-airing {
  background: rgba(76,175,128,0.14);
  color: var(--success);
  border: 1px solid rgba(76,175,128,0.28);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.airing-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--success);
}

/* STATUS BADGE */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 600;
}
.status-airing {
  background: rgba(76,175,128,0.12);
  color: var(--success);
}
.status-finished {
  background: rgba(255,255,255,0.06);
  color: var(--text-muted);
}
.status-upcoming {
  background: rgba(108,99,255,0.12);
  color: var(--accent);
}

/* TAG (GENRE) */
.tag {
  display: inline-flex;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 11px;
  font-weight: 500;
}

/* GENRE COLOR VARIANTS */
.genre-action  { background: rgba(224,85,85,0.1);  color: #e05555; }
.genre-fantasy { background: rgba(108,99,255,0.1); color: #6c63ff; }
.genre-romance { background: rgba(255,120,160,0.1); color: #ff78a0; }
.genre-scifi   { background: rgba(64,196,255,0.1); color: #40c4ff; }
.genre-drama   { background: rgba(255,200,80,0.1); color: #ffc850; }
.genre-horror  { background: rgba(180,40,40,0.1);  color: #b42828; }
.genre-comedy  { background: rgba(80,220,160,0.1); color: #50dca0; }

/* ============================================
   ANIME CARD
============================================ */
.anime-card {
  width: 158px;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border);
  transition: var(--transition);
  cursor: pointer;
  position: relative;
}
.anime-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
}

.card-poster {
  width: 100%;
  aspect-ratio: 2/3;
  background: var(--bg-elevated);
  position: relative;
  overflow: hidden;
}
.card-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.card-score {
  position: absolute;
  top: 8px; left: 8px;
  background: rgba(10,10,15,0.85);
  border-radius: 4px;
  padding: 2px 7px;
  font-size: 11px;
  font-weight: 700;
  color: var(--gold);
  display: flex;
  align-items: center;
  gap: 3px;
}
.card-type {
  position: absolute;
  top: 8px; right: 8px;
  background: var(--accent);
  border-radius: 4px;
  padding: 2px 6px;
  font-size: 10px;
  font-weight: 700;
  color: #fff;
  text-transform: uppercase;
}
.card-airing-dot {
  position: absolute;
  bottom: 8px; left: 8px;
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--success);
}

.card-body { padding: 10px; }

/* ★ عنوان کارت — پیش‌فرض یک خط با ... */
.card-title {
  font-size: 12.5px;
  font-weight: 600;
  line-height: 1.4;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  margin-bottom: 6px;
}

/* ★ اگر کارتی خواست دو خط شود، کلاس two-line را اضافه کن */
.card-title.two-line {
  white-space: normal;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  text-overflow: unset;
}

.card-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 2px;
}
.card-meta-item {
  font-size: 10.5px;
  color: var(--text-muted);
}
.card-genres {
  display: flex;
  gap: 4px;
  margin-top: 6px;
  flex-wrap: wrap;
}
.card-genre-tag {
  font-size: 9.5px;
  color: var(--text-muted);
  background: var(--bg-elevated);
  border-radius: 3px;
  padding: 1px 5px;
}

/* ============================================
   RESULT GRID
============================================ */
.results-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(158px, 1fr));
  gap: 16px;
  padding: 0 16px;
}
.results-grid .anime-card { width: 100%; }

/* ============================================
   SECTION (shared)
============================================ */
.section { padding: 48px 0; }
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
  padding: 0 24px;
}
.section-title {
  font-size: 16px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 10px;
}
.section-title-bar {
  display: block;
  width: 3px;
  height: 18px;
  background: var(--accent);
  border-radius: 2px;
}
.section-link {
  font-size: 12.5px;
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
  transition: var(--transition);
  font-weight: 500;
}
.section-link:hover { color: var(--accent); }

/* ============================================
   SCROLL ROW
============================================ */
.scroll-row {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 4px 24px 16px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}
.scroll-row::-webkit-scrollbar { display: none; }
.scroll-row > * { flex-shrink: 0; }

/* ============================================
   TABS
============================================ */
.tab-btn {
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  border-bottom: 2px solid transparent;
  white-space: nowrap;
  transition: var(--transition);
  margin-bottom: -1px;
}
.tab-btn.active {
  color: var(--text-primary);
  border-bottom-color: var(--accent);
}
.tab-panel {
  display: none;
  padding-top: 24px;
}
.tab-panel.active { display: block; }

/* ============================================
   FORMS
============================================ */
.form-group { margin-bottom: 16px; }
.form-label {
  display: block;
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 6px;
}
.form-input {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  color: var(--text-primary);
  font-size: 14px;
  outline: none;
}
.form-input:focus { border-color: var(--accent); }
.form-input::placeholder { color: var(--text-muted); }

.form-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}
.checkbox-wrap {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  color: var(--text-secondary);
  cursor: pointer;
}
.checkbox-wrap input { accent-color: var(--accent); }
.form-link {
  font-size: 12.5px;
  color: var(--accent);
}

/* ============================================
   CUSTOM BOTTOM-SHEET SELECT
============================================ */
.custom-select-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.55);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 4000;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.custom-select-overlay.show { opacity: 1; }

.custom-select-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-card);
  border-top-left-radius: 20px;
  border-top-right-radius: 20px;
  border-top: 1px solid var(--border);
  z-index: 4001;
  padding: 8px 0 20px;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  max-height: 70vh;
  overflow-y: auto;
  box-shadow: 0 -20px 60px rgba(0,0,0,0.6);
}
.custom-select-sheet.show { transform: translateY(0); }

.custom-select-handle {
  width: 40px;
  height: 4px;
  background: var(--border-hover);
  border-radius: 2px;
  margin: 4px auto 14px;
}
.custom-select-list { padding: 0 8px; }
.custom-select-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 16px 14px;
  background: transparent;
  border: none;
  color: var(--text-primary);
  font-size: 15px;
  font-weight: 500;
  text-align: left;
  cursor: pointer;
  border-radius: var(--radius-md);
  transition: background 0.15s ease;
}
.custom-select-item:hover,
.custom-select-item:active {
  background: var(--bg-elevated);
}
.custom-select-radio {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid var(--border-hover);
  flex-shrink: 0;
  position: relative;
  transition: border-color 0.15s ease, background 0.15s ease;
}
.custom-select-item.selected .custom-select-radio {
  border-color: var(--accent);
  background: var(--accent);
}
.custom-select-item.selected .custom-select-radio::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #fff;
}
.custom-select-item.selected .custom-select-label {
  color: var(--accent);
  font-weight: 600;
}

/* ============================================
   DOWNLOAD MENU
============================================ */
.download-menu {
  position: absolute;
  top: calc(100% + 6px);
  left: 0;
  min-width: 220px;
  background: var(--bg-card);
  border: 1px solid var(--border-hover);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-modal);
  padding: 6px;
  z-index: 999;
  display: none;
  animation: fadeUp 0.15s ease both;
}
.download-menu.open { display: block; }
.download-menu-header {
  padding: 8px 12px;
  font-size: 11px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 4px;
}
.download-menu-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--text-primary);
  transition: var(--transition);
}
.download-menu-item:hover {
  background: var(--bg-elevated);
  color: var(--accent);
}
.download-menu-item svg { color: var(--accent); }
.download-menu-size {
  margin-left: auto;
  font-size: 10.5px;
  color: var(--text-muted);
  background: var(--bg-elevated);
  padding: 2px 6px;
  border-radius: 4px;
}

/* ============================================
   TOAST
============================================ */
.anivora-toast {
  position: fixed;
  bottom: 90px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--bg-elevated);
  color: var(--text-primary);
  border: 1px solid var(--border-hover);
  padding: 10px 20px;
  border-radius: var(--radius-md);
  font-size: 13px;
  font-weight: 500;
  box-shadow: var(--shadow-modal);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.25s ease, transform 0.25s ease, visibility 0.25s;
  z-index: 5000;
}
.anivora-toast.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* ============================================
   LIST CATEGORY TABS (Watchlist)
============================================ */
.list-category-tabs {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 20px;
}
.list-cat-btn {
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 12.5px;
  font-weight: 500;
  background: var(--bg-elevated);
  color: var(--text-secondary);
  border: 1px solid var(--border);
}
.list-cat-btn.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}

/* ============================================
   STAT CARD (Profile / Admin)
============================================ */
.stat-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: var(--transition);
}
.stat-card:hover {
  transform: translateY(-2px);
  border-color: var(--border-hover);
}
.stat-card-icon {
  width: 38px;
  height: 38px;
  border-radius: 9px;
  background: var(--accent-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 14px;
  color: var(--accent);
}
.stat-card-value {
  font-size: 26px;
  font-weight: 800;
  display: block;
  margin-bottom: 4px;
}
.stat-card-label {
  font-size: 12px;
  color: var(--text-muted);
  font-weight: 500;
}
.stat-card-change {
  font-size: 11.5px;
  color: var(--success);
  margin-top: 6px;
  display: flex;
  align-items: center;
  gap: 3px;
}

/* ============================================
   ADMIN TABLE
============================================ */
.admin-table-wrap {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  margin-bottom: 24px;
}
.admin-table-header {
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.admin-table {
  width: 100%;
  border-collapse: collapse;
}
.admin-table th {
  text-align: left;
  padding: 10px 16px;
  font-size: 11px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  border-bottom: 1px solid var(--border);
  background: var(--bg-elevated);
}
.admin-table td {
  padding: 12px 16px;
  font-size: 13.5px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.table-actions {
  display: flex;
  gap: 6px;
}
.table-btn {
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 11.5px;
  font-weight: 500;
  border: 1px solid var(--border);
  background: var(--bg-elevated);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  gap: 4px;
}
.table-btn.danger {
  color: var(--danger);
  border-color: rgba(224,85,85,0.28);
}

/* ============================================
   AUTH CARD
============================================ */
.auth-card {
  width: 100%;
  max-width: 400px;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 36px;
}
.auth-title {
  font-size: 20px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 6px;
}
.auth-subtitle {
  font-size: 13px;
  color: var(--text-muted);
  text-align: center;
  margin-bottom: 28px;
}
.auth-divider {
  text-align: center;
  position: relative;
  margin: 20px 0;
  color: var(--text-muted);
  font-size: 12px;
}
.auth-divider::before,
.auth-divider::after {
  content: '';
  position: absolute;
  top: 50%;
  width: 42%;
  height: 1px;
  background: var(--border);
}
.auth-divider::before { left: 0; }
.auth-divider::after { right: 0; }
.auth-switch {
  text-align: center;
  margin-top: 20px;
  font-size: 13px;
  color: var(--text-muted);
}
.auth-switch a {
  color: var(--accent);
  font-weight: 500;
}

/* ============================================
   WATCHLIST BADGES
============================================ */
.wl-badges {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-top: 6px;
}
.wl-badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 2px 8px;
  border-radius: 20px;
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.3px;
}
.wl-badge-watching {
  background: rgba(76,175,128,0.14);
  color: var(--success);
  border: 1px solid rgba(76,175,128,0.28);
}
.wl-badge-fav {
  background: rgba(255,120,160,0.14);
  color: #ff78a0;
  border: 1px solid rgba(255,120,160,0.28);
}
.wl-badge-list {
  background: var(--accent-dim);
  color: var(--accent);
  border: 1px solid rgba(108,99,255,0.28);
}

/* در موبایل، دکمه‌های Remove کوچیک‌تر */
@media (max-width: 480px) {
  .watchlist-item .btn-sm {
    padding: 5px 10px;
    font-size: 11px;
  }
}

/* ============================================
   LIST STATUS SHEET — 4 Options (Modern)
============================================ */
.list-status-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 4500;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.list-status-overlay.show { opacity: 1; }

.list-status-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #0d0d14;
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  border-top: 1px solid rgba(255,255,255,0.08);
  z-index: 4501;
  padding: 8px 14px 26px;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  max-width: 520px;
  margin: 0 auto;
  box-shadow: 0 -20px 60px rgba(0,0,0,0.7);
  max-height: 90vh;
  overflow-y: auto;
}
.list-status-sheet.show { transform: translateY(0); }

.list-status-handle {
  width: 44px;
  height: 4px;
  background: rgba(255,255,255,0.18);
  border-radius: 2px;
  margin: 6px auto 18px;
}

.list-status-title {
  font-size: 13px;
  font-weight: 700;
  color: var(--text-secondary);
  text-align: center;
  letter-spacing: 1.5px;
  margin-bottom: 20px;
  text-transform: uppercase;
}

.list-status-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 15px 16px;
  background: #17171f;
  border: 1px solid rgba(255,255,255,0.05);
  color: var(--text-primary);
  text-align: left;
  cursor: pointer;
  border-radius: 14px;
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.15s ease;
  margin-bottom: 10px;
  position: relative;
}
.list-status-item:hover {
  background: #1d1d28;
  border-color: rgba(255,255,255,0.1);
}
.list-status-item:active {
  transform: scale(0.985);
}
.list-status-item::before {
  content: '';
  position: absolute;
  left: 0;
  top: 12px;
  bottom: 12px;
  width: 3px;
  border-radius: 0 3px 3px 0;
  background: transparent;
  transition: background 0.2s ease;
}
.list-status-item[data-status="not_watched"]::before    { background: rgba(136,136,160,0.6); }
.list-status-item[data-status="plan_to_watch"]::before  { background: rgba(64,196,255,0.8); }
.list-status-item[data-status="completed"]::before      { background: rgba(76,175,128,0.8); }
.list-status-item[data-status="watching"]::before       { background: rgba(108,99,255,0.9); }
.list-status-item.selected {
  background: #1f1f2d;
  border-color: rgba(108,99,255,0.35);
}

.list-status-radio {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  border: 2px solid rgba(255,255,255,0.22);
  flex-shrink: 0;
  position: relative;
  transition: border-color 0.18s ease, background 0.18s ease;
}
.list-status-item.selected .list-status-radio {
  border-color: var(--accent);
  background: var(--accent);
}
.list-status-item.selected .list-status-radio::after {
  content: '';
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #fff;
}
.list-status-name {
  font-size: 15px;
  font-weight: 600;
  flex-shrink: 0;
  letter-spacing: 0.2px;
}

.list-status-watching {
  flex-wrap: wrap;
  padding-bottom: 16px;
}
.list-status-watching-body {
  flex-basis: 100%;
  margin-top: 16px;
  padding-left: 34px;
  padding-right: 4px;
}
.list-status-progress-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 16px;
}
.list-status-progress-count {
  font-size: 12px;
  color: #a9a4ff;
  font-weight: 700;
  min-width: 48px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  direction: ltr;
  background: rgba(108,99,255,0.12);
  border: 1px solid rgba(108,99,255,0.28);
  border-radius: 8px;
  padding: 4px 6px;
}
.list-status-slider-wrap {
  flex: 1;
  position: relative;
  padding: 10px 0;
  user-select: none;
  -webkit-user-select: none;
  touch-action: none;
}
.list-status-slider-track {
  width: 100%;
  height: 6px;
  background: rgba(255,255,255,0.08);
  border-radius: 3px;
  overflow: visible;
  position: relative;
}
.list-status-slider-fill {
  height: 100%;
  background: linear-gradient(90deg, #6c63ff, #8b85ff);
  border-radius: 3px;
  transition: width 0.05s linear;
  box-shadow: 0 0 8px rgba(108,99,255,0.4);
}
.list-status-slider-thumb {
  position: absolute;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  border-radius: 50%;
  background: var(--accent);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 11px;
  font-weight: 700;
  box-shadow: 0 2px 10px rgba(108,99,255,0.6);
  cursor: grab;
  font-variant-numeric: tabular-nums;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
  border: 2px solid #0d0d14;
  z-index: 2;
}
.list-status-slider-thumb:hover {
  transform: translate(-50%, -50%) scale(1.1);
  box-shadow: 0 3px 14px rgba(108,99,255,0.8);
}
.list-status-slider-thumb:active,
.list-status-slider-thumb.dragging {
  cursor: grabbing;
  transform: translate(-50%, -50%) scale(1.15);
  box-shadow: 0 4px 16px rgba(108,99,255,0.95);
}

.list-status-checkbox-row {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
  color: var(--text-secondary);
  cursor: pointer;
  padding: 4px 0;
  user-select: none;
  -webkit-user-select: none;
}
.list-status-checkbox-row input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.22);
  border-radius: 7px;
  background: transparent;
  cursor: pointer;
  flex-shrink: 0;
  position: relative;
  transition: all 0.18s ease;
  margin: 0;
}
.list-status-checkbox-row input[type="checkbox"]:hover {
  border-color: var(--accent);
  background: rgba(108,99,255,0.08);
}
.list-status-checkbox-row input[type="checkbox"]:checked {
  background: var(--accent);
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(108,99,255,0.15);
}
.list-status-checkbox-row input[type="checkbox"]:checked::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 6px;
  width: 5px;
  height: 10px;
  border: solid #fff;
  border-width: 0 2.2px 2.2px 0;
  transform: rotate(45deg);
  border-radius: 1px;
}
.list-status-checkbox-row:hover {
  color: var(--text-primary);
}

.list-status-actions-row {
  display: flex;
  gap: 10px;
  margin-top: 18px;
  margin-bottom: 0;
}
.list-status-actions-row .list-status-item {
  flex: 1;
  justify-content: center !important;
  padding: 13px 16px !important;
  margin-bottom: 0 !important;
  border-radius: 12px !important;
  gap: 8px !important;
}
.list-status-actions-row .list-status-item::before {
  display: none !important;
}
.list-status-actions-row .list-status-item .list-status-radio {
  display: none !important;
}
.list-status-actions-row .list-status-item .list-status-name {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.5px;
}
.list-status-item-danger {
  background: rgba(224,85,85,0.1) !important;
  border: 1px solid rgba(224,85,85,0.28) !important;
}
.list-status-item-danger .list-status-name {
  color: var(--danger);
}
.list-status-item-danger:hover {
  background: rgba(224,85,85,0.18) !important;
  border-color: rgba(224,85,85,0.5) !important;
}
.list-status-item-save {
  background: rgba(108,99,255,0.12) !important;
  border: 1px solid rgba(108,99,255,0.32) !important;
}
.list-status-item-save .list-status-name {
  color: var(--accent);
}
.list-status-item-save:hover {
  background: rgba(108,99,255,0.22) !important;
  border-color: rgba(108,99,255,0.55) !important;
}
.list-status-item-save:active {
  transform: scale(0.98);
}

/* ============================================
   DOWNLOAD SHEET
============================================ */
.download-sheet-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.65);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  z-index: 4800;
  opacity: 0;
  transition: opacity 0.25s ease;
}
.download-sheet-overlay.show { opacity: 1; }

.download-sheet {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #0d0d14;
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  border-top: 1px solid rgba(255,255,255,0.08);
  z-index: 4801;
  padding: 8px 0 20px;
  transform: translateY(100%);
  transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
  max-width: 520px;
  margin: 0 auto;
  box-shadow: 0 -20px 60px rgba(0,0,0,0.7);
  max-height: 80vh;
  display: flex;
  flex-direction: column;
}
.download-sheet.show { transform: translateY(0); }

.download-sheet-handle {
  width: 44px;
  height: 4px;
  background: rgba(255,255,255,0.18);
  border-radius: 2px;
  margin: 6px auto 12px;
}

.download-sheet-header {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 0 16px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.download-sheet-header-left,
.download-sheet-header-right {
  width: 34px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
}
.download-sheet-header-right { justify-content: flex-end; }

.download-sheet-back,
.download-sheet-close {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--bg-elevated);
  color: var(--text-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: var(--transition);
  cursor: pointer;
  border: none;
}
.download-sheet-back:hover,
.download-sheet-close:hover {
  background: var(--bg-hover);
}
.download-sheet-back { display: none; }

.download-sheet-title {
  flex: 1;
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.download-sheet-body {
  padding: 16px 12px 4px;
  overflow-y: auto;
  flex: 1;
  min-height: 0;
}

.download-sheet-subtitle {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 0 6px 12px;
}

.download-ep-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.download-ep-item {
  display: flex;
  align-items: center;
  gap: 14px;
  width: 100%;
  padding: 14px;
  background: #17171f;
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
  color: var(--text-primary);
  text-align: left;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.download-ep-item:hover {
  background: #1d1d28;
  border-color: rgba(108,99,255,0.4);
}
.download-ep-item:active {
  transform: scale(0.99);
}

.download-ep-num {
  font-size: 12px;
  font-weight: 800;
  color: var(--accent);
  background: rgba(108,99,255,0.12);
  border: 1px solid rgba(108,99,255,0.28);
  border-radius: 8px;
  padding: 5px 9px;
  flex-shrink: 0;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.5px;
}

.download-ep-info {
  flex: 1;
  min-width: 0;
}
.download-ep-name {
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.download-ep-dur {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.download-ep-arrow {
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ============================================
   DOWNLOAD QUALITY (با دکمه کپی)
============================================ */
.download-quality-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

/* ★ هر کیفیت = کارت اصلی + دکمه کپی کنارش */
.download-quality-item {
  display: flex;
  align-items: stretch;
  background: #17171f;
  border: 1px solid rgba(255,255,255,0.05);
  border-radius: 12px;
  overflow: hidden;
  transition: background 0.15s ease, border-color 0.15s ease;
}
.download-quality-item:hover {
  background: #1d1d28;
  border-color: rgba(108,99,255,0.4);
}

/* بخش اصلی (لینک دانلود) */
.download-quality-main {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 14px;
  color: var(--text-primary);
  text-decoration: none;
  min-width: 0;
  cursor: pointer;
}
.download-quality-main:hover {
  color: var(--text-primary);
}

/* ★ دکمه کپی */
.download-quality-copy {
  flex-shrink: 0;
  width: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  border: none;
  border-left: 1px solid rgba(255,255,255,0.06);
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.download-quality-copy:hover {
  background: rgba(108,99,255,0.12);
  color: var(--accent);
}
.download-quality-copy:active {
  transform: scale(0.95);
}
.download-quality-copy.copied {
  background: rgba(76,175,128,0.12);
}

.download-quality-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  background: rgba(108,99,255,0.12);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.download-quality-info {
  flex: 1;
  min-width: 0;
}
.download-quality-label {
  font-size: 15px;
  font-weight: 700;
}
.download-quality-desc {
  font-size: 11.5px;
  color: var(--text-muted);
  margin-top: 2px;
}

.download-quality-arrow {
  color: var(--text-muted);
  flex-shrink: 0;
}

/* ============================================
   DOWNLOAD LOADING
============================================ */
.dl-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  padding: 60px 20px;
}

.dl-loading-spinner {
  width: 40px;
  height: 40px;
  border: 3px solid rgba(108,99,255,0.18);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: dlSpin 0.75s linear infinite;
}

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

.dl-loading-text {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 500;
}