/* Komponenten: Dashboard, Karten, Badges, Buttons, Detailansicht, Modals, Toasts, Skeletons, Tier-List & Episoden-Ratings */

/* Bento Dashboard */
.dashboard-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 14px;
  margin-bottom: 28px;
}
.dashboard-card {
  background: linear-gradient(180deg, rgba(255,255,255,0.02) 0%, rgba(255,255,255,0) 100%), var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 16px 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.2s ease;
}
.dashboard-card:hover {
  border-color: var(--accent-dim);
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
}
.dash-head { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; }
.dash-label { font-size: 11px; font-weight: 700; color: var(--text-dim); text-transform: uppercase; letter-spacing: 0.06em; }
.dash-icon { font-size: 16px; }
.dash-value { font-family: 'Bebas Neue'; font-size: 34px; color: var(--accent); line-height: 1; text-shadow: 0 2px 10px var(--accent-glow); }
.dash-sub { font-size: 11.5px; color: var(--text-dim); margin-top: 6px; }

/* Movie Grid & Modern Cards */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 14px;
  align-items: start !important;
}

.show-card {
  cursor: pointer;
  display: flex;
  flex-direction: column;
  width: 100%;
  min-width: 0;
  height: 100%;
  position: relative;
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}
.show-card:hover { transform: translateY(-5px); }

/* Garantiert 100% identisches 2:3 Format auf allen Bildschirmen */
.poster-wrap {
  width: 100%;
  aspect-ratio: 2 / 3 !important;
  flex: 0 0 auto !important;
  position: relative !important;
  overflow: hidden;
  border-radius: var(--radius-md);
  background: var(--bg-raised);
  border: 1px solid var(--line);
  margin-bottom: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
  transition: box-shadow 0.25s ease, border-color 0.25s ease;
}
.show-card:hover .poster-wrap {
  border-color: rgba(255, 255, 255, 0.2);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.5);
}

.watched-badge-corner {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 22px;
  height: 22px;
  background: var(--watched);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  font-weight: 800;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4);
  z-index: 2;
}

.poster {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  object-position: center top !important;
  display: block;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}
.show-card:hover .poster { transform: scale(1.04); }

.poster-placeholder {
  position: absolute !important;
  top: 0 !important;
  left: 0 !important;
  width: 100% !important;
  height: 100% !important;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-dim);
  font-family: 'Bebas Neue';
  font-size: 18px;
  text-align: center;
  padding: 8px;
  background: linear-gradient(135deg, var(--bg-raised) 0%, var(--bg-card) 100%);
}

.show-title {
  font-size: 12.5px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 5px;
}

.badge-row {
  display: flex;
  align-items: center;
  gap: 4px;
  height: 20px;
  min-height: 20px;
  margin-top: 2px;
  margin-bottom: 8px;
  overflow: hidden;
  flex-wrap: nowrap;
}

/* Streaming Hub & Provider Cards */
.streaming-hub {
  background: linear-gradient(180deg, rgba(255,255,255,0.025) 0%, rgba(255,255,255,0.005) 100%), var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 12px 16px;
  margin-top: 14px;
  max-width: 540px;
}
.streaming-hub-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 8px;
  flex-wrap: wrap;
  gap: 8px;
}
.streaming-hub-title {
  font-size: 11.5px;
  font-weight: 800;
  color: var(--text);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  display: flex;
  align-items: center;
  gap: 6px;
}
.streaming-links-group {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  align-items: center;
}
.streaming-providers-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.provider-pill {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 5px 10px;
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
}
.provider-icon { font-size: 16px; line-height: 1; }
.provider-name { font-weight: 700; font-size: 12.5px; line-height: 1.2; color: var(--text); }
.provider-type { font-size: 10.5px; color: var(--text-dim); }

