*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: #141414;
  color: #e5e5e5;
  min-height: 100vh;
}

/* Header */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
  height: 56px;
  background: #1a1a1a;
  border-bottom: 1px solid #222;
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-logo { font-size: 1.2rem; font-weight: 800; color: #4da6ff; text-decoration: none; letter-spacing: -0.02em; display: flex; align-items: center; gap: 0.4rem; }
.header-logo:hover { color: #58aaff; }
.header-logo-img { height: 1rem; width: auto; }

.header-left { display: flex; align-items: center; gap: 1.5rem; }

.header-browse {
  color: #e5e5e5;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  transition: color 0.15s;
}
.header-browse:hover { color: #4da6ff; }

.header-search {
  flex: 0 1 400px;
  display: flex;
  align-items: center;
  background: #2a2a2a;
  border-radius: 6px;
  padding: 0 0.75rem;
  transition: background 0.15s;
}
.header-search:focus-within { background: #333; outline: 1px solid #444; }
.header-search input {
  flex: 1;
  background: none;
  border: none;
  color: #fff;
  font-size: 0.85rem;
  padding: 0.5rem 0;
  outline: none;
}
.header-search input::placeholder { color: #666; }
.header-search button {
  background: none;
  border: none;
  color: #555;
  cursor: pointer;
  font-size: 0.9rem;
  padding: 0.25rem;
}
.header-search--hidden { display: none; }

.account-area { display: flex; align-items: center; gap: 0.5rem; position: relative; }

.account-circle {
  width: 32px; height: 32px;
  border-radius: 50%;
  background: #4da6ff;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.8rem;
  cursor: pointer;
  user-select: none;
  text-decoration: none;
  position: relative;
}

.account-dropdown {
  display: none;
  position: absolute;
  top: 40px;
  right: 0;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 6px;
  min-width: 150px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
}
.account-dropdown.show { display: block; }
.account-dropdown a, .account-dropdown form button {
  display: block;
  width: 100%;
  padding: 0.6rem 1rem;
  color: #e5e5e5;
  text-decoration: none;
  font-size: 0.85rem;
  background: none;
  border: none;
  text-align: left;
  cursor: pointer;
}
.account-dropdown a:hover, .account-dropdown form button:hover { background: #2a2a2a; }

.sign-in-link {
  color: #e5e5e5;
  text-decoration: none;
  font-size: 0.8rem;
  padding: 0.4rem 0.75rem;
  border: 1px solid #444;
  border-radius: 4px;
  transition: all 0.15s;
}
.sign-in-link:hover { border-color: #4da6ff; color: #4da6ff; }

/* Hero */
.hero {
  text-align: center;
  padding: 4rem 1rem 3rem;
  max-width: 640px;
  margin: 0 auto;
}
.hero h1 { font-size: 2rem; font-weight: 700; margin-bottom: 0.5rem; }
.hero p { color: #666; font-size: 0.9rem; }
.hero-search {
  display: flex;
  margin-top: 1.5rem;
  background: #2a2a2a;
  border-radius: 8px;
  overflow: hidden;
  outline: 1px solid #333;
  transition: outline-color 0.15s;
}
.hero-search:focus-within { outline-color: #4da6ff; }
.hero-search input {
  flex: 1;
  background: none;
  border: none;
  color: #fff;
  font-size: 1rem;
  padding: 0.9rem 1.25rem;
  outline: none;
}
.hero-search input::placeholder { color: #555; }
.hero-search button {
  background: #4da6ff;
  border: none;
  color: #fff;
  font-size: 0.9rem;
  padding: 0.9rem 1.75rem;
  cursor: pointer;
  font-weight: 600;
  transition: background 0.15s;
}
.hero-search button:hover { background: #58aaff; }

/* Sections (home) */
.section { padding: 1.5rem 2rem; }
.section h2 { font-size: 1.1rem; font-weight: 600; margin-bottom: 1rem; }

.home-recs-grid {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
}
.home-recs-grid::-webkit-scrollbar { height: 6px; }
.home-recs-grid::-webkit-scrollbar-thumb { background: #333; border-radius: 3px; }
.home-recs-card {
  display: block;
  border-radius: 8px;
  overflow: hidden;
  background: #1a1a1a;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s, background 0.15s;
  flex: 0 0 150px;
}
.home-recs-card:hover { transform: translateY(-2px); background: #222; }
.home-recs-poster {
  aspect-ratio: 2 / 3;
  background: #2a2a2a;
  overflow: hidden;
  position: relative;
}
.home-recs-poster img { width: 100%; height: 100%; object-fit: cover; display: block; }
.home-recs-poster .no-poster {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #444; font-size: 2rem;
}
.watched-check {
  position: absolute;
  top: 4px;
  right: 4px;
  width: 20px;
  height: 20px;
  background: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #1d1d1d;
  font-size: 0.7rem;
  font-weight: 700;
  z-index: 2;
}
.not-interested-x {
  position: absolute;
  top: 4px;
  left: 4px;
  width: 20px;
  height: 20px;
  background: rgba(0, 0, 0, 0.46);
  border: none;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: rgb(255, 255, 255);
  font-size: 14px;
  line-height: 1;
  padding: 0;
  transition: background 0.15s, color 0.15s;
  z-index: 2;
}
.not-interested-x:hover {
  background: rgba(255, 255, 255, 0.4);
  color: rgba(0, 0, 0, 0.8);
}
.not-interested-x.is-active {
  background: rgba(77, 166, 255, 0.25);
  color: rgba(77, 166, 255, 0.9);
}
.not-interested-x.is-active:hover {
  background: rgba(77, 166, 255, 0.45);
  color: rgba(77, 166, 255, 1);
}
.home-recs-body { padding: 0.6rem 0.75rem 0.75rem; }
.home-recs-title { font-size: 0.82rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-recs-genre { font-size: 0.72rem; color: #666; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.home-recs-meta { display: flex; align-items: center; gap: 0.35rem; margin-top: 0.15rem; }
.home-recs-rating { font-size: 0.7rem; color: #f5c518; font-weight: 600; white-space: nowrap; }
.home-sentinel { flex: 0 0 1px; height: 220px; }

.card-row {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}

.placeholder-card {
  min-width: 160px;
  height: 220px;
  background: #1e1e1e;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #444;
  font-size: 0.8rem;
  border: 1px dashed #333;
}

/* Search results */
.section-results { padding: 1.5rem 2rem; max-width: 800px; margin: 0 auto; }
.section-results h2 { font-size: 1.1rem; font-weight: 600; margin-bottom: 1rem; }

.result-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 1rem;
  border-radius: 6px;
  transition: background 0.15s;
  margin-bottom: 0.25rem;
}
.result-card:hover { background: #1e1e1e; }
.result-card a { color: #e5e5e5; text-decoration: none; font-weight: 500; }
.result-card a:hover { color: #4da6ff; }
.result-card .genre { color: #666; font-size: 0.8rem; margin-top: 0.15rem; }

/* Movie Detail */
.movie-hero {
  height: 380px;
  background-size: cover;
  background-position: center 20%;
  background-repeat: no-repeat;
  position: relative;
}

.movie-hero-gradient {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(20,20,20,0.3) 0%, rgba(20,20,20,0.6) 50%, #141414 100%);
  display: flex;
  align-items: flex-end;
}

.movie-hero-content {
  max-width: 800px;
  margin: 0 auto;
  padding: 2rem;
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  gap: 1rem;
}

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

.imdb-link-movie {
  display: inline-block;
  color: #4da6ff;
  font-size: 0.78rem;
  text-decoration: none;
  opacity: 0.8;
  transition: opacity 0.15s;
}
.imdb-link-movie:visited,
.imdb-link-movie:hover {
  color: #4da6ff;
}
.imdb-link-movie:hover {
  opacity: 1;
  text-decoration: underline;
}

.movie-hero-info h1 {
  font-size: 2rem;
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: 0.4rem;
  text-shadow: 0 2px 8px rgba(0,0,0,0.6);
}

.movie-hero-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.85rem;
  color: #bbb;
}

.movie-hero-actions {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex-shrink: 0;
}

.movie-poster-card {
  flex-shrink: 0;
  width: 100px;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
  border: 1px solid rgba(255, 255, 255, 0.08);
}

.movie-poster-card img {
  display: block;
  width: 100%;
  height: auto;
}

.meta-chip {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  padding: 0.15rem 0.45rem;
  font-size: 0.75rem;
  color: #ddd;
}

.vote-count {
  font-size: 0.7rem;
  color: #999;
  font-weight: 400;
}

.watch-providers {
  margin-bottom: 1.5rem;
}

.watch-providers h3,
.cast-section h3,
.keyword-section h3 {
  font-size: 0.95rem;
  margin-bottom: 0.6rem;
  color: #ccc;
}

.provider-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.provider {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: #1e1e1e;
  border: 1px solid #2a2a2a;
  border-radius: 6px;
  padding: 0.3rem 0.6rem;
  font-size: 0.8rem;
  color: #ddd;
}

.provider img {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  object-fit: cover;
}

.cast-section {
  margin-bottom: 1.5rem;
}

.cast-strip {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
}

.cast-member {
  flex: 0 0 110px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  text-align: center;
}

.cast-member img,
.cast-no-photo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
  background: #222;
}

.cast-no-photo {
  display: flex;
  align-items: center;
  justify-content: center;
  color: #888;
  font-size: 1.6rem;
}

.cast-name {
  font-size: 0.78rem;
  font-weight: 600;
  color: #e5e5e5;
}

.cast-char {
  font-size: 0.7rem;
  color: #888;
  line-height: 1.2;
}

.movie-detail { max-width: 800px; margin: 0 auto; padding: 2rem; }

.movie-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1.25rem;
}
.movie-header h1 { font-size: 1.65rem; font-weight: 700; line-height: 1.3; }
.movie-header .genre {
  font-size: 0.8rem;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  margin-top: 0.25rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.movie-rating {
  color: #f5c518;
  font-weight: 600;
  font-size: 0.85rem;
  letter-spacing: 0;
}

.content-rating {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 600;
  color: #999;
  border: 1px solid #444;
  border-radius: 2px;
  padding: 0px 3px;
  line-height: 1.4;
  vertical-align: middle;
  white-space: nowrap;
}

/* Thumbs - SVG-based */
.watched-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #777;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding: 0;
  color: #ddd;
}
.watched-btn:hover { color: #fff; border-color: #aaa; }
.watched-btn.is-watched { border-color: #666; color: #1d1d1d; background: #bbb; }

.wl-btn {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #777;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding: 0;
  color: #ddd;
}
.wl-btn:hover { color: #fff; border-color: #aaa; }
.wl-btn.in-watchlist { border-color: #f9a825; color: #f9a825; background: rgba(249,168,37,0.1); }

.thumbs {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}
.thumb {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid #777;
  background: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s;
  padding: 0;
  color: #ddd;
}
.thumb:hover { color: #fff; border-color: #aaa; }
.thumb.active { }
.thumb-up.active { border-color: #2e7d32; background: #2e7d32; color: #fff; }
.thumb-up.super { border-color: #1b5e20; background: #1b5e20; color: #fff; box-shadow: 0 0 8px rgba(46,125,50,0.4); }
.thumb-down.active { border-color: #c62828; background: #c62828; color: #fff; }
.thumb-down.super { border-color: #b71c1c; background: #b71c1c; color: #fff; box-shadow: 0 0 8px rgba(198,40,40,0.4); }
.thumb.active svg { fill: currentColor; }
.thumb-svg--stack { display: none; }
.thumb.super .thumb-svg--stack { display: block; }
.thumb.super .thumb-svg { width: 14px; height: 14px; }
.thumb.super .thumb-svg:first-child { margin-right: -4px; }
.thumb.super .thumb-svg--stack { margin-left: -4px; }
.thumb-up.super .thumb-svg { filter: drop-shadow(1.5px 0 0 #1b5e20) drop-shadow(-1.5px 0 0 #1b5e20); }
.thumb-down.super .thumb-svg { filter: drop-shadow(1.5px 0 0 #b71c1c) drop-shadow(-1.5px 0 0 #b71c1c); }

.nibtn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 6px;
  color: rgba(255, 255, 255, 0.35);
  cursor: pointer;
  font-size: 0.8rem;
  padding: 0.35rem 0.7rem;
  transition: background 0.15s, color 0.15s;
  margin-bottom: 10px;
}
.nibtn:hover {
  background: rgba(255, 255, 255, 0.15);
  color: rgba(255, 255, 255, 0.7);
}
.nibtn.is-ni {
  background: rgba(77, 166, 255, 0.15);
  border-color: rgba(77, 166, 255, 0.25);
  color: rgba(77, 166, 255, 0.8);
}
.nibtn.is-ni:hover {
  background: rgba(77, 166, 255, 0.3);
  color: rgba(77, 166, 255, 1);
}

/* Aspect badges */
.aspects { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-bottom: 1.25rem; }
.aspect-badge.pos,
.aspect-badge.neg,
.aspect-badge--very-pos,
.aspect-badge--pos,
.aspect-badge--neutral,
.aspect-badge--neg,
.aspect-badge--very-neg {
  padding: 0.2rem 0.6rem;
  border-radius: 4px;
  font-size: 0.78rem;
  font-weight: 600;
}
.aspect-badge--very-pos { background: rgba(46,125,50,0.15); color: #66bb6a; }
.aspect-badge--pos { background: rgba(46,125,50,0.07); color: #81c784; }
.aspect-badge--neutral { background: rgba(255,255,255,0.04); color: #888; }
.aspect-badge--neg { background: rgba(198,40,40,0.07); color: #e57373; }
.aspect-badge--very-neg { background: rgba(198,40,40,0.15); color: #ef5350; }

/* Summary */
.summary {
  background: linear-gradient(to right, #1a1a1a, #161616);
  border-left: 3px solid #4da6ff;
  padding: 1.25rem 1.5rem;
  border-radius: 0 8px 8px 0;
  margin-bottom: 2rem;
  line-height: 1.7;
  font-size: 0.9rem;
  color: #ccc;
}
.summary h3 {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: #666;
  margin-bottom: 0.5rem;
}

/* Recs section */
.recs { margin-bottom: 2rem; }
.recs-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 1rem;
}
.recs-header h3 { font-size: 1rem; font-weight: 600; }
.recs-header .recs-count { font-size: 0.8rem; color: #666; }

.recs-list {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.rec-card {
  display: flex;
  gap: 0.75rem;
  padding: 0.6rem;
  background: #1a1a1a;
  border-radius: 8px;
  transition: background 0.15s, transform 0.15s;
  text-decoration: none;
  color: inherit;
}
.rec-card:hover { background: #222; transform: translateY(-1px); }

.rec-card-poster {
  width: 50px;
  height: 74px;
  border-radius: 4px;
  background: #2a2a2a;
  flex-shrink: 0;
  overflow: hidden;
  position: relative;
}
.rec-card-poster img { width: 100%; height: 100%; object-fit: cover; display: block; }
.rec-card-poster .no-poster {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #444;
  font-size: 1.2rem;
}

.rec-card-body { display: flex; flex-direction: column; justify-content: center; min-width: 0; }
.rec-card-title { font-size: 0.85rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rec-card-genre { font-size: 0.75rem; color: #666; margin-top: 0.15rem; }

/* Raw reviews */
.raw-reviews {
  margin-top: 0.5rem;
  cursor: pointer;
}
.raw-reviews summary {
  color: #555;
  font-size: 0.8rem;
  padding: 0.5rem 0;
  transition: color 0.15s;
}
.raw-reviews summary:hover { color: #888; }
.raw-reviews .reviews {
  max-height: 260px;
  overflow-y: auto;
  background: #111;
  padding: 1rem;
  border-radius: 6px;
  font-size: 0.8rem;
  line-height: 1.6;
  color: #777;
  margin-top: 0.5rem;
  border: 1px solid #1e1e1e;
}

/* Account pages */
.login-page { max-width: 360px; margin: 4rem auto; padding: 2rem; background: #1a1a1a; border-radius: 10px; border: 1px solid #2a2a2a; }
.login-page h1 { text-align: center; font-size: 1.3rem; margin-bottom: 1.5rem; }
.login-page form label { display: block; margin-bottom: 0.3rem; font-size: 0.8rem; color: #888; }
.login-page form input {
  width: 100%;
  padding: 0.65rem 0.75rem;
  margin-bottom: 1rem;
  background: #2a2a2a;
  border: 1px solid #333;
  border-radius: 6px;
  color: #fff;
  font-size: 0.9rem;
  outline: none;
  transition: border-color 0.15s;
}
.login-page form input:focus { border-color: #4da6ff; }
.login-page form button {
  width: 100%;
  padding: 0.7rem;
  background: #4da6ff;
  border: none;
  border-radius: 6px;
  color: #fff;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}
.login-page form button:hover { background: #58aaff; }
.login-page .error { color: #ef5350; margin-bottom: 1rem; text-align: center; font-size: 0.85rem; }

/* Profile page */
.profile-page {
  max-width: 560px;
  margin: 3rem auto;
  padding: 0 2rem;
  background: rgba(26, 26, 26, 0.686);
  backdrop-filter: blur(5px);
  -webkit-backdrop-filter: blur(5px);
  padding-top: 30px;
  padding-bottom: 30px;
  border-radius: 15px;
}

.profile-header {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  padding: 1.5rem 0;
  border-bottom: 1px solid #222;
  margin-bottom: 1rem;
}
.profile-header-fav {
  margin-left: auto;
  align-self: center;
}

.profile-header--bg {
  background: rgba(26,26,26,0.75);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 8px;
  padding: 1.5rem;
  margin-bottom: 1rem;
  border-bottom: none;
}

.bg-picker-card {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem;
  background: #111;
  border: 1px solid #2a2a2a;
  border-radius: 6px;
  margin-bottom: 1rem;
  min-height: 60px;
}
.bg-picker-poster {
  width: 48px;
  height: 72px;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
  background: #1a1a1a;
  display: flex;
  align-items: center;
  justify-content: center;
}
.bg-picker-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.bg-picker-info {
  flex: 1;
}
.bg-picker-title {
  font-size: 0.9rem;
  color: #e5e5e5;
}
.bg-picker-search {
  position: relative;
  margin-bottom: 1rem;
}

.profile-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: #4da6ff;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.4rem;
  flex-shrink: 0;
}
.profile-avatar--friend {
  background: transparent;
  border: 2px solid #4da6ff;
  color: #4da6ff;
}

.profile-info h1 {
  font-size: 1.5rem;
  font-weight: 700;
  margin-bottom: 0.2rem;
}

.profile-email { color: #888; font-size: 0.85rem; margin-bottom: 0.15rem; }

.profile-joined { color: #555; font-size: 0.8rem; }

.profile-stats {
  display: flex;
  gap: 1rem;
  margin-bottom: 2.5rem;
}

.profile-stat {
  flex: 1;
  background: #1a1a1a;
  border-radius: 8px;
  padding: 1rem;
  text-align: center;
  border: 1px solid #2a2a2a;
}

.profile-stat-number {
  display: block;
  font-size: 1.5rem;
  font-weight: 700;
  color: #e5e5e5;
  margin-bottom: 0.2rem;
}

.profile-stat-label {
  font-size: 0.75rem;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.profile-expandable {
  border-top: 1px solid #2a2a2a;
  padding: 0.75rem 0;
}
.profile-expandable:first-child { border-top: none; padding-top: 0; }
.profile-expandable-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  background: none;
  border: none;
  color: #e5e5e5;
  font-size: 0.9rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  padding: 0.25rem 0;
  text-align: left;
}
.profile-expandable-toggle:hover { color: #4da6ff; }
.profile-expandable-toggle--locked { color: #555; cursor: default; }
.profile-expandable-toggle--locked:hover { color: #555; }
.profile-expandable-count { font-weight: 400; color: #888; }
.profile-expandable-arrow { font-size: 0.65rem; color: #666; transition: transform 0.15s; padding-right: 20px;}
.profile-expandable-toggle:hover .profile-expandable-arrow { color: #4da6ff; }

.privacy-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.72rem;
  color: #666;
  cursor: pointer;
  margin-top: 0.25rem;
  user-select: none;
}
.privacy-toggle input { accent-color: #4da6ff; cursor: pointer; }

.profile-movie-list {
  margin-top: 0.5rem;
}
.profile-movie-scroll {
  display: flex;
  gap: 0.6rem;
  overflow-x: auto;
  padding-bottom: 0.5rem;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
}
.profile-movie-scroll::-webkit-scrollbar { height: 4px; }
.profile-movie-scroll::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }

.profile-movie-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  flex: 0 0 110px;
  min-width: 0;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.15s;
}
.profile-movie-card:hover { opacity: 0.8; }
.profile-movie-poster {
  width: 110px;
  height: 163px;
  background: #2a2a2a;
  border-radius: 4px;
  overflow: hidden;
  flex-shrink: 0;
}
.profile-movie-poster img { width: 100%; height: 100%; object-fit: cover; display: block; }
.profile-movie-poster .no-poster {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #444; font-size: 1.5rem;
}
.profile-movie-title {
  font-size: 0.75rem;
  font-weight: 500;
  line-height: 1.2;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.profile-movie-rating {
  font-size: 0.7rem;
  color: #f5c518;
  font-weight: 600;
}
.profile-movie-placeholder-card {
  background: #2a2a2a;
  border-radius: 4px;
  flex: 0 0 110px;
  height: 163px;
  animation: shimmer 1.5s ease-in-out infinite;
  background: linear-gradient(90deg, #2a2a2a 25%, #333 50%, #2a2a2a 75%);
  background-size: 200% 100%;
}
.profile-movie-sentinel {
  flex: 0 0 1px;
  height: 163px;
}
.profile-expandable[data-category="notinterested"] .profile-expandable-toggle {
  margin-bottom: 0;
}
.profile-load-more {
  display: block;
  width: 100%;
  padding: 0.45rem 1rem;
  background: #2a2a2a;
  border: 1px solid #444;
  border-radius: 4px;
  color: #888;
  font-size: 0.78rem;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.15s;
  text-align: center;
}
.profile-load-more:hover {
  border-color: #4da6ff;
  color: #4da6ff;
}

.profile-section {
  background: #1a1a1a;
  border: 1px solid #2a2a2a;
  border-radius: 8px;
  padding: 1.25rem 1.5rem;
  margin-bottom: 1rem;
}

.profile-section h2 {
  font-size: 0.9rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: #e5e5e5;
}

.profile-section--danger {
  border-color: rgba(198,40,40,0.25);
}

.profile-section--danger h2 { color: #ef5350; }

.profile-action {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.profile-action span {
  font-size: 0.82rem;
  color: #888;
}

.profile-action--link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  text-decoration: none;
  padding: 0.5rem 0;
}
.profile-action--link:hover { opacity: 0.8; }
.profile-action--link + form { margin-top: 0.5rem; }

.profile-confirm {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid #2a2a2a;
}

.profile-confirm p {
  font-size: 0.82rem;
  color: #ef5350;
  margin-bottom: 0.75rem;
}

.profile-confirm form {
  display: flex;
  gap: 0.5rem;
}

.profile-btn {
  padding: 0.45rem 1rem;
  border: none;
  border-radius: 4px;
  font-size: 0.82rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
  white-space: nowrap;
}

.profile-btn--outline {
  background: none;
  border: 1px solid #444;
  color: #e5e5e5;
}
.profile-btn--outline:hover { border-color: #4da6ff; color: #4da6ff; }

.profile-btn--danger {
  background: #c62828;
  color: #fff;
}
.profile-btn--danger:hover { background: #d32f2f; }

/* Podium */
.podium {
  display: flex;
  align-items: flex-start;
  justify-content: center;
  gap: 1rem;
  min-height: 180px;
  margin-bottom: 1rem;
  padding-top: 0.5rem;
}

a.podium-spot,
.podium-spot {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  width: 160px;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.15s;
}
a.podium-spot:hover {
  opacity: 0.85;
}

.podium-spot--1 { order: 1; }
.podium-spot--2 { order: 2; }
.podium-spot--3 { order: 3; }

.podium-spot--1 .podium-poster,
.podium-spot--1 .podium-empty-poster {
  width: 130px;
  height: 184px;
  border: 2px solid #f9a825;
}
.podium-spot--2 .podium-poster,
.podium-spot--2 .podium-empty-poster {
  width: 130px;
  height: 184px;
  border: 2px solid #bdbdbd;
}
.podium-spot--3 .podium-poster,
.podium-spot--3 .podium-empty-poster {
  width: 130px;
  height: 184px;
  border: 2px solid #c47240;
}

.podium-poster {
  border-radius: 4px;
  overflow: hidden;
  background: #2a2a2a;
  flex-shrink: 0;
}
.podium-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.podium-empty-poster {
  border-radius: 4px;
  background: #1e1e1e;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.podium-medal { font-size: 1.3rem; line-height: 1; }

.podium-title {
  font-size: 0.75rem;
  font-weight: 600;
  text-align: center;
  line-height: 1.15;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 160px;
}

.podium-rating {
  font-size: 0.7rem;
  color: #f5c518;
  text-align: center;
  line-height: 1;
}

.podium-empty-label {
  font-size: 0.7rem;
  color: #555;
  text-align: center;
}

.podium-edit-btn {
  font-size: 0.8rem;
  padding: 0.35rem 0.75rem;
}

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.section-header h2 {
  margin: 0;
}

/* Unranked overrides */
.podium--unranked .podium-spot--1 .podium-poster,
.podium--unranked .podium-spot--1 .podium-empty-poster,
.podium--unranked .podium-spot--2 .podium-poster,
.podium--unranked .podium-spot--2 .podium-empty-poster,
.podium--unranked .podium-spot--3 .podium-poster,
.podium--unranked .podium-spot--3 .podium-empty-poster {
  border: none;
}

.podium--unranked .podium-medal {
  display: none;
}

.no-poster-small {
  color: #444;
  font-size: 1rem;
}

/* Favorite editor overlay */
.fav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.75);
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
}

.fav-editor {
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 10px;
  padding: 2rem;
  width: 100%;
  max-width: 720px;
  margin: 0 1rem;
}

.fav-editor h2 {
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 1.5rem;
}

.fav-cards {
  display: flex;
  gap: 1rem;
  justify-content: center;
  margin-bottom: 1rem;
}

.fav-card {
  width: 200px;
  min-height: 220px;
  background: #1e1e1e;
  border: 2px solid #2a2a2a;
  border-radius: 12px;
  cursor: pointer;
  position: relative;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.fav-card:hover {
  border-color: #444;
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0,0,0,0.4);
}

.fav-card--searching {
  border-color: #4da6ff;
  cursor: default;
  transform: none;
  box-shadow: 0 0 0 2px rgba(77,166,255,0.15);
}

.fav-card-display {
  padding: 1rem 0.75rem 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
  transition: opacity 0.2s ease;
  min-height: 100%;
}

.fav-card--searching .fav-card-display {
  opacity: 0;
  pointer-events: none;
}

.fav-card-search {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.fav-card--searching .fav-card-search {
  opacity: 1;
  pointer-events: auto;
}

.fav-card-medal {
  font-size: 1.1rem;
  line-height: 1;
}

.fav-card-poster {
  width: 100px;
  height: 150px;
  background: #2a2a2a;
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.fav-card-poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.fav-card-title {
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  color: #e5e5e5;
  line-height: 1.3;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  width: 100%;
}

.fav-card-input {
  width: 100%;
  padding: 0.5rem 0.6rem;
  background: #2a2a2a;
  border: 1px solid #444;
  border-radius: 6px;
  color: #e5e5e5;
  font-size: 0.82rem;
  outline: none;
  font-family: inherit;
  transition: border-color 0.15s;
}

.fav-card-input:focus {
  border-color: #4da6ff;
}

.fav-card .fav-dropdown {
  position: absolute;
  top: 100%;
  left: -2px;
  right: -2px;
  margin-top: 0.25rem;
  background: #2a2a2a;
  border: 1px solid #444;
  border-radius: 6px;
  z-index: 220;
  max-height: 200px;
  overflow-y: auto;
  box-shadow: 0 6px 16px rgba(0,0,0,0.5);
}

.fav-option {
  padding: 0.5rem 0.75rem;
  cursor: pointer;
  transition: background 0.1s;
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.fav-option:hover { background: #333; }

.fav-option-title {
  font-size: 0.82rem;
  color: #e5e5e5;
  font-weight: 500;
}

.fav-option-genre {
  font-size: 0.7rem;
  color: #666;
}

.fav-dropdown-empty {
  padding: 0.5rem 0.75rem;
  color: #555;
  font-size: 0.8rem;
}

.fav-editor-actions {
  display: flex;
  gap: 0.5rem;
  justify-content: flex-end;
}

.fav-ranked-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0;
  font-size: 0.85rem;
  color: #b3b3b3;
  cursor: pointer;
  user-select: none;
}
.fav-ranked-toggle input[type="checkbox"] {
  width: 16px;
  height: 16px;
  accent-color: #4da6ff;
  cursor: pointer;
}

/* Footer */
.footer { text-align: center; padding: 2rem; color: #666; font-size: 0.75rem; }
.footer a { color: #999; text-decoration: none; }
.footer a:hover { color: #01b4e4; }

/* Autocomplete dropdown */
.ac-wrapper { pointer-events: auto; }

.ac-dropdown {
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 6px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
  max-height: 340px;
  overflow-y: auto;
}

.ac-dropdown::-webkit-scrollbar { width: 4px; }
.ac-dropdown::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }

.ac-item {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.75rem;
  padding: 0.6rem 0.85rem;
  color: #ccc;
  text-decoration: none;
  font-size: 0.83rem;
  transition: background 0.1s;
  border-bottom: 1px solid #1f1f1f;
}
.ac-item:last-child { border-bottom: none; }
.ac-item:hover,
.ac-item.ac-active { background: #2a2a2a; }

.ac-title { font-weight: 500; color: #e5e5e5; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ac-genre { font-size: 0.72rem; color: #555; white-space: nowrap; flex-shrink: 0; }

/* Browse page */
.browse-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 2rem;
  border-bottom: 1px solid #222;
  gap: 1rem;
  flex-wrap: wrap;
}

.browse-toolbar-left {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.browse-toolbar-right {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.browse-count { color: #888; font-size: 0.85rem; }

.browse-clear {
  font-size: 0.75rem;
  color: #777;
  text-decoration: none;
  transition: color 0.15s;
}
.browse-clear:hover { color: #4da6ff; }

.browse-sort, .browse-per-page { display: flex; align-items: center; }

.toolbar-select {
  background: #2a2a2a;
  color: #e5e5e5;
  border: 1px solid #333;
  border-radius: 4px;
  padding: 0.4rem 0.5rem;
  font-size: 0.8rem;
  cursor: pointer;
  outline: none;
}
.toolbar-select:focus { border-color: #4da6ff; }

.browse-divider {
  width: 1px;
  height: 20px;
  background: #333;
  margin: 0 0.25rem;
}

.toolbar-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.4rem 0.75rem;
  background: none;
  border: 1px solid #444;
  border-radius: 4px;
  color: #e5e5e5;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
  font-family: inherit;
}
.toolbar-btn:hover { border-color: #4da6ff; color: #4da6ff; }

.filter-badge {
  background: #4da6ff;
  color: #fff;
  font-size: 0.65rem;
  padding: 0.1rem 0.4rem;
  border-radius: 8px;
  font-weight: 600;
  min-width: 16px;
  text-align: center;
  line-height: 1.2;
}

/* Dropdown panels */
.filter-group { position: relative; }

.filter-panel {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0.35rem;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 6px;
  z-index: 50;
  min-width: 260px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
}
.filter-panel.show { display: block; }

.filter-search {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: #2a2a2a;
  border: none;
  border-bottom: 1px solid #333;
  color: #fff;
  font-size: 0.8rem;
  outline: none;
  border-radius: 6px 6px 0 0;
}
.filter-search::placeholder { color: #555; }

.filter-checkboxes {
  max-height: 220px;
  overflow-y: auto;
  padding: 0.5rem 0.75rem;
}

.filter-checkboxes::-webkit-scrollbar { width: 4px; }
.filter-checkboxes::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }

.filter-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0;
  font-size: 0.82rem;
  color: #ccc;
  cursor: pointer;
  transition: color 0.1s;
  white-space: nowrap;
}
.filter-label:hover { color: #fff; }

.filter-label input[type="checkbox"] {
  accent-color: #4da6ff;
  width: 14px;
  height: 14px;
  cursor: pointer;
  flex-shrink: 0;
}

/* Radio buttons in filter panels */
.filter-label input[type="radio"] {
  appearance: none;
  width: 14px;
  height: 14px;
  border: 2px solid #555;
  border-radius: 50%;
  cursor: pointer;
  flex-shrink: 0;
  transition: border-color 0.15s, background 0.15s;
  position: relative;
}
.filter-label input[type="radio"]:checked {
  border-color: #4da6ff;
  background: #4da6ff;
  box-shadow: inset 0 0 0 3px #1a1a1a;
}
.filter-label:hover input[type="radio"] { border-color: #888; }

.filter-actions {
  padding: 0.5rem 0.75rem;
  border-top: 1px solid #333;
}

.filter-apply-btn {
  width: 100%;
  padding: 0.4rem;
  background: #4da6ff;
  border: none;
  border-radius: 4px;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
  font-family: inherit;
}
.filter-apply-btn:hover { background: #58aaff; }

/* Hierarchical genre groups */
.filter-genre-group {
  border-bottom: 1px solid #2a2a2a;
}
.filter-genre-parent {
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  padding: 0.15rem 0;
  user-select: none;
}
.filter-genre-parent:hover {
  background: #2a2a2a;
}
.genre-caret {
  font-size: 0.65rem;
  color: #666;
  transition: transform 0.15s;
  flex-shrink: 0;
  margin-left: 0.25rem;
}
.genre-caret.open {
  transform: rotate(90deg);
}
.filter-genre-children {
  padding-left: 1.25rem;
  border-left: 1px solid #333;
  margin-left: 6px;
}
.filter-label--child {
  color: #aaa;
  font-size: 0.82rem;
}
.filter-label input[type="checkbox"]:indeterminate {
  accent-color: #666;
}

/* Active filter chips row */
.active-filters-row {
  padding: 0 2rem;
  border-bottom: 1px solid #222;
}

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  padding: 0.6rem 0;
}

.active-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.25rem 0.55rem;
  background: rgba(77,166,255,0.12);
  border: 1px solid rgba(77,166,255,0.25);
  border-radius: 4px;
  font-size: 0.75rem;
  color: #e5e5e5;
  white-space: nowrap;
}

.chip-remove {
  cursor: pointer;
  color: rgba(77,166,255,0.6);
  font-size: 0.9rem;
  line-height: 1;
  transition: color 0.1s;
  margin-left: 0.1rem;
}
.chip-remove:hover { color: #fff; }

.browse-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 1rem;
  padding: 1.5rem 2rem;
}

.browse-card {
  display: block;
  border-radius: 8px;
  background: #1a1a1a;
  text-decoration: none;
  color: inherit;
  transition: transform 0.15s, background 0.15s;
}
.browse-card:hover { transform: translateY(-2px); background: #222; }

.browse-poster {
  aspect-ratio: 2 / 3;
  background: #2a2a2a;
  overflow: hidden;
  position: relative;
  border-radius: 8px 8px 0 0;
}
.browse-poster img { width: 100%; height: 100%; object-fit: cover; display: block; }
.browse-poster .no-poster {
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: #444; font-size: 2rem;
}

.browse-body { padding: 0.6rem 0.75rem 0.75rem; }
.browse-title { font-size: 0.82rem; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.browse-genre { font-size: 0.72rem; color: #666; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.browse-meta { display: flex; align-items: center; gap: 0.35rem; margin-top: 0.15rem; }
.browse-rating { font-size: 0.7rem; color: #f5c518; font-weight: 600; white-space: nowrap; }

.browse-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.3rem;
  padding: 1.5rem 2rem 2rem;
}

.page-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 0.6rem;
  border-radius: 4px;
  background: #1a1a1a;
  color: #e5e5e5;
  text-decoration: none;
  font-size: 0.82rem;
  border: 1px solid #2a2a2a;
  transition: all 0.15s;
}
.page-link:hover { background: #2a2a2a; border-color: #4da6ff; }

.page-current {
  background: #4da6ff;
  border-color: #4da6ff;
  font-weight: 600;
}
.page-current:hover { background: #4da6ff; border-color: #4da6ff; }

.page-dots { border: none; background: none; color: #555; min-width: 24px; }
.page-dots:hover { background: none; border: none; }

.page-prev, .page-next { padding: 0 0.9rem; }

/* Browse filters */
.filter-bar {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  padding: 0.5rem 2rem 1rem;
  flex-wrap: wrap;
}

.filter-group { position: relative; }

.filter-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.4rem 0.75rem;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 4px;
  color: #e5e5e5;
  font-size: 0.8rem;
  cursor: pointer;
  transition: all 0.15s;
}
.filter-toggle:hover { border-color: #4da6ff; }

.filter-badge {
  background: #4da6ff;
  color: #fff;
  font-size: 0.65rem;
  padding: 0.1rem 0.4rem;
  border-radius: 8px;
  font-weight: 600;
  min-width: 18px;
  text-align: center;
}

.filter-arrow { font-size: 0.6rem; color: #666; }

.filter-panel {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  margin-top: 0.35rem;
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 6px;
  z-index: 50;
  min-width: 260px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.6);
}
.filter-panel.show { display: block; }

.filter-search {
  width: 100%;
  padding: 0.5rem 0.75rem;
  background: #2a2a2a;
  border: none;
  border-bottom: 1px solid #333;
  color: #fff;
  font-size: 0.8rem;
  outline: none;
  border-radius: 6px 6px 0 0;
}
.filter-search::placeholder { color: #555; }

.filter-checkboxes {
  max-height: 240px;
  overflow-y: auto;
  padding: 0.5rem 0.75rem;
}

.filter-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.3rem 0;
  font-size: 0.82rem;
  color: #ccc;
  cursor: pointer;
  transition: color 0.1s;
}
.filter-label:hover { color: #fff; }

.filter-label input[type="checkbox"] {
  accent-color: #4da6ff;
  width: 14px;
  height: 14px;
  cursor: pointer;
}

.filter-actions {
  padding: 0.5rem 0.75rem;
  border-top: 1px solid #333;
}

.filter-apply-btn {
  width: 100%;
  padding: 0.4rem;
  background: #4da6ff;
  border: none;
  border-radius: 4px;
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s;
}
.filter-apply-btn:hover { background: #58aaff; }

.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  align-items: center;
}

.active-filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.5rem;
  background: #2a2a2a;
  border: 1px solid #444;
  border-radius: 4px;
  font-size: 0.75rem;
  color: #ccc;
}

.chip-remove {
  cursor: pointer;
  color: #888;
  font-size: 0.9rem;
  line-height: 1;
  transition: color 0.1s;
}
.chip-remove:hover { color: #4da6ff; }

.browse-clear {
  margin-left: 0.75rem;
  font-size: 0.75rem;
  color: #888;
  text-decoration: none;
  transition: color 0.15s;
}
.browse-clear:hover { color: #4da6ff; }

.browse-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 3rem 0;
  color: #666;
}
.browse-empty p { margin-bottom: 0.75rem; }
.browse-empty a { color: #4da6ff; text-decoration: none; font-size: 0.85rem; }
.browse-empty a:hover { text-decoration: underline; }

.multi-select-bar {
  padding: 0.5rem 2rem;
  background: #1c1c1c;
  border-bottom: 1px solid #222;
}
.multi-select-bar-inner {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}
.multi-select-count {
  font-size: 0.8rem;
  color: #888;
  margin-right: 0.5rem;
  min-width: 80px;
}
.multi-select-status {
  font-size: 0.8rem;
  color: #4da6ff;
  margin-left: 0.5rem;
}
.browse-card--selected {  
  border: 3px solid #4da6ff;
}
.toolbar-btn--active {
  border-color: #4da6ff;
  color: #4da6ff;
  background: rgba(77,166,255,0.1);
}

/* Taste summary */
.profile-taste {
  border-left: 3px solid #4da6ff;
  padding-left: 1.25rem;
}
.taste-summary {
  font-size: 0.95rem;
  line-height: 1.6;
  color: #ccc;
  margin: 0;
}

/* Badge section */
.badge-section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}
.badge-section-header h2 {
  margin: 0;
}
.badge-row {
  display: flex;
  gap: 1rem;
  overflow-x: auto;
  padding-bottom: 0.25rem;
  scrollbar-width: thin;
  scrollbar-color: #333 transparent;
}
.badge-row::-webkit-scrollbar { height: 3px; }
.badge-row::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }
.badge-card {
  background: #1e1e1e;
  border-radius: 8px;
  padding: 1rem 1.25rem;
  flex: 1;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  border: 1px solid #333;
}
.badge-card--empty {
  cursor: pointer;
  border: 1px dashed #555;
  color: #666;
}
.badge-card--empty:hover {
  border-color: #4da6ff;
  color: #4da6ff;
}
.badge-row--compact { gap: 0.5rem; padding: 0 0 0.5rem; flex-wrap: nowrap; }
.badge-card--compact {
  min-width: 0;
  border-radius: 6px;
}
.badge-card--compact .badge-icon { font-size: 0.8rem; line-height: 1; }
.badge-card--compact .badge-value { font-size: 1rem; line-height: 1; }
.badge-card--compact .badge-label { font-size: 0.55rem; line-height: 1; }
.badge-card--small {
  flex-direction: row;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  min-width: auto;
}
.badge-icon {
  font-size: 1.25rem;
}
.badge-value {
  font-size: 1.5rem;
  font-weight: 500;
  color: #e5e5e5;
}
.badge-card--small .badge-value {
  font-size: 1rem;
}
.badge-label {
  font-size: 0.8rem;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}
.badge-select {
  width: 100%;
  padding: 0.5rem;
  background: #333;
  border: 1px solid #444;
  border-radius: 4px;
  color: #fff;
  font-size: 0.85rem;
}

/* Badge picker */
.badge-counter {
  font-size: 0.8rem;
  color: #666;
  font-weight: 400;
  margin-left: 0.5rem;
}

.badge-preview-row {
  display: flex;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.badge-preview-slot {
  flex: 1;
  min-height: 72px;
  border-radius: 8px;
  border: 1px dashed #444;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0.5rem;
}

.badge-preview-slot--filled {
  border: 1px solid #333;
  background: #1e1e1e;
  flex-direction: column;
  gap: 0.15rem;
  padding: 0.5rem 0.25rem;
}

.badge-preview-slot--filled .badge-icon { font-size: 1rem; }
.badge-preview-slot--filled .badge-value { font-size: 1.1rem; font-weight: 700; color: #e5e5e5; }
.badge-preview-slot--filled .badge-label { font-size: 0.65rem; color: #888; text-transform: uppercase; letter-spacing: 0.5px; }

.badge-preview-empty {
  font-size: 1.2rem;
  color: #444;
}

.badge-picker-grid {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  max-height: 320px;
  overflow-y: auto;
  margin-bottom: 1.25rem;
  padding-right: 0.25rem;
}
.badge-picker-grid::-webkit-scrollbar { width: 4px; }
.badge-picker-grid::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }
.badge-category { margin-bottom: 0.25rem; }
.badge-category-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.35rem 0.25rem;
  cursor: pointer;
  user-select: none;
  font-size: 0.75rem;
  font-weight: 600;
  color: #888;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border-bottom: 1px solid #2a2a2a;
}
.badge-category-header:hover { color: #4da6ff; }
.badge-category-count { font-size: 0.65rem; color: #555; font-weight: 400; }
.badge-category-header .genre-caret { font-size: 0.55rem; color: #555; margin-left: auto; }
.badge-category-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  padding: 0.5rem 0.25rem;
}

.badge-picker-card {
  background: #1e1e1e;
  border: 1px solid #333;
  border-radius: 8px;
  padding: 0.65rem 0.85rem;
  min-width: 90px;
  flex: 1 0 auto;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.15rem;
  cursor: pointer;
  transition: border-color 0.15s, opacity 0.15s;
  user-select: none;
}

.badge-picker-card:hover {
  border-color: #555;
}

.badge-picker-card--selected {
  border-color: #4da6ff;
  background: rgba(77, 166, 255, 0.08);
}

.badge-picker-card--selected:hover {
  border-color: #4da6ff;
}

.badge-picker-card--disabled {
  opacity: 0.35;
  cursor: default;
  pointer-events: none;
}

.badge-picker-card .badge-icon { font-size: 1.1rem; }
.badge-picker-card .badge-value { font-size: 1.2rem; font-weight: 700; color: #e5e5e5; }
.badge-picker-card .badge-label { font-size: 0.7rem; color: #888; text-transform: uppercase; letter-spacing: 0.5px; }

/* Badge tier styles */
.badge-card--bronze {
  border-color: rgba(205, 127, 50, 0.5);
  background: linear-gradient(180deg, rgba(205, 127, 50, 0.08) 0%, transparent 100%);
  box-shadow: inset 0 1px 0 rgba(205, 127, 50, 0.15);
}
.badge-card--bronze .badge-value { color: #cd7f32; }

.badge-card--silver {
  border-color: rgba(192, 192, 192, 0.5);
  background: linear-gradient(180deg, rgba(192, 192, 192, 0.08) 0%, transparent 100%);
  box-shadow: inset 0 1px 0 rgba(192, 192, 192, 0.15), 0 0 12px rgba(192, 192, 192, 0.08);
}
.badge-card--silver .badge-value { color: #c0c0c0; }

.badge-card--gold {
  border-color: rgba(249, 168, 37, 0.5);
  background: linear-gradient(180deg, rgba(249, 168, 37, 0.1) 0%, transparent 100%);
  box-shadow: inset 0 1px 0 rgba(249, 168, 37, 0.2), 0 0 18px rgba(249, 168, 37, 0.1);
}
.badge-card--gold .badge-value { color: #f9a825; }

.badge-card--diamond {
  border-color: rgba(179, 136, 255, 0.5);
  background: linear-gradient(180deg, rgba(179, 136, 255, 0.08) 0%, rgba(0, 229, 255, 0.04) 100%);
  box-shadow: inset 0 1px 0 rgba(179, 136, 255, 0.2), 0 0 24px rgba(179, 136, 255, 0.15), 0 0 48px rgba(0, 229, 255, 0.06);
}
.badge-card--diamond .badge-value {
  background: linear-gradient(135deg, #b388ff 0%, #00e5ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

/* Animated border for diamond badges */
@keyframes diamond-shift {
  0%, 100% { border-color: rgba(179, 136, 255, 0.5); box-shadow: inset 0 1px 0 rgba(179, 136, 255, 0.2), 0 0 24px rgba(179, 136, 255, 0.15), 0 0 48px rgba(0, 229, 255, 0.06); }
  50% { border-color: rgba(0, 229, 255, 0.5); box-shadow: inset 0 1px 0 rgba(0, 229, 255, 0.2), 0 0 24px rgba(0, 229, 255, 0.15), 0 0 48px rgba(179, 136, 255, 0.06); }
}

.badge-card--diamond {
  animation: diamond-shift 3s ease-in-out infinite;
}

.badge-picker-card--bronze {
  border-color: rgba(205, 127, 50, 0.5);
}
.badge-picker-card--bronze:hover {
  border-color: rgba(205, 127, 50, 0.8);
}
.badge-picker-card--bronze .badge-value { color: #cd7f32; }

.badge-picker-card--silver {
  border-color: rgba(192, 192, 192, 0.5);
}
.badge-picker-card--silver:hover {
  border-color: rgba(192, 192, 192, 0.8);
}
.badge-picker-card--silver .badge-value { color: #c0c0c0; }

.badge-picker-card--gold {
  border-color: rgba(249, 168, 37, 0.5);
}
.badge-picker-card--gold:hover {
  border-color: rgba(249, 168, 37, 0.8);
}
.badge-picker-card--gold .badge-value { color: #f9a825; }

.badge-picker-card--diamond {
  border-color: rgba(179, 136, 255, 0.5);
}
.badge-picker-card--diamond:hover {
  border-color: rgba(179, 136, 255, 0.8);
}
.badge-picker-card--diamond .badge-value {
  background: linear-gradient(135deg, #b388ff 0%, #00e5ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

@media (prefers-reduced-motion: reduce) {
  .badge-card--diamond {
    animation: none;
  }
}

/* Badge tooltips */
.badge-tooltip {
  position: fixed;
  background: #1a1a1a;
  border: 1px solid #444;
  color: #bbb;
  font-size: 0.68rem;
  padding: 0.35rem 0.55rem;
  border-radius: 6px;
  white-space: nowrap;
  pointer-events: none;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.1s, visibility 0.1s;
  z-index: 9999;
  box-shadow: 0 2px 8px rgba(0,0,0,0.4);
  transform: translateX(-50%);
}
.badge-tooltip::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: #444;
}
.badge-tooltip--shown {
  visibility: visible;
  opacity: 1;
}
.badge-tooltip--below::after {
  top: auto;
  bottom: 100%;
  border-top-color: transparent;
  border-bottom-color: #444;
}

/* Mobile */
@media (max-width: 600px) {
  .header {
    padding: 0 1rem;
    height: auto;
    min-height: 52px;
    flex-wrap: wrap;
  }

  .header-logo { font-size: 1.15rem; }
  .header-browse { font-size: 0.85rem; }
  .header-left { gap: 1rem; }

  .account-area { gap: 0.75rem; }

  .header-search {
    flex: 1 0 100%;
    order: 3;
    margin: 0 -1rem;
    border-radius: 0;
    padding: 0 1rem;
    border-top: 1px solid #222;
  }

  .header-search input {
    padding: 0.55rem 0;
    font-size: 0.9rem;
  }

  .sign-in-link {
    font-size: 0.78rem;
    padding: 0.35rem 0.65rem;
  }

  .account-circle {
    width: 30px; height: 30px;
    font-size: 0.75rem;
  }

  .hero {
    padding: 3.5rem 1.5rem 3rem;
  }

  .hero h1 {
    font-size: 1.75rem;
    margin-bottom: 0.5rem;
  }

  .hero p {
    font-size: 0.85rem;
  }

  .hero-search {
    margin-top: 1.25rem;
  }

  .hero-search input {
    font-size: 0.9rem;
    padding: 0.8rem 1rem;
  }

  .hero-search button {
    font-size: 0.85rem;
    padding: 0.8rem 1.15rem;
    white-space: nowrap;
  }

  .section {
    padding: 1.25rem 0.75rem;
  }

  .section h2 {
    font-size: 1rem;
  }

  .home-recs-card {
    flex: 0 0 130px;
  }

  .home-recs-title { font-size: 0.78rem; }
  .home-recs-genre { font-size: 0.68rem; }
  .home-recs-rating { font-size: 0.65rem; }

  .footer {
    padding: 1.5rem 0.75rem;
    font-size: 0.7rem;
  }

  .login-page {
    margin: 2rem 0.75rem;
    max-width: none;
    border-radius: 0;
    padding: 1.5rem;
  }

  .login-page h1 {
    font-size: 1.2rem;
  }

  .login-page form input {
    padding: 0.6rem 0.75rem;
    font-size: 0.85rem;
  }

  .profile-page {
    margin: 2rem auto;    
    padding: 0.75rem;
    width: 90dvw;
  }

  .profile-header {
    gap: 1rem;
    margin-bottom: 1.5rem;
  }

  .profile-avatar {
    width: 52px; height: 52px;
    font-size: 1.2rem;
  }

  .profile-info h1 {
    font-size: 1.25rem;
  }

  .profile-stats {
    flex-direction: column;
    gap: 0.5rem;
    margin-bottom: 1.5rem;
  }

  .profile-stat {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
  }

  .profile-stat-number {
    font-size: 1.2rem;
    margin-bottom: 0;
  }

  .profile-stat-label {
    font-size: 0.72rem;
  }

  .profile-section {
    padding: 1rem;
  }

  .badge-row {
    flex-wrap: wrap;
  }

  .badge-card {
    flex: 1 1 100px;
  }

  .browse-toolbar {
    padding: 0.75rem;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .browse-toolbar-left {
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .browse-grid {
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 0.75rem;
    padding: 1rem 0.75rem;
  }

  .browse-pagination {
    padding: 1rem 0.75rem 1.5rem;
    gap: 0.2rem;
  }

  .page-link {
    min-width: 32px;
    height: 32px;
    font-size: 0.78rem;
  }

  .movie-hero {
    height: 250px;
  }

  .movie-hero-gradient {
    background: linear-gradient(to bottom, rgba(20,20,20,0.45) 0%, rgba(20,20,20,0.85) 55%, #141414 100%);
  }

  .movie-hero-content {
    padding: 1rem 0.75rem;
    flex-wrap: wrap;
    gap: 0.75rem;
  }

  .movie-hero-info h1 {
    font-size: 1.4rem;
  }

  .movie-hero-meta {
    font-size: 0.78rem;
    gap: 0.5rem;
  }

  .movie-detail {
    padding: 1.25rem 0.75rem;
  }

  .movie-hero-actions {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    flex-shrink: 0;
  }

  .movie-poster-card {
    width: 64px;
  }

  .movie-header h1 {
    font-size: 1.3rem;
  }

  .rec-card {
    padding: 0.5rem;
  }

  .rec-card-poster {
    width: 42px;
    height: 62px;
  }

  .rec-card-title { font-size: 0.8rem; }
  .rec-card-genre { font-size: 0.7rem; }

  .filter-bar {
    padding: 0.5rem 0.75rem 0.75rem;
  }

  .active-filters-row {
    padding: 0 0.75rem;
  }

  .fav-editor {
    margin: 0 0.75rem;
    padding: 1.25rem;
    max-width: 100%;
  }

  .fav-editor h2 {
    font-size: 1rem;
    margin-bottom: 1rem;
  }

  .fav-cards {
    gap: 0.5rem;
  }

  .fav-card {
    width: 30%;
    min-height: 160px;
  }

  .fav-card-poster {
    width: 70px;
    height: 105px;
  }

  .fav-card-title {
    font-size: 0.7rem;
  }

  .fav-card-input {
    font-size: 0.75rem;
  }

  .podium {
    min-height: 140px;
  }

  .podium-spot--1 .podium-poster,
  .podium-spot--1 .podium-empty-poster,
  .podium-spot--2 .podium-poster,
  .podium-spot--2 .podium-empty-poster,
  .podium-spot--3 .podium-poster,
  .podium-spot--3 .podium-empty-poster {
    width: 100px;
    height: 142px;
  }

  .podium-title {
    font-size: 0.7rem;
  }
}

@media (max-width: 380px) {
  .hero-search {
    flex-direction: column;
    border-radius: 8px;
  }

  .hero-search input {
    border-radius: 8px 8px 0 0;
    padding: 0.75rem 1rem;
  }

  .hero-search button {
    border-radius: 0 0 8px 8px;
    padding: 0.7rem;
    width: 100%;
  }

  .hero {
    padding: 2rem 1.25rem 2.5rem;
  }

  .hero h1 {
    font-size: 1.5rem;
  }
}

/* ===== Friends Section ===== */

.friends-toggle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
  padding: 0.85rem 0;
  background: none;
  border: none;
  border-top: 1px solid #222;
  color: #e5e5e5;
  font-size: 1.1rem;
  font-weight: 600;
  cursor: pointer;
  text-align: left;
}
.friends-toggle:hover { color: #4da6ff; }
.friends-toggle-count { color: #666; font-weight: 400; font-size: 0.85rem; }
.friends-toggle-badge {
  background: #4da6ff;
  color: #fff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.1rem 0.4rem;
  border-radius: 10px;
  min-width: 18px;
  text-align: center;
  line-height: 1.3;
}
.friends-toggle-arrow { margin-left: auto; font-size: 0.7rem; color: #666; }

.friends-panel {
  padding-bottom: 0.5rem;
}

.friends-tabs {
  display: flex;
  gap: 0;
  border-bottom: 1px solid #222;
  margin-bottom: 1rem;
}
.friends-tab {
  padding: 0.5rem 1rem;
  background: none;
  border: none;
  border-bottom: 2px solid transparent;
  color: #888;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 500;
  position: relative;
}
.friends-tab:hover { color: #e5e5e5; }
.friends-tab--active { color: #4da6ff; border-bottom-color: #4da6ff; }
.friends-tab-badge {
  background: #4da6ff;
  color: #fff;
  font-size: 0.65rem;
  padding: 0.05rem 0.3rem;
  border-radius: 8px;
  margin-left: 0.25rem;
  vertical-align: top;
}

.friends-tab-content { }
.friends-subhead {
  font-size: 0.8rem;
  color: #666;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 1rem 0 0.5rem;
}

.friends-grid {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-height: 22rem;
  overflow-y: auto;
  padding-right: 0.25rem;
}
.friends-grid::-webkit-scrollbar { width: 4px; }
.friends-grid::-webkit-scrollbar-thumb { background: #333; border-radius: 2px; }

.friend-card {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 0.85rem;
  background: #1e1e1e;
  border-radius: 8px;
  border: 1px solid #2a2a2a;
}
.friend-card-link {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  flex: 1;
  min-width: 0;
  text-decoration: none;
  color: inherit;
}
.friend-card-link:hover .friend-card-name { color: #4da6ff; }
.friend-card-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: transparent;
  border: 2px solid #4da6ff;
  color: #4da6ff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.85rem;
  flex-shrink: 0;
}
.friend-card-avatar--small {
  width: 30px;
  height: 30px;
  font-size: 0.75rem;
}
.friend-card-info {
  flex: 1;
  min-width: 0;
}
.friend-card-name {
  font-size: 0.85rem;
  color: #e5e5e5;
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.friend-card-time {
  font-size: 0.7rem;
  color: #555;
}
.friend-card-actions {
  display: flex;
  gap: 0.35rem;
  flex-shrink: 0;
}

.friend-btn {
  padding: 0.3rem 0.65rem;
  border: none;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
}
.friend-btn--view {
  background: #2a2a2a;
  color: #e5e5e5;
}
.friend-btn--view:hover { background: #3a3a3a; color: #fff; }
.friend-btn--add {
  background: #2e7d32;
  color: #fff;
}
.friend-btn--add:hover { background: #388e3c; }
.friend-btn--remove {
  background: none;
  color: #888;
}
.friend-btn--remove:hover { color: #ef5350; }
.friend-btn--accept {
  background: #2e7d32;
  color: #fff;
}
.friend-btn--accept:hover { background: #388e3c; }
.friend-btn--reject {
  background: none;
  color: #888;
}
.friend-btn--reject:hover { color: #ef5350; }
.friend-btn--cancel {
  background: none;
  color: #888;
}
.friend-btn--cancel:hover { color: #ef5350; }

.friend-status {
  font-size: 0.75rem;
  color: #888;
  white-space: nowrap;
}
.friend-status--pending { color: #e6a817; }
.friend-status--received { color: #42a5f5; }

.friends-search {
  margin-bottom: 0.75rem;
}
.friends-search-input {
  width: 100%;
  padding: 0.55rem 0.75rem;
  background: #2a2a2a;
  border: 1px solid #333;
  border-radius: 6px;
  color: #e5e5e5;
  font-size: 0.85rem;
  outline: none;
}
.friends-search-input:focus { border-color: #4da6ff; }
.friends-search-input::placeholder { color: #555; }

.friends-search-results { min-height: 40px; }
.friends-search-results .friend-card { margin-bottom: 0.35rem; }
.friends-search-status {
  padding: 0.5rem;
  color: #888;
  font-size: 0.8rem;
  text-align: center;
}
.friends-empty {
  color: #555;
  font-size: 0.85rem;
  padding: 1rem 0;
}

.friends-requests .friend-card { margin-bottom: 0.35rem; }

/* Account badge (base.html) */
.account-badge {
  position: absolute;
  top: -6px;
  right: -6px;
  background: #f5c518;
  color: #141414;
  font-size: 0.6rem;
  font-weight: 700;
  padding: 0.1rem 0.35rem;
  border-radius: 10px;
  min-width: 16px;
  text-align: center;
  line-height: 1.4;
}

.friend-fav-btn {
  background: none;
  border: none;
  color: #555;
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.15rem 0.3rem;
  line-height: 1;
}
.friend-fav-btn:hover { color: #f5c518; }
.friend-fav-btn--active { color: #f5c518; }
.friend-fav-btn--large { font-size: 1.5rem; }

/* Profile page remove friend button area */
.profile-actions {
  padding: 1rem 0;
  border-top: 1px solid #222;
  margin-top: 0.5rem;
}

.friend-label {
  font-size: 0.7em;
  color: #666;
  font-weight: 400;
}

/* Messages */
.messages-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 1rem;
}
.message {
  padding: 0.65rem 1rem;
  margin-bottom: 0.5rem;
  border-radius: 4px;
  font-size: 0.85rem;
}
.message--success {
  background: #1b3a1b;
  border: 1px solid #2d5a2d;
  color: #6fcf6f;
}
.message--error {
  background: #3a1b1b;
  border: 1px solid #5a2d2d;
  color: #cf6f6f;
}

/* Review form */
.review-section {
  margin: 1.5rem 0;
}
.review-section details {
  background: #1a1a1a;
  border: 1px solid #333;
  border-radius: 8px;
}
.review-section summary {
  padding: 0.75rem 1rem;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.9rem;
  color: #aaa;
}
.review-section summary:hover {
  color: #e5e5e5;
}
.review-form {
  padding: 0 1rem 1rem;
}
.review-rows {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-bottom: 1rem;
}
.review-row {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
}
.review-label {
  min-width: 140px;
  text-align: center;
  font-size: 0.85rem;
  color: #ccc;
  text-transform: capitalize;
}
.review-btn {
  width: 28px;
  height: 28px;
  border: 1px solid #444;
  border-radius: 4px;
  background: #222;
  color: #888;
  font-size: 1rem;
  font-weight: bold;
  cursor: pointer;
  line-height: 1;
  padding: 0;
  flex-shrink: 0;
}
.review-btn:hover {
  border-color: #888;
  color: #ccc;
}
.review-btn.review-pos.active {
  background: #1a3a1a;
  border-color: #4a8a4a;
  color: #6fcf6f;
}
.review-btn.review-neg.active {
  background: #3a1a1a;
  border-color: #8a4a4a;
  color: #cf6f6f;
}
.review-submit {
  padding: 0.5rem 1.25rem;
  background: #4da6ff;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
}
.review-submit:hover {
  background: #ff1a24;
}
.review-status {
  margin-left: 0.75rem;
  font-size: 0.8rem;
}
.review-status--ok {
  color: #6fcf6f;
}
.review-status--err {
  color: #cf6f6f;
}

/* Preferences Widgets */
.pref-row {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 0.75rem 0;
}
.pref-row--stack {
  flex-direction: column;
  align-items: stretch;
  gap: 0.35rem;
  padding: 0.6rem 0;
}

.pref-label {
  font-size: 0.82rem;
  color: #b3b3b3;
  flex: 0 0 auto;
}

.pref-slider-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  width: 100%;
}

.pref-slider-val {
  font-size: 0.7rem;
  color: #555;
  font-weight: 400;
  text-align: center;
  min-width: 1.8em;
  transition: color 0.2s;
  cursor: default;
}
.pref-slider-val.active {
  color: #4da6ff;
  font-weight: 600;
}

.pref-rating-labels-row {
  justify-content: space-between;
  margin-bottom: -0.1rem;
}

.pref-rating-track {
  position: relative;
  height: 20px;
  width: 100%;
  touch-action: none;
}

.pref-rating-fill {
  position: absolute;
  top: 8px;
  height: 4px;
  background: #4da6ff;
  border-radius: 2px;
  z-index: 1;
  pointer-events: none;
}

.pref-rating-track::before {
  content: '';
  position: absolute;
  top: 8px;
  left: 0;
  right: 0;
  height: 4px;
  background: #333;
  border-radius: 2px;
}

.pref-rating-handle {
  position: absolute;
  top: 3px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #4da6ff;
  border: 2px solid #fff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
  z-index: 3;
  margin-left: -7px;
  cursor: pointer;
}

.pref-rating-range {
  -webkit-appearance: none;
  appearance: none;
  position: absolute;
  top: 8px;
  width: 100%;
  height: 4px;
  background: transparent;
  z-index: 2;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}

.pref-rating-range--single {
  pointer-events: auto;
  opacity: 1;
}
.pref-rating-range--single::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #4da6ff;
  border: 2px solid #fff;
  cursor: pointer;
  box-shadow: 0 1px 3px rgba(0,0,0,0.4);
}
.pref-rating-range--single::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: #4da6ff;
  border: 2px solid #fff;
  cursor: pointer;
}

.pref-checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.78rem;
  color: #999;
  cursor: pointer;
}
.pref-checkbox-label input[type="checkbox"] {
  accent-color: #4da6ff;
}

/* User lists page */
.lists-header {
  padding: 1.5rem 2rem 0;
  margin-bottom: 1rem;
}
.lists-header h1 {
  font-size: 1.25rem;
  font-weight: 600;
  color: #e5e5e5;
  margin: 0.5rem 0 0 0;
}
.lists-back {
  color: #888;
  font-size: 0.85rem;
  text-decoration: none;
}
.lists-back:hover { color: #4da6ff; }

.lists-tabs {
  display: flex;
  gap: 0;
  margin: 0 2rem 1rem;
  border-bottom: 1px solid #2a2a2a;
}
.lists-tab {
  padding: 0.6rem 1.25rem;
  font-size: 0.85rem;
  color: #888;
  text-decoration: none;
  border-bottom: 2px solid transparent;
  transition: color 0.15s, border-color 0.15s;
  user-select: none;
}
.lists-tab:hover { color: #ccc; }
.lists-tab--active { color: #e5e5e5; border-bottom-color: #4da6ff; }
.lists-tab--locked { color: #444; cursor: default; pointer-events: none; }
.lists-tab--locked:hover { color: #444; }

.lists-private {
  text-align: center;
  color: #666;
  padding: 3rem 1rem;
  font-size: 0.9rem;
}
.lists-empty {
  text-align: center;
  color: #666;
  padding: 3rem 1rem;
  font-size: 0.9rem;
}

/* See all link on profiles */
.see-all-link {
  color: #888;
  font-size: 0.78rem;
  text-decoration: none;
  white-space: nowrap;
  transition: color 0.15s;
}
.see-all-link:hover { color: #4da6ff; }

@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

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

.browse-card, .home-recs-card, .rec-card, .profile-movie-card {
  animation: fadeIn 0.25s ease-out;
}

/* ============ HOME THEATER SKIN (futuristic lounge) ============ */
:root {
  --accent-blue: #4da6ff;
  --accent-blue-bright: #58aaff;
  --accent-tan: #d6c7a1;
  --bg: #17181a;
  --bias-color: rgba(77, 166, 255, 0.10);
}

/* dark room: graphite bg + ambient LED glow from above */
body {
  background:
    radial-gradient(ellipse 90% 45% at 50% -12%, rgba(77,166,255,0.06), transparent 70%),
    var(--bg);
}

/* header: glowing hairline, dark glass */
.header {
  background: rgba(23, 24, 26, 0.92);
  backdrop-filter: blur(6px);
  border-bottom: 1px solid rgba(77, 166, 255, 0.14);
}
.header-search {
  background: #121314;
  border: 1px solid rgba(77, 166, 255, 0.22);
}
.header-search:focus-within {
  background: #121314;
  outline: 1px solid rgba(77, 166, 255, 0.6);
}

/* home hero: framed screen with letterbox bars + bias bloom */
.hero {
  max-width: 720px;
  margin: 2rem auto 1rem;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  border: 1px solid rgba(214, 199, 161, 0.16);
  background:
    radial-gradient(ellipse 70% 60% at 50% 120%, rgba(77, 166, 255, 0.10), transparent 60%),
    linear-gradient(180deg, #1c1e22 0%, #131417 100%);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 90px var(--bias-color);
}
.hero::before,
.hero::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 4px;
  background: #0a0b0c;
  border-left: 1px solid rgba(214, 199, 161, 0.2);
  border-right: 1px solid rgba(214, 199, 161, 0.2);
  pointer-events: none;
}
.hero::before { top: 0; }
.hero::after { bottom: 0; }
.hero h1 { color: #f2f5f8; }
.hero p { color: #8b93a1; }
.hero-search {
  border-radius: 999px;
  background: #0e0f11;
  border: 1px solid rgba(77, 166, 255, 0.3);
  overflow: hidden;
  outline: none;
}
.hero-search:focus-within {
  outline: none;
  border-color: var(--accent-blue);
  box-shadow: 0 0 18px rgba(77, 166, 255, 0.25);
}
.hero-search button {
  background: var(--accent-blue);
  color: #06121f;
  border-radius: 0 999px 999px 0;
  font-weight: 700;
}
.hero-search button:hover {
  background: var(--accent-blue-bright);
  box-shadow: 0 0 26px rgba(77, 166, 255, 0.45);
}

/* movie detail hero: framed screen */
.movie-hero {
  margin: 1.25rem auto 0;
  max-width: 900px;
  border-radius: 14px;
  overflow: hidden;
  border: 1px solid rgba(214, 199, 161, 0.16);
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 90px var(--bias-color);
}

/* sections: names unchanged, quiet hairline */
.section h2 {
  color: #edf0f4;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 0.55rem;
}

/* shelf-tile cards */
.browse-card,
.home-recs-card,
.rec-card,
.profile-movie-card,
.result-card {
  background: #1b1d20;
  border: 1px solid rgba(214, 199, 161, 0.13);
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.16s ease, box-shadow 0.16s ease, border-color 0.16s ease, background 0.16s ease;
}
.browse-card:hover,
.home-recs-card:hover,
.rec-card:hover,
.profile-movie-card:hover,
.result-card:hover {
  transform: translateY(-3px);
  border-color: rgba(77, 166, 255, 0.5);
  background: #1f2125;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55), 0 0 32px rgba(77, 166, 255, 0.13);
}

/* placeholder cards: tan dashed */
.placeholder-card {
  background: #1b1d20;
  border: 1px dashed rgba(214, 199, 161, 0.25);
  color: #8b93a1;
}

/* content rating chips: tan leather */
.content-rating {
  color: var(--accent-tan);
  border: 1px solid rgba(214, 199, 161, 0.3);
  background: rgba(214, 199, 161, 0.14);
}

/* not-interested X: quiet, blue active */
.not-interested-x {
  background: rgba(0, 0, 0, 0.35);
  color: rgba(255, 255, 255, 0.5);
}
.not-interested-x:hover {
  background: rgba(77, 166, 255, 0.22);
  color: #ffffff;
}
.not-interested-x.is-active {
  background: rgba(77, 166, 255, 0.22);
  color: var(--accent-blue);
}
.not-interested-x.is-active:hover {
  background: rgba(77, 166, 255, 0.35);
  color: var(--accent-blue-bright);
}

/* thumbs: abstract line icons, blue active glow */
.thumb {
  border-width: 1.5px;
  transition: all 0.15s;
}
.thumb svg { stroke-width: 1.5; }
.thumb-up.active,
.thumb-down.active {
  border-color: var(--accent-blue);
  background: rgba(77, 166, 255, 0.18);
  color: var(--accent-blue);
}
.thumb-up.super,
.thumb-down.super {
  border-color: var(--accent-blue);
  background: rgba(77, 166, 255, 0.28);
  color: var(--accent-blue-bright);
  box-shadow: 0 0 10px rgba(77, 166, 255, 0.5);
}
.thumb-up.super .thumb-svg,
.thumb-down.super .thumb-svg {
  filter: drop-shadow(1.5px 0 0 rgba(77, 166, 255, 0.6)) drop-shadow(-1.5px 0 0 rgba(77, 166, 255, 0.6));
}

/* footer hairline */
.footer {
  border-top: 1px solid rgba(77, 166, 255, 0.12);
  background: #131417;
}

@media (max-width: 600px) {
  .hero {
    margin: 1rem 0.75rem 0.5rem;
    padding: 2.25rem 1.25rem 2rem;
  }
  .movie-hero {
    margin: 0.75rem 0.75rem 0;
    border-radius: 10px;
  }
}

