/* Account features: action bar on watch/game pages, dashboard panels, profile and list pages. */
:root {
  --acc-pink: #ff3dff;
  --acc-green: #00e887;
  --acc-amber: #ffb84d;
  --acc-red: #ff5c7a;
  --acc-bg: rgba(18, 18, 22, 0.92);
  --acc-card: rgba(255, 255, 255, 0.04);
  --acc-line: rgba(255, 255, 255, 0.1);
  --acc-text: rgba(255, 255, 255, 0.92);
  --acc-muted: rgba(255, 255, 255, 0.58);
}

/* ---------- action bar (rating, mark watched, add to list, wishlist) ---------- */
.acc-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 12px 0 4px;
  font-size: 0.88rem;
  color: var(--acc-text);
}
.acc-bar-group {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  background: var(--acc-card);
  border: 1px solid var(--acc-line);
  border-radius: 999px;
  padding: 3px;
}
.acc-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 34px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--acc-text);
  font: inherit;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
  white-space: nowrap;
}
.acc-btn:hover { background: rgba(255, 255, 255, 0.08); }
.acc-btn:focus-visible { outline: 2px solid var(--acc-pink); outline-offset: 2px; }
.acc-btn[disabled] { opacity: 0.5; cursor: default; }
.acc-btn.solo { background: var(--acc-card); border-color: var(--acc-line); }
.acc-btn.is-on { background: rgba(255, 61, 255, 0.16); border-color: rgba(255, 61, 255, 0.5); color: #fff; }
.acc-btn.is-on.good { background: rgba(0, 232, 135, 0.14); border-color: rgba(0, 232, 135, 0.5); }
.acc-btn .acc-count { color: var(--acc-muted); font-size: 0.78rem; }
.acc-react { padding: 6px 9px; font-size: 1.05rem; }
.acc-react.is-on { transform: scale(1.06); }
.acc-react-love.is-on i { color: #ff5fd2; }
.acc-react-like.is-on i { color: var(--acc-green); }
.acc-react-meh.is-on i { color: var(--acc-amber); }
.acc-react-dislike.is-on i { color: var(--acc-red); }
.acc-ep-tick { margin-top: 4px; }
.acc-label { color: var(--acc-muted); font-size: 0.8rem; padding: 0 6px 0 8px; }
.acc-hint { color: var(--acc-muted); font-size: 0.82rem; }

/* episode ticks injected next to episode buttons */
.acc-ep-tick {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  margin-left: 6px;
  border-radius: 50%;
  background: var(--acc-green);
  color: #062;
  font-size: 11px;
  font-weight: 800;
  vertical-align: middle;
}

/* ---------- popover (add to list) ---------- */
.acc-pop {
  position: fixed;
  z-index: 10050;
  width: min(320px, calc(100vw - 24px));
  max-height: min(420px, 70vh);
  overflow: auto;
  background: #141418;
  border: 1px solid var(--acc-line);
  border-radius: 14px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
  padding: 10px;
  color: var(--acc-text);
}
.acc-pop h4 { margin: 4px 6px 8px; font-size: 0.95rem; }
.acc-pop label.acc-check {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px;
  border-radius: 8px;
  cursor: pointer;
}
.acc-pop label.acc-check:hover { background: rgba(255, 255, 255, 0.06); }
.acc-pop input[type="checkbox"] { width: 16px; height: 16px; accent-color: var(--acc-pink); }
.acc-pop .acc-new { display: flex; gap: 6px; margin-top: 8px; border-top: 1px solid var(--acc-line); padding-top: 10px; }

/* ---------- toasts ---------- */
.acc-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 10060;
  background: #1c1c22;
  color: #fff;
  border: 1px solid var(--acc-line);
  border-radius: 12px;
  padding: 10px 16px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
  font-size: 0.9rem;
  max-width: calc(100vw - 32px);
}
.acc-toast.error { border-color: rgba(255, 92, 122, 0.6); }

/* ---------- header bell ---------- */
.acc-bell-badge {
  position: absolute;
  top: 2px;
  right: 2px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: var(--acc-pink);
  color: #fff;
  font-size: 10px;
  font-weight: 800;
  line-height: 16px;
  text-align: center;
}
.nav-item.acc-bell-link { position: relative; }

/* ---------- forms & panels (dashboard tabs, profile, list pages) ---------- */
.acc-panel { color: var(--acc-text); }
.acc-section {
  background: var(--acc-card);
  border: 1px solid var(--acc-line);
  border-radius: 16px;
  padding: 18px;
  margin-bottom: 16px;
}
.acc-section h3 { margin: 0 0 6px; font-size: 1.05rem; }
.acc-section p.acc-sub { margin: 0 0 14px; color: var(--acc-muted); font-size: 0.88rem; line-height: 1.5; }
.acc-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.acc-input {
  flex: 1 1 200px;
  min-height: 40px;
  padding: 9px 12px;
  border-radius: 10px;
  border: 1px solid var(--acc-line);
  background: rgba(0, 0, 0, 0.35);
  color: #fff;
  font: inherit;
}
.acc-input:focus { outline: none; border-color: var(--acc-pink); }
.acc-primary {
  min-height: 40px;
  padding: 9px 16px;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, #ff3dff, #b400ff);
  color: #fff;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
}
.acc-primary[disabled] { opacity: 0.55; cursor: default; }
.acc-ghost {
  min-height: 40px;
  padding: 9px 14px;
  border-radius: 10px;
  border: 1px solid var(--acc-line);
  background: transparent;
  color: var(--acc-text);
  font: inherit;
  cursor: pointer;
}
.acc-ghost:hover { background: rgba(255, 255, 255, 0.06); }
.acc-danger { border-color: rgba(255, 92, 122, 0.5); color: #ffb3c1; }
.acc-toggle { display: flex; align-items: flex-start; gap: 10px; padding: 8px 0; cursor: pointer; }
.acc-toggle input { margin-top: 3px; width: 16px; height: 16px; accent-color: var(--acc-pink); }
.acc-toggle small { display: block; color: var(--acc-muted); }
.acc-msg { margin-top: 10px; font-size: 0.88rem; }
.acc-msg.error { color: #ff9db0; }
.acc-msg.ok { color: #7dffc4; }
.acc-code {
  display: inline-block;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  background: rgba(0, 0, 0, 0.45);
  border: 1px dashed rgba(255, 61, 255, 0.6);
  padding: 6px 10px;
  border-radius: 8px;
  letter-spacing: 0.08em;
  user-select: all;
}
.acc-codes { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; margin: 10px 0; }
.acc-stats { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; margin: 12px 0; }
.acc-stat { background: rgba(0, 0, 0, 0.3); border: 1px solid var(--acc-line); border-radius: 12px; padding: 10px 12px; }
.acc-stat b { display: block; font-size: 1.25rem; }
.acc-stat span { color: var(--acc-muted); font-size: 0.78rem; }
.acc-table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
.acc-table td, .acc-table th { padding: 9px 6px; border-bottom: 1px solid var(--acc-line); text-align: left; vertical-align: middle; }
.acc-table th { color: var(--acc-muted); font-weight: 600; }
.acc-pill { display: inline-block; padding: 2px 8px; border-radius: 999px; font-size: 0.75rem; background: rgba(255, 255, 255, 0.08); color: var(--acc-muted); }
.acc-pill.on { background: rgba(0, 232, 135, 0.15); color: #7dffc4; }
.acc-pill.soon { background: rgba(255, 184, 77, 0.16); color: var(--acc-amber); }
.acc-empty { color: var(--acc-muted); text-align: center; padding: 26px 10px; }
.acc-qr { background: #fff; padding: 10px; border-radius: 10px; display: inline-block; }

/* poster grid used by the new dashboard tabs, profile and list pages */
.acc-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 14px; }
.acc-card { position: relative; display: block; color: inherit; text-decoration: none; border-radius: 12px; overflow: hidden; background: rgba(255, 255, 255, 0.03); border: 1px solid var(--acc-line); }
.acc-card img { display: block; width: 100%; aspect-ratio: 2 / 3; object-fit: cover; background: #111; }
.acc-card.wide img { aspect-ratio: 460 / 215; }
.acc-card .acc-card-body { padding: 8px 10px 10px; }
.acc-card .acc-card-title { font-size: 0.86rem; font-weight: 600; line-height: 1.3; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.acc-card .acc-card-meta { color: var(--acc-muted); font-size: 0.76rem; margin-top: 4px; }
.acc-card .acc-card-x {
  position: absolute; top: 6px; right: 6px; width: 28px; height: 28px; border-radius: 50%;
  border: 0; background: rgba(0, 0, 0, 0.7); color: #fff; cursor: pointer; font-size: 16px; line-height: 28px;
}
.acc-card .acc-card-badge { position: absolute; top: 6px; left: 6px; font-size: 1.1rem; filter: drop-shadow(0 1px 2px rgba(0,0,0,.8)); }
.acc-progress { height: 4px; background: rgba(255, 255, 255, 0.12); }
.acc-progress > i { display: block; height: 100%; background: var(--acc-pink); }

.acc-notif { display: flex; gap: 12px; align-items: center; padding: 12px; border-bottom: 1px solid var(--acc-line); }
.acc-notif.unread { background: rgba(255, 61, 255, 0.06); }
.acc-notif img { width: 46px; height: 46px; object-fit: cover; border-radius: 8px; flex: none; background: #111; }
.acc-notif .acc-notif-body { flex: 1; min-width: 0; }
.acc-notif .acc-notif-title { font-weight: 600; }
.acc-notif .acc-notif-sub { color: var(--acc-muted); font-size: 0.82rem; }

/* public profile / list pages */
.acc-page { max-width: 1100px; margin: 0 auto; padding: 96px 16px 48px; color: var(--acc-text); }
.acc-hero { display: flex; gap: 18px; align-items: center; margin-bottom: 22px; flex-wrap: wrap; }
.acc-avatar {
  width: 84px; height: 84px; border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 2.4rem; background: linear-gradient(135deg, rgba(255, 61, 255, 0.35), rgba(0, 232, 135, 0.25));
  border: 2px solid rgba(255, 255, 255, 0.15); flex: none;
}
.acc-hero h1 { margin: 0; font-size: 1.8rem; }
.acc-hero .acc-sub { color: var(--acc-muted); margin-top: 4px; }
.acc-h2 { font-size: 1.15rem; margin: 26px 0 12px; }

@media (max-width: 600px) {
  .acc-grid { grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 10px; }
  .acc-page { padding-top: 80px; }
  .acc-bar { gap: 6px; }
  .acc-btn { padding: 6px 10px; }
}
