/* ═══════════════════════════════════════════════════════════════════════
   STREAMTALOGUE — Gamification & UI CSS v2.0
   ═══════════════════════════════════════════════════════════════════════ */

/* ── 1. XP Widget (navbar/profil) ────────────────────────────────────── */
.stl-xp-widget {
  background: linear-gradient(135deg, #13131e 0%, #1c1a2e 100%);
  border: 1px solid rgba(124,106,255,.25);
  border-radius: 12px;
  padding: 14px 18px;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 20px;
}
.stl-xp-level-icon { font-size: 30px; flex: 0 0 auto; }
.stl-xp-level-info { flex: 1; min-width: 0; }
.stl-xp-level-name {
  font-size: 11px;
  font-weight: 800;
  color: #a78bfa;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.stl-xp-total {
  font-size: 20px;
  font-weight: 900;
  color: #fff;
  line-height: 1.1;
}
.stl-xp-total small { font-size: 12px; color: #6b7280; font-weight: 400; }
.stl-xp-bar-wrap { margin-top: 6px; }
.stl-xp-bar-wrap small { font-size: 11px; color: #6b7280; }
.stl-xp-track {
  height: 5px;
  background: rgba(255,255,255,.1);
  border-radius: 99px;
  overflow: hidden;
  margin-bottom: 3px;
}
.stl-xp-fill {
  height: 100%;
  background: linear-gradient(90deg, #7c6aff, #a78bfa);
  border-radius: 99px;
  transition: width .7s cubic-bezier(.4,0,.2,1);
}
.stl-xp-bar-lg .stl-xp-track { height: 8px; }

/* ── 2. Widget Search-Add ─────────────────────────────────────────────── */
.stl-add-wrap { max-width: 880px; margin: 0 auto; }

.stl-search-add-bar {
  display: flex;
  gap: 10px;
  align-items: center;
  background: #13131e;
  border: 1.5px solid rgba(124,106,255,.3);
  border-radius: 14px;
  padding: 12px 18px;
  margin-bottom: 16px;
  transition: border-color .18s, box-shadow .18s;
}
.stl-search-add-bar:focus-within {
  border-color: rgba(124,106,255,.6);
  box-shadow: 0 0 0 3px rgba(124,106,255,.1);
}
.stl-search-add-bar input[type=text] {
  flex: 1;
  background: transparent;
  border: none;
  color: #eeeef8;
  font-size: 16px;
  outline: none;
  padding: 2px 0;
}
.stl-search-add-bar input::placeholder { color: #4b5563; }
.stl-search-add-bar .stl-search-spinner { font-size: 18px; display: none; }

/* Pills type */
.stl-type-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.stl-type-pill {
  padding: 6px 16px;
  border-radius: 50px;
  border: 1.5px solid rgba(255,255,255,.1);
  background: transparent;
  color: #9ca3af;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.stl-type-pill.active,
.stl-type-pill:hover {
  background: #7c6aff;
  color: #fff;
  border-color: #7c6aff;
}

/* ── 3. Résultats recherche ───────────────────────────────────────────── */
.stl-results-cols {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-bottom: 16px;
}
@media (max-width: 640px) { .stl-results-cols { grid-template-columns: 1fr; } }

.stl-results-col h4 {
  font-size: 11px;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 700;
  margin: 0 0 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,.06);
}

.stl-result-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 10px;
  border-radius: 10px;
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.06);
  margin-bottom: 6px;
  transition: all .15s;
  cursor: pointer;
}
.stl-result-item:hover {
  background: rgba(124,106,255,.1);
  border-color: rgba(124,106,255,.25);
}
.stl-result-item img,
.stl-result-thumb {
  width: 34px;
  height: 50px;
  object-fit: cover;
  border-radius: 5px;
  flex: 0 0 34px;
}
.stl-result-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  background: rgba(255,255,255,.05);
  color: #6b7280;
}
.stl-result-thumb-sq { height: 34px; }
.stl-result-info { flex: 1; min-width: 0; }
.stl-result-title {
  font-size: 13px;
  font-weight: 700;
  color: #eeeef8;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.stl-result-meta { font-size: 11px; color: #6b7280; margin-top: 2px; }
.stl-result-type-badge {
  font-size: 10px;
  padding: 2px 7px;
  border-radius: 50px;
  background: rgba(124,106,255,.2);
  color: #a78bfa;
  font-weight: 700;
  letter-spacing: .04em;
  white-space: nowrap;
}
.stl-result-add-btn {
  padding: 5px 12px;
  border-radius: 7px;
  border: 1px solid rgba(124,106,255,.4);
  background: transparent;
  color: #a78bfa;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: all .15s;
}
.stl-result-add-btn:hover { background: #7c6aff; color: #fff; border-color: #7c6aff; }

.stl-result-view-btn {
  padding: 5px 12px;
  border-radius: 7px;
  border: 1px solid rgba(34,197,94,.3);
  background: transparent;
  color: #22c55e;
  font-size: 12px;
  font-weight: 600;
  text-decoration: none;
  white-space: nowrap;
  transition: all .15s;
}
.stl-result-view-btn:hover { background: #22c55e; color: #fff; }

.stl-tmdb-import-btn {
  padding: 6px 16px;
  border-radius: 8px;
  background: linear-gradient(135deg, #7c6aff, #a78bfa);
  color: #fff;
  border: none;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: opacity .15s, transform .15s;
  white-space: nowrap;
}
.stl-tmdb-import-btn:hover { opacity: .88; transform: translateY(-1px); }
.stl-tmdb-import-btn:disabled { opacity: .4; cursor: default; transform: none; }

/* États vides */
.stl-results-empty {
  text-align: center;
  padding: 30px;
  color: #4b5563;
  font-size: 14px;
}
.stl-results-placeholder {
  text-align: center;
  padding: 40px;
  color: #374151;
  font-size: 14px;
}
.stl-results-placeholder span { font-size: 40px; display: block; margin-bottom: 10px; }

.stl-not-found-hint {
  background: rgba(124,106,255,.07);
  border: 1px dashed rgba(124,106,255,.25);
  border-radius: 12px;
  padding: 18px 20px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}
.stl-not-found-hint p { margin: 0; color: #9ca3af; font-size: 13px; flex: 1; }
.stl-not-found-btns { display: flex; gap: 8px; flex-wrap: wrap; }

.stl-btn-add-new {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 9px 18px;
  border-radius: 9px;
  border: none;
  background: #7c6aff;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  transition: background .15s, transform .15s;
}
.stl-btn-add-new:hover { background: #6a58f0; transform: translateY(-1px); }
.stl-btn-add-new.movie  { background: #c026d3; }
.stl-btn-add-new.movie:hover  { background: #a21caf; }
.stl-btn-add-new.person { background: #0891b2; }
.stl-btn-add-new.person:hover { background: #0e7490; }

/* XP preview */
.stl-xp-preview {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 50px;
  background: rgba(124,106,255,.2);
  color: #a78bfa;
  font-size: 11px;
  font-weight: 800;
  margin-left: 6px;
}

/* ── 4. Modal ─────────────────────────────────────────────────────────── */
.stl-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.82);
  z-index: 99998;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 16px;
  backdrop-filter: blur(4px);
}
.stl-modal-overlay.open { display: flex; }

.stl-modal {
  background: #13131e;
  border: 1px solid rgba(124,106,255,.25);
  border-radius: 18px;
  width: 100%;
  max-width: 600px;
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 24px 80px rgba(0,0,0,.7);
  scrollbar-width: thin;
  scrollbar-color: rgba(124,106,255,.3) transparent;
}
.stl-modal::-webkit-scrollbar { width: 5px; }
.stl-modal::-webkit-scrollbar-thumb { background: rgba(124,106,255,.3); border-radius: 99px; }

.stl-modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  border-bottom: 1px solid rgba(255,255,255,.07);
  position: sticky;
  top: 0;
  background: #13131e;
  z-index: 1;
}
.stl-modal-header h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 800;
  color: #eeeef8;
  letter-spacing: -.01em;
}
.stl-modal-close {
  background: rgba(255,255,255,.06);
  border: none;
  color: #9ca3af;
  font-size: 18px;
  cursor: pointer;
  line-height: 1;
  padding: 6px 10px;
  border-radius: 8px;
  transition: all .15s;
}
.stl-modal-close:hover { background: rgba(255,255,255,.12); color: #fff; }
.stl-modal-body { padding: 20px 24px; }

/* TMDB bar dans modal */
.stl-modal-tmdb-bar {
  background: rgba(124,106,255,.08);
  border: 1px solid rgba(124,106,255,.2);
  border-radius: 10px;
  padding: 12px 16px;
  margin-bottom: 18px;
  display: flex;
  gap: 8px;
  align-items: center;
  flex-wrap: wrap;
}
.stl-modal-tmdb-bar input {
  flex: 1;
  min-width: 140px;
  background: rgba(255,255,255,.06);
  border: 1px solid rgba(255,255,255,.1);
  color: #fff;
  border-radius: 7px;
  padding: 7px 12px;
  font-size: 13px;
  outline: none;
  transition: border-color .15s;
}
.stl-modal-tmdb-bar input:focus { border-color: rgba(124,106,255,.5); }
.stl-modal-tmdb-bar input::placeholder { color: #4b5563; }

.stl-tmdb-results-mini {
  width: 100%;
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.stl-tmdb-mini-item {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  color: #d1d5db;
  transition: all .15s;
}
.stl-tmdb-mini-item:hover {
  background: rgba(124,106,255,.18);
  border-color: rgba(124,106,255,.4);
  color: #fff;
}
.stl-tmdb-mini-item img { width: 24px; height: 36px; object-fit: cover; border-radius: 3px; }

/* Formulaire modal */
.stl-modal-form .stl-field { margin-bottom: 14px; }
.stl-modal-form .stl-field label {
  color: #9ca3af;
  font-size: 12px;
  font-weight: 700;
  margin-bottom: 5px;
  display: block;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.stl-modal-form .stl-field input[type=text],
.stl-modal-form .stl-field input[type=number],
.stl-modal-form .stl-field input[type=url],
.stl-modal-form .stl-field textarea,
.stl-modal-form .stl-field select {
  width: 100%;
  background: rgba(255,255,255,.05);
  border: 1.5px solid rgba(255,255,255,.1);
  color: #eeeef8;
  border-radius: 9px;
  padding: 10px 14px;
  font-size: 14px;
  box-sizing: border-box;
  outline: none;
  transition: border-color .15s, box-shadow .15s;
}
.stl-modal-form .stl-field input:focus,
.stl-modal-form .stl-field textarea:focus,
.stl-modal-form .stl-field select:focus {
  border-color: rgba(124,106,255,.6);
  box-shadow: 0 0 0 3px rgba(124,106,255,.1);
}
.stl-modal-form .stl-field textarea { min-height: 90px; resize: vertical; line-height: 1.6; }
.stl-modal-form .stl-field select option { background: #13131e; }

.stl-field-row { display: flex; gap: 12px; }
.stl-field-row .stl-field { flex: 1; }

.stl-genres-picker { display: flex; flex-wrap: wrap; gap: 6px; }
.stl-genre-pill {
  padding: 5px 13px;
  border-radius: 50px;
  border: 1.5px solid rgba(255,255,255,.1);
  background: transparent;
  color: #9ca3af;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.stl-genre-pill.selected { background: #7c6aff; color: #fff; border-color: #7c6aff; }

.stl-poster-preview-wrap { margin-top: 8px; }
.stl-poster-preview-wrap img { max-width: 72px; border-radius: 6px; box-shadow: 0 4px 12px rgba(0,0,0,.4); }

.stl-modal-footer {
  padding: 16px 24px;
  border-top: 1px solid rgba(255,255,255,.07);
  display: flex;
  justify-content: flex-end;
  gap: 10px;
}
.stl-btn-cancel {
  padding: 10px 22px;
  border-radius: 9px;
  background: transparent;
  border: 1.5px solid rgba(255,255,255,.12);
  color: #9ca3af;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.stl-btn-cancel:hover { border-color: rgba(255,255,255,.3); color: #eeeef8; }

.stl-btn-submit {
  padding: 10px 28px;
  border-radius: 9px;
  background: linear-gradient(135deg, #7c6aff, #6a58f0);
  border: none;
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  cursor: pointer;
  transition: opacity .15s, transform .15s;
  letter-spacing: .02em;
}
.stl-btn-submit:hover { opacity: .88; transform: translateY(-1px); }
.stl-btn-submit:disabled { opacity: .4; cursor: default; transform: none; }

/* ── 5. Toast notifications ───────────────────────────────────────────── */
.stl-toast-container {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.stl-toast {
  background: #1c1c2a;
  border: 1px solid rgba(124,106,255,.3);
  border-radius: 14px;
  padding: 14px 18px;
  box-shadow: 0 12px 40px rgba(0,0,0,.6);
  display: flex;
  align-items: flex-start;
  gap: 12px;
  min-width: 270px;
  max-width: 340px;
  animation: stlToastIn .35s cubic-bezier(.34,1.56,.64,1) forwards;
  pointer-events: auto;
}
.stl-toast.hide { animation: stlToastOut .28s ease forwards; }

.stl-toast-icon { font-size: 28px; flex: 0 0 auto; line-height: 1; }
.stl-toast-body { flex: 1; }
.stl-toast-title { font-size: 14px; font-weight: 800; color: #eeeef8; }
.stl-toast-msg   { font-size: 12px; color: #9ca3af; margin-top: 3px; line-height: 1.5; }
.stl-toast-xp {
  display: inline-block;
  margin-top: 5px;
  padding: 2px 9px;
  border-radius: 50px;
  background: rgba(124,106,255,.2);
  color: #a78bfa;
  font-size: 11px;
  font-weight: 800;
}
.stl-toast-close {
  background: transparent;
  border: none;
  color: #4b5563;
  font-size: 16px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  align-self: flex-start;
  transition: color .15s;
}
.stl-toast-close:hover { color: #eeeef8; }

@keyframes stlToastIn {
  from { opacity: 0; transform: translateX(40px) scale(.9); }
  to   { opacity: 1; transform: translateX(0) scale(1); }
}
@keyframes stlToastOut {
  from { opacity: 1; transform: translateX(0); }
  to   { opacity: 0; transform: translateX(30px); }
}

/* XP float animation */
.stl-xp-float {
  position: fixed;
  pointer-events: none;
  z-index: 99999;
  font-size: 17px;
  font-weight: 900;
  color: #a78bfa;
  text-shadow: 0 2px 10px rgba(124,106,255,.6);
  animation: stlXpFloat 1.5s ease forwards;
}
@keyframes stlXpFloat {
  0%   { opacity: 1; transform: translateY(0) scale(1); }
  50%  { opacity: 1; transform: translateY(-44px) scale(1.15); }
  100% { opacity: 0; transform: translateY(-72px) scale(.85); }
}

/* ── 6. Leaderboard ───────────────────────────────────────────────────── */
.stl-leaderboard-wrap { max-width: 720px; }

.stl-leaderboard-table {
  width: 100%;
  border-collapse: collapse;
  background: #13131e;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(124,106,255,.15);
}
.stl-leaderboard-table thead th {
  padding: 12px 16px;
  font-size: 10px;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: #4b5563;
  background: rgba(255,255,255,.02);
  text-align: left;
  border-bottom: 1px solid rgba(255,255,255,.05);
}
.stl-leaderboard-table tbody tr {
  border-bottom: 1px solid rgba(255,255,255,.04);
  transition: background .15s;
}
.stl-leaderboard-table tbody tr:hover { background: rgba(124,106,255,.06); }
.stl-leaderboard-table tbody tr:last-child { border-bottom: none; }
.stl-leaderboard-table td {
  padding: 12px 16px;
  color: #d1d5db;
  font-size: 14px;
  vertical-align: middle;
}

.stl-lb-rank { font-size: 22px; text-align: center; width: 52px; }
.stl-lb-user { display: flex; align-items: center; gap: 12px; }
.stl-lb-avatar {
  width: 38px; height: 38px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid rgba(255,255,255,.1);
}
.stl-lb-name { font-weight: 700; color: #eeeef8; font-size: 15px; }
.stl-lb-level { font-size: 12px; color: #a78bfa; margin-top: 1px; }
.stl-lb-xp { font-weight: 900; color: #7c6aff; font-size: 16px; }
.stl-lb-badges { color: #f0c040; font-weight: 700; }

.stl-lb-me { background: rgba(124,106,255,.1) !important; }
.stl-lb-me td { color: #eeeef8; }
.stl-lb-me .stl-lb-name { color: #a78bfa; }

.stl-lb-footer {
  margin-top: 14px;
  padding: 14px 18px;
  background: rgba(124,106,255,.07);
  border: 1px solid rgba(124,106,255,.15);
  border-radius: 10px;
  font-size: 13px;
  color: #9ca3af;
  display: flex;
  align-items: center;
  gap: 12px;
}
.stl-lb-footer strong { color: #eeeef8; }

/* ── 7. Page Badges ───────────────────────────────────────────────────── */
.stl-badges-wrap { max-width: 900px; }

/* Carte XP profil (page badges) */
.stl-xp-profile-card {
  background: linear-gradient(135deg, #13131e 0%, #1c1a2e 100%);
  border: 1px solid rgba(124,106,255,.25);
  border-radius: 18px;
  padding: 24px 28px;
  display: flex;
  align-items: center;
  gap: 24px;
  margin-bottom: 28px;
  flex-wrap: wrap;
  position: relative;
  overflow: hidden;
}
.stl-xp-profile-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, #7c6aff, #a78bfa, #f0c040);
}
.stl-xp-profile-level { display: flex; align-items: center; gap: 16px; }
.stl-level-big { font-size: 56px; line-height: 1; }
.stl-level-name { font-size: 20px; font-weight: 900; color: #a78bfa; letter-spacing: -.01em; }
.stl-level-num { font-size: 13px; color: #6b7280; margin-top: 2px; font-weight: 600; }
.stl-xp-profile-right { flex: 1; min-width: 180px; }
.stl-xp-big { font-size: 36px; font-weight: 900; color: #eeeef8; letter-spacing: -.02em; }
.stl-xp-big small { font-size: 15px; color: #6b7280; font-weight: 400; }
.stl-badges-earned-count { font-size: 13px; color: #6b7280; margin-top: 8px; }

.stl-badges-subtitle {
  font-size: 11px;
  font-weight: 800;
  color: #4b5563;
  text-transform: uppercase;
  letter-spacing: .1em;
  margin: 0 0 14px;
}

/* Grille de badges */
.stl-badges-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 12px;
  margin-bottom: 32px;
}

.stl-badge-card {
  background: #13131e;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 14px;
  padding: 18px 14px;
  text-align: center;
  transition: all .2s cubic-bezier(.4,0,.2,1);
  position: relative;
  overflow: hidden;
}
.stl-badge-card.earned {
  border-color: rgba(124,106,255,.35);
  background: linear-gradient(135deg, #1a1728, #13131e);
}
.stl-badge-card.earned::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, #7c6aff, #a78bfa);
}
.stl-badge-card.earned:hover {
  border-color: rgba(124,106,255,.6);
  transform: translateY(-3px);
  box-shadow: 0 12px 32px rgba(124,106,255,.2);
}
.stl-badge-card.locked { opacity: .38; filter: grayscale(.6); }

.stl-badge-icon { font-size: 38px; margin-bottom: 10px; line-height: 1; }
.stl-badge-name { font-size: 13px; font-weight: 800; color: #eeeef8; margin-bottom: 5px; letter-spacing: -.01em; }
.stl-badge-desc { font-size: 11px; color: #6b7280; line-height: 1.5; margin-bottom: 6px; }
.stl-badge-date { font-size: 11px; color: #22c55e; font-weight: 600; }
.stl-badge-xp-bonus {
  display: inline-block;
  margin-top: 5px;
  padding: 2px 9px;
  border-radius: 50px;
  background: rgba(124,106,255,.18);
  color: #a78bfa;
  font-size: 11px;
  font-weight: 800;
}
.stl-badge-locked-msg { font-size: 11px; color: #374151; }

/* Historique XP */
.stl-xp-history { display: flex; flex-direction: column; gap: 6px; }
.stl-xp-history-row {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 14px;
  background: #13131e;
  border: 1px solid rgba(255,255,255,.05);
  border-radius: 9px;
  transition: border-color .15s;
}
.stl-xp-history-row:hover { border-color: rgba(255,255,255,.1); }
.stl-xh-label { flex: 1; font-size: 13px; color: #d1d5db; }
.stl-xh-date  { font-size: 11px; color: #4b5563; white-space: nowrap; }
.stl-xh-xp   { font-weight: 800; color: #a78bfa; font-size: 13px; white-space: nowrap; }

/* ── 8. Builder saisons modal ─────────────────────────────────────────── */
.stl-sb-seasons { margin-top: 12px; }

.stl-sb-season {
  background: rgba(255,255,255,.03);
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 10px;
  margin-bottom: 10px;
  overflow: hidden;
}
.stl-sb-season-head {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  background: rgba(255,255,255,.03);
}
.stl-sb-season-title-input {
  flex: 1;
  background: transparent;
  border: none;
  color: #eeeef8;
  font-size: 14px;
  font-weight: 700;
  outline: none;
}
.stl-sb-season-title-input::placeholder { color: #4b5563; }
.stl-sb-btn-rm-season {
  background: transparent;
  border: none;
  color: #6b7280;
  cursor: pointer;
  font-size: 16px;
  padding: 2px 6px;
  border-radius: 5px;
  transition: all .15s;
}
.stl-sb-btn-rm-season:hover { color: #ef4444; background: rgba(239,68,68,.1); }

.stl-sb-episodes { padding: 0 14px 10px; }
.stl-sb-ep {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 0;
  border-bottom: 1px solid rgba(255,255,255,.05);
}
.stl-sb-ep:last-child { border-bottom: none; }
.stl-sb-ep-num { font-size: 12px; font-weight: 800; color: #7c6aff; width: 24px; flex-shrink: 0; }
.stl-sb-ep input {
  flex: 1;
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.08);
  color: #eeeef8;
  border-radius: 6px;
  padding: 5px 9px;
  font-size: 13px;
  outline: none;
  transition: border-color .15s;
}
.stl-sb-ep input:focus { border-color: rgba(124,106,255,.5); }
.stl-sb-ep input::placeholder { color: #4b5563; }
.stl-sb-ep-dur { width: 70px; flex-shrink: 0; }
.stl-sb-ep-watched-cb { accent-color: #7c6aff; width: 16px; height: 16px; cursor: pointer; flex-shrink: 0; }
.stl-sb-btn-rm-ep {
  background: transparent;
  border: none;
  color: #4b5563;
  cursor: pointer;
  font-size: 14px;
  padding: 2px;
  transition: color .15s;
  flex-shrink: 0;
}
.stl-sb-btn-rm-ep:hover { color: #ef4444; }

.stl-sb-btn-add-ep {
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 6px 12px;
  margin-top: 6px;
  background: rgba(124,106,255,.1);
  border: 1px dashed rgba(124,106,255,.3);
  border-radius: 7px;
  color: #a78bfa;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  width: 100%;
  justify-content: center;
}
.stl-sb-btn-add-ep:hover {
  background: rgba(124,106,255,.18);
  border-color: rgba(124,106,255,.5);
}

.stl-sb-btn-add-season {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  padding: 10px;
  margin-top: 10px;
  background: transparent;
  border: 1.5px dashed rgba(255,255,255,.12);
  border-radius: 10px;
  color: #6b7280;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
}
.stl-sb-btn-add-season:hover {
  border-color: rgba(124,106,255,.4);
  color: #a78bfa;
  background: rgba(124,106,255,.05);
}

/* ── 9. States ────────────────────────────────────────────────────────── */
.stl-loading-spinner {
  display: inline-block;
  width: 18px; height: 18px;
  border: 2px solid rgba(255,255,255,.12);
  border-top-color: #7c6aff;
  border-radius: 50%;
  animation: stlSpin .65s linear infinite;
}
@keyframes stlSpin { to { transform: rotate(360deg); } }
.stl-search-loading { text-align: center; padding: 20px; }

.stl-form-success {
  padding: 12px 16px;
  background: rgba(34,197,94,.12);
  border: 1px solid rgba(34,197,94,.25);
  border-radius: 9px;
  color: #22c55e;
  font-size: 13px;
  margin-top: 10px;
}
.stl-form-error {
  padding: 12px 16px;
  background: rgba(239,68,68,.12);
  border: 1px solid rgba(239,68,68,.25);
  border-radius: 9px;
  color: #ef4444;
  font-size: 13px;
  margin-top: 10px;
}

/* Level-up toast */
.stl-levelup-toast {
  border-color: rgba(240,192,64,.5) !important;
  background: linear-gradient(135deg, #1c1a10, #1c1c2a) !important;
}
.stl-levelup-toast .stl-toast-title { color: #f0c040; font-size: 15px; }

/* ── 10. Responsive ───────────────────────────────────────────────────── */
@media (max-width: 640px) {
  .stl-toast-container { bottom: 16px; right: 16px; left: 16px; }
  .stl-toast { min-width: unset; max-width: 100%; }

  .stl-badges-grid { grid-template-columns: repeat(2, 1fr); gap: 10px; }
  .stl-badge-card { padding: 14px 10px; }
  .stl-badge-icon { font-size: 30px; }

  .stl-leaderboard-table th:nth-child(4),
  .stl-leaderboard-table td:nth-child(4) { display: none; }

  .stl-xp-profile-card { padding: 18px; }
  .stl-level-big { font-size: 44px; }
  .stl-xp-big { font-size: 28px; }

  .stl-modal { border-radius: 14px; }
  .stl-modal-body { padding: 16px; }
  .stl-modal-header { padding: 16px; }
  .stl-modal-footer { padding: 12px 16px; }
}