.provider-netflix { border-color: rgba(229, 9, 20, 0.4); background: rgba(229, 9, 20, 0.08); }
.provider-prime { border-color: rgba(0, 168, 225, 0.4); background: rgba(0, 168, 225, 0.08); }
.provider-disney { border-color: rgba(17, 60, 207, 0.4); background: rgba(17, 60, 207, 0.08); }
.provider-apple { border-color: rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.06); }
.provider-hbo { border-color: rgba(153, 51, 204, 0.4); background: rgba(153, 51, 204, 0.08); }
.provider-paramount { border-color: rgba(0, 100, 255, 0.4); background: rgba(0, 100, 255, 0.08); }
.provider-hulu { border-color: rgba(28, 231, 131, 0.4); background: rgba(28, 231, 131, 0.08); }
.provider-crunchyroll { border-color: rgba(244, 117, 33, 0.4); background: rgba(244, 117, 33, 0.08); }

.provider-info-hint {
  font-size: 11px;
  color: var(--text-dim);
  margin-top: 8px;
  line-height: 1.4;
}

/* Modern Pill Badges */
.badge {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--text-dim);
  text-decoration: none;
  background: rgba(255, 255, 255, 0.03);
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  max-width: none !important;
  overflow: visible !important;
  text-overflow: clip !important;
  white-space: normal !important;
  transition: all 0.15s ease;
}

.badge-rating {
  color: var(--accent);
  border-color: rgba(245, 197, 24, 0.3);
  background: var(--accent-glow);
}
.badge-link { cursor: pointer; }
.badge-link:hover { background: var(--accent); color: #000; border-color: var(--accent); }
.badge-justwatch { background: rgba(251, 197, 0, 0.1); color: var(--text); border-color: rgba(251, 197, 0, 0.3); }
.badge-netflix { background: rgba(229, 9, 20, 0.15) !important; color: #ff4d4d !important; border-color: rgba(229, 9, 20, 0.4) !important; font-weight: 700 !important; }
.badge-prime { background: rgba(0, 168, 225, 0.15) !important; color: #00a8e1 !important; border-color: rgba(0, 168, 225, 0.4) !important; font-weight: 700 !important; }
.badge-apple { background: rgba(255, 255, 255, 0.1) !important; color: #ffffff !important; border-color: rgba(255, 255, 255, 0.3) !important; font-weight: 700 !important; }
.badge-disney { background: rgba(17, 60, 207, 0.2) !important; color: #58a6ff !important; border-color: rgba(17, 60, 207, 0.5) !important; font-weight: 700 !important; }
.badge-hbo { background: rgba(153, 51, 204, 0.2) !important; color: #d680ff !important; border-color: rgba(153, 51, 204, 0.5) !important; font-weight: 700 !important; }
.badge-hulu { background: rgba(28, 231, 131, 0.15) !important; color: #1ce783 !important; border-color: rgba(28, 231, 131, 0.4) !important; font-weight: 700 !important; }
.badge-paramount { background: rgba(0, 100, 255, 0.15) !important; color: #4da6ff !important; border-color: rgba(0, 100, 255, 0.4) !important; font-weight: 700 !important; }
.badge-justwatch:hover { background: #fbc500; color: #000; border-color: #fbc500; }
.badge-genre { cursor: pointer; }
.badge-genre:hover { color: var(--text); border-color: var(--text-dim); background: rgba(255, 255, 255, 0.08); }
.badge-genre.active { color: #000; background: var(--accent); border-color: var(--accent); font-weight: 700; }

/* Spezifische Tags für Games */
.game-tags-container {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}
.game-tag {
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-size: 13px !important;
  font-weight: 700 !important;
  padding: 7px 14px !important;
  border-radius: 8px !important;
  border: 1px solid var(--line) !important;
  max-width: none !important;
  width: auto !important;
  white-space: normal !important;
  line-height: 1.35 !important;
}
.game-tag-rating { background: rgba(245, 197, 24, 0.15) !important; color: var(--accent) !important; border-color: rgba(245, 197, 24, 0.4) !important; }
.game-tag-metacritic { background: rgba(102, 204, 51, 0.18) !important; color: #79e044 !important; border-color: rgba(102, 204, 51, 0.5) !important; font-weight: 800 !important; }
.game-tag-genre { background: rgba(255, 255, 255, 0.06) !important; color: var(--text) !important; }
.game-tag-dev { background: rgba(59, 130, 246, 0.15) !important; color: #60a5fa !important; border-color: rgba(59, 130, 246, 0.4) !important; }
.game-tag-pub { background: rgba(236, 72, 153, 0.15) !important; color: #f472b6 !important; border-color: rgba(236, 72, 153, 0.4) !important; }
.game-tag-plat { background: rgba(147, 51, 234, 0.18) !important; color: #d8b4fe !important; border-color: rgba(147, 51, 234, 0.45) !important; }

/* Preview & Progress */
.preview-action-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
.preview-category-select {
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--text);
  padding: 8px 12px;
  font-size: 13px;
  font-weight: 600;
  border-radius: var(--radius-sm);
  cursor: pointer;
  height: 38px;
  transition: border-color 0.2s ease;
}
.preview-category-select:focus {
  outline: none;
  border-color: var(--accent);
}
.badge-release {
  background: rgba(56, 161, 105, 0.15) !important;
  color: #48bb78 !important;
  border-color: rgba(56, 161, 105, 0.4) !important;
  font-weight: 700 !important;
}
.progress-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 2px;
  padding-top: 0;
}
.progress-bar { flex: 1; height: 4px; background: rgba(255, 255, 255, 0.08); border-radius: 999px; overflow: hidden; }
.progress-fill { height: 100%; background: var(--accent); border-radius: 999px; transition: width 0.3s ease; }
.progress-fill.completed { background: var(--watched); box-shadow: 0 0 8px var(--watched-glow); }
.progress-text {
  font-size: 11px;
  color: var(--text-dim);
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  display: block;
  max-width: 100%;
}

/* Skeleton-Loader */
.card-skeleton {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: var(--radius-md);
  background: linear-gradient(100deg, var(--bg-raised) 25%, rgba(255, 255, 255, 0.08) 50%, var(--bg-raised) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.4s ease-in-out infinite;
  margin-bottom: 8px;
  border: 1px solid var(--line);
}
.skeleton-line {
  height: 12px;
  border-radius: 4px;
  background: linear-gradient(100deg, var(--bg-raised) 25%, rgba(255, 255, 255, 0.08) 50%, var(--bg-raised) 75%);
  background-size: 200% 100%;
  animation: skeletonShimmer 1.4s ease-in-out infinite;
  margin-bottom: 6px;
}
@keyframes skeletonShimmer {
  0% { background-position: 100% 0; }
  100% { background-position: -100% 0; }
}

/* Buttons */
.add-button {
  background: var(--accent); color: #000; border: none;
  font-weight: 700; font-size: 12px; padding: 7px 10px; border-radius: var(--radius-sm);
  cursor: pointer; width: 100%; transition: all 0.15s ease;
  margin-top: auto !important;
  flex-shrink: 0;
}
.add-button:hover:not(:disabled) { transform: translateY(-1px); filter: brightness(1.08); }
.add-button:active:not(:disabled) { transform: scale(0.98); }
.added-button { background: var(--watched); color: white; opacity: 0.75; cursor: not-allowed; }

.action-btn-secondary {
  background: var(--bg-raised); color: var(--text); border: 1px solid var(--line);
  font-weight: 600; font-size: 13px; padding: 8px 14px; border-radius: var(--radius-sm);
  cursor: pointer; transition: all 0.15s ease;
}
.action-btn-secondary:hover { border-color: var(--text-dim); background: rgba(255, 255, 255, 0.04); }
.remove-btn-dynamic {
  background: rgba(229, 62, 62, 0.15); color: #fc8181; border: 1px solid rgba(229, 62, 62, 0.3);
  font-weight: 600; font-size: 13px; padding: 8px 14px; border-radius: var(--radius-sm); cursor: pointer;
  transition: all 0.15s ease;
}
.remove-btn-dynamic:hover { background: #e53e3e; color: white; }

.back-btn {
  background: var(--bg-raised) !important;
  border: 1px solid var(--line) !important;
  color: var(--text) !important;
  font-size: 13.5px !important;
  font-weight: 700 !important;
  padding: 8px 16px !important;
  border-radius: var(--radius-sm) !important;
  cursor: pointer !important;
  margin-bottom: 20px !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15) !important;
  transition: all 0.15s ease !important;
  z-index: 10 !important;
  position: relative !important;
}
.back-btn:hover {
  background: var(--accent) !important;
  color: #000 !important;
  border-color: var(--accent) !important;
  transform: translateY(-1px) !important;
}

/* Detail View Layout */
.detail-head { display: flex; gap: 32px; margin-bottom: 36px; flex-wrap: wrap; }
.detail-info { flex: 1; min-width: 280px; }
.detail-title-row { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 10px; }
.detail-title-row .detail-title { margin-bottom: 0; }
.favorite-star-btn {
  background: none; border: none; cursor: pointer; font-size: 52px; line-height: 1;
  color: rgba(255, 255, 255, 0.2); transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275); flex-shrink: 0; padding: 0;
}
.favorite-star-btn:hover { color: var(--accent); transform: scale(1.15); filter: drop-shadow(0 0 10px var(--accent-glow)); }
.favorite-star-btn.active { color: var(--accent); text-shadow: 0 0 16px var(--accent-glow); }
.detail-meta { font-size: 14px; color: var(--text-dim); margin-bottom: 14px; font-weight: 500; }
.detail-summary { font-size: 14.8px; line-height: 1.65; color: var(--text-dim); max-width: 65ch; margin-bottom: 18px; }
.detail-badges { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 18px; align-items: center; }
.detail-stats { display: flex; flex-wrap: wrap; gap: 24px; margin-bottom: 20px; }
.stat-num { font-family: 'Bebas Neue'; font-size: 28px; color: var(--accent); line-height: 1; }
.stat-label { font-size: 12px; color: var(--text-dim); font-weight: 500; }

.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  max-width: 540px;
}
.detail-actions select.lang-select {
  max-width: 180px;
}

/* Season Accordion */
.season-block { margin-bottom: 12px; border: 1px solid var(--line); border-radius: var(--radius-md); overflow: hidden; background: var(--bg-raised); }
.season-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 18px; cursor: pointer; background: var(--bg-raised);
  transition: background 0.15s ease;
}
.season-head:hover { background: rgba(255, 255, 255, 0.03); }
.season-head-left { display: flex; align-items: center; gap: 12px; }
.season-name { font-weight: 700; font-size: 15px; }
.season-progress { font-size: 13px; color: var(--text-dim); font-weight: 600; }
.season-toggle-all {
  font-size: 12.5px; font-weight: 700; color: var(--accent); background: none; border: none;
  cursor: pointer; padding: 4px 10px; border-radius: 4px; transition: background 0.15s ease;
}
.season-toggle-all:hover { background: var(--accent-glow); }
.chevron { color: var(--text-dim); font-size: 12px; transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1); }
.season-head.open .chevron { transform: rotate(90deg); }
.season-body { display: none; }
.season-body.open { display: block; }

.ep-row {
  display: flex; align-items: center; gap: 12px; padding: 12px 18px; border-top: 1px solid var(--line);
  cursor: pointer; transition: background 0.15s ease;
}
.ep-row:hover { background: rgba(255, 255, 255, 0.03); }
.ep-check {
  width: 22px; height: 22px; border: 1.5px solid var(--line); border-radius: 5px;
  display: flex; align-items: center; justify-content: center; cursor: pointer; flex-shrink: 0;
  font-size: 13px; color: transparent; transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.ep-check.checked { background: var(--watched); border-color: var(--watched); color: #fff; transform: scale(1.08); box-shadow: 0 0 8px var(--watched-glow); }
.ep-num { font-size: 13px; color: var(--text-dim); width: 56px; flex-shrink: 0; font-variant-numeric: tabular-nums; font-weight: 700; }
.ep-name { font-size: 14.5px; flex: 1; font-weight: 500; }
.ep-date { font-size: 12.5px; color: var(--text-dim); flex-shrink: 0; font-weight: 500; }

/* Episoden-Rating-Badges */
.ep-score {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 32px;
  height: 22px;
  padding: 0 6px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.01em;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
  user-select: none;
}
.ep-score-masterpiece { background: #14532d !important; color: #ffffff !important; border: 1px solid #22c55e; }
.ep-score-great { background: #22c55e !important; color: #000000 !important; }
.ep-score-good { background: #eab308 !important; color: #000000 !important; }
.ep-score-mediocre { background: #f97316 !important; color: #ffffff !important; }
.ep-score-bad { background: #ef4444 !important; color: #ffffff !important; }

/* Toolbar & Filters */
.toolbar-row { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 22px; flex-wrap: wrap; }
.sort-bar {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  color: var(--text-dim);
  white-space: nowrap;
  margin-left: auto;
}
.sort-bar select.lang-select {
  width: auto;
  padding: 4px 10px;
  font-size: 12px;
  height: 28px;
  border-radius: var(--radius-sm);
  background: var(--bg-card);
  color: var(--text);
  font-weight: 600;
  cursor: pointer;
}

/* Modals & Dialogs (Zuverlässig als fixed-Overlay definiert) */
.modal-overlay {
  position: fixed !important;
  top: 0 !important; left: 0 !important; right: 0 !important; bottom: 0 !important;
  width: 100vw !important; height: 100vh !important;
  background: rgba(0, 0, 0, 0.75) !important;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  z-index: 99999 !important;
  opacity: 0 !important;
  visibility: hidden !important;
  pointer-events: none !important;
  transition: opacity 0.25s ease, visibility 0.25s ease !important;
}
.modal-overlay.active { opacity: 1 !important; visibility: visible !important; pointer-events: auto !important; }
.modal-card {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 26px;
  max-width: 480px;
  width: 90%;
  box-shadow: 0 24px 60px rgba(0,0,0,0.6);
  transform: translateY(16px) scale(0.97);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  max-height: 90vh;
  overflow-y: auto;
}
.modal-overlay.active .modal-card { transform: translateY(0) scale(1); }
.modal-title { font-family: 'Bebas Neue'; font-size: 30px; color: var(--text); margin: 0 0 10px; line-height: 1.05; }
.modal-text { font-size: 14.5px; color: var(--text-dim); line-height: 1.55; margin-bottom: 22px; }
.modal-actions { display: flex; gap: 10px; justify-content: flex-end; }
.modal-btn { padding: 9px 18px; border-radius: var(--radius-sm); font-weight: 600; font-size: 13.8px; cursor: pointer; border: none; transition: all 0.15s ease; }
.modal-btn-primary { background: var(--accent); color: #000; font-weight: 700; }
.modal-btn-danger { background: #e53e3e; color: white; }
.modal-btn-secondary { background: rgba(255,255,255,0.06); color: var(--text); }
.modal-btn:hover { transform: translateY(-1px); }

/* Episode Modal */
.ep-modal-img { width: 100%; aspect-ratio: 16/9; object-fit: cover; border-radius: var(--radius-sm); margin-bottom: 14px; background: var(--line); }
.ep-modal-meta { font-size: 13px; color: var(--text-dim); margin-bottom: 12px; display: flex; gap: 14px; flex-wrap: wrap; font-weight: 600; }

/* Achievement Toast */
.achievement-toast {
  position: fixed; bottom: 24px; left: 50%; transform: translateX(-50%) translateY(24px) scale(0.95);
  background: rgba(23, 26, 34, 0.95);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--accent); border-radius: var(--radius-md);
  padding: 14px 20px; display: flex; align-items: center; gap: 14px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.5), 0 0 20px var(--accent-glow);
  z-index: 10000; opacity: 0; transition: all 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  max-width: 360px;
}
.achievement-toast.show { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
.achievement-toast-icon { font-size: 30px; line-height: 1; }
.achievement-toast-label { font-size: 10.5px; color: var(--accent); font-weight: 800; text-transform: uppercase; letter-spacing: 0.08em; }
.achievement-toast-name { font-size: 15px; font-weight: 700; color: var(--text); }

/* Achievements Grid */
.achievements-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); gap: 14px; }
.achievement-card {
  background: var(--bg-raised); border: 1px solid var(--line); border-radius: var(--radius-md);
  padding: 16px; display: flex; gap: 14px; align-items: flex-start;
  transition: transform 0.2s ease, border-color 0.2s ease;
}
.achievement-card:hover { transform: translateY(-2px); border-color: var(--line-light); }
.achievement-card.locked { opacity: 0.45; }
.achievement-card.hidden-locked { opacity: 0.3; }
.achievement-icon { font-size: 28px; line-height: 1; flex-shrink: 0; }
.achievement-name { font-size: 15px; font-weight: 700; margin-bottom: 4px; }
.achievement-desc { font-size: 12.8px; color: var(--text-dim); line-height: 1.5; }
.achievement-date { font-size: 11px; color: var(--accent); margin-top: 8px; font-weight: 600; }

/* Dev Drawer */
#devToolDrawer {
  position: fixed !important;
  top: 0 !important;
  right: -420px !important;
  width: 380px !important;
  height: 100vh !important;
  background: #111318 !important;
  border-left: 2px solid var(--accent) !important;
  box-shadow: -10px 0 30px rgba(0,0,0,0.7) !important;
  z-index: 100000 !important;
  transition: right 0.3s cubic-bezier(0.16, 1, 0.3, 1) !important;
  display: flex !important;
  flex-direction: column !important;
  font-family: 'JetBrains Mono', monospace !important;
}
#devToolDrawer.open { right: 0 !important; }
.dev-header { background: #1a1d24; padding: 14px 16px; border-bottom: 1px solid var(--line); display: flex; justify-content: space-between; align-items: center; }
.dev-header h3 { margin: 0; font-size: 15px; color: var(--accent); font-family: 'Bebas Neue'; letter-spacing: 0.05em; }
.dev-close { background: none; border: none; color: var(--text-dim); font-size: 18px; cursor: pointer; }
.dev-tabs { display: flex; border-bottom: 1px solid var(--line); background: #161820; }
.dev-tab { flex: 1; padding: 10px; font-size: 11px; text-align: center; background: none; border: none; color: var(--text-dim); cursor: pointer; border-bottom: 2px solid transparent; font-family: inherit; }
.dev-tab.active { color: var(--accent); border-bottom-color: var(--accent); background: #1b1e26; font-weight: bold; }
.dev-content { flex: 1; overflow-y: auto; padding: 14px; font-size: 12px; }
.dev-pane { display: none; }
.dev-pane.active { display: block; }
.dev-btn { width: 100%; background: #222630; border: 1px solid var(--line); color: var(--text); padding: 8px 10px; border-radius: 4px; font-size: 11px; cursor: pointer; margin-bottom: 8px; font-family: inherit; }
.dev-btn:hover { background: #2a2f3d; border-color: var(--accent); color: var(--accent); }
.dev-btn-danger { color: #f87171; border-color: #7f1d1d; }
.dev-achieve-item { display: flex; align-items: center; justify-content: space-between; padding: 6px 8px; background: #181b22; border: 1px solid var(--line); margin-bottom: 6px; border-radius: 3px; }
.dev-achieve-item span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 180px; }
.dev-achieve-toggle { background: #282d3b; border: 1px solid var(--line); color: var(--text-dim); font-size: 10px; padding: 3px 6px; border-radius: 3px; cursor: pointer; font-family: inherit; }
.dev-achieve-item.unlocked { border-color: var(--watched); }
.dev-achieve-item.unlocked .dev-achieve-toggle { background: var(--watched); color: #fff; border-color: var(--watched); }
.dev-form-group { margin-bottom: 12px; }
.dev-form-group label { display: block; font-size: 11px; color: var(--text-dim); margin-bottom: 4px; }
.dev-hint { font-size: 10px; color: var(--text-dim); margin-top: 10px; line-height: 1.4; border-top: 1px dashed var(--line); padding-top: 8px; }

/* Empty & Footer */
.empty { text-align: center; padding: 60px 20px; color: var(--text-dim); }
.empty .grid { text-align: left; }
.empty .display { font-size: 34px; color: var(--text); margin-bottom: 8px; }

footer {
  margin-top: auto;
  border-top: 1px solid var(--line);
  padding: 12px 20px;
  text-align: center;
  font-size: 10px;
  color: var(--text-dim);
  opacity: 0.65;
}
.footer-links {
  margin-top: 4px;
  display: flex;
  gap: 12px;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
}
.footer-links a {
  color: var(--text-dim);
  text-decoration: none;
  cursor: pointer;
  font-size: 10px;
}
.footer-links a:hover { color: var(--accent); }

/* Tier-List & Rankings Styles */
.tier-container {
  max-width: 1440px !important;
  margin: 0 auto;
}
.tier-head-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 24px;
}
.tier-board {
  display: flex;
  flex-direction: column;
  gap: 6px;
  background: #090a0d;
  border: 3px solid #1a1d26;
  border-radius: var(--radius-lg);
  padding: 6px;
  margin-bottom: 30px;
  box-shadow: 0 16px 40px rgba(0,0,0,0.6);
}
.tier-row {
  display: flex;
  min-height: 140px;
  background: #12141c;
  border-bottom: 3px solid #090a0d;
}
.tier-row:last-child {
  border-bottom: none;
}
.tier-badge {
  width: 140px;
  min-width: 140px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Bebas Neue', sans-serif;
  font-size: 64px;
  color: #000;
  font-weight: 800;
  user-select: none;
  text-shadow: 0 2px 4px rgba(255,255,255,0.25);
}
.tier-badge-s { background: #ff7f7f; }
.tier-badge-a { background: #ffbf7f; }
.tier-badge-b { background: #ffff7f; }
.tier-badge-c { background: #7fff7f; }
.tier-badge-d { background: #7fbfff; }
.tier-badge-unwatched { background: #475569; color: #fff; font-size: 28px; }

.tier-dropzone {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 12px;
  min-height: 140px;
  transition: background-color 0.15s ease;
}
.tier-dropzone.drag-over {
  background: rgba(245, 197, 24, 0.15) !important;
  box-shadow: inset 0 0 15px rgba(245, 197, 24, 0.3);
}

.tier-card-thumb {
  width: 84px;
  height: 124px;
  aspect-ratio: 2 / 3;
  border-radius: 6px;
  object-fit: cover;
  border: 1.5px solid rgba(255,255,255,0.2);
  cursor: grab;
  user-select: none;
  background: var(--bg-card);
  transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.15s ease;
}
.tier-card-thumb:active {
  cursor: grabbing;
}
.tier-card-thumb.dragging {
  opacity: 0.4;
}
.tier-card-thumb:hover {
  transform: scale(1.08);
  box-shadow: 0 8px 22px rgba(0, 0, 0, 0.8);
  border-color: var(--accent);
  z-index: 10;
}

.tier-pool {
  background: var(--bg-raised);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}
.tier-pool-head {
  font-weight: 700;
  font-size: 15px;
  color: var(--text-dim);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.tier-pool-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  min-height: 150px;
  padding: 12px;
  background: #0d0f14;
  border-radius: 8px;
  border: 1.5px dashed var(--line);
}
.tier-pool-grid.drag-over {
  border-color: var(--accent);
  background: rgba(245, 197, 24, 0.05);
}

/* Netflix-Style Movie Collections */
.collection-row-section {
  margin-bottom: 28px;
  position: relative;
  z-index: 2;
}
.collection-row-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 24px;
  color: var(--accent);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  letter-spacing: 0.04em;
}
.collection-horizontal-row {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 6px 2px 14px;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.collection-horizontal-row::-webkit-scrollbar {
  height: 6px;
}
.collection-horizontal-row::-webkit-scrollbar-thumb {
  background: var(--line);
  border-radius: 999px;
}
.collection-card {
  flex: 0 0 150px;
  width: 150px;
  scroll-snap-align: start;
}
@media (max-width: 768px) {
  .collection-card {
    flex-basis: 125px;
    width: 125px;
  }
}