:root {
  --bg: #08090d;
  --panel: rgba(16, 18, 24, 0.9);
  --card: rgba(18, 20, 28, 0.94);
  --card-hover: rgba(24, 27, 37, 0.98);
  --input: rgba(14, 16, 22, 0.96);
  --text: #f5f7fb;
  --muted: #9ca3b7;
  --soft: #70778d;
  --accent: #8b5cf6;
  --accent2: #a78bfa;
  --lime: #8fe388;
  --gold: #d6b25e;
  --green: #56c288;
  --border: rgba(255, 255, 255, 0.08);
  --shadow: 0 26px 58px rgba(0, 0, 0, 0.48);
  --glow: 0 40px 100px rgba(0, 0, 0, 0.62);
  --btn: linear-gradient(180deg, #7266ff 0%, #5f53e8 100%);
  --btnh: linear-gradient(180deg, #8478ff 0%, #6b60f1 100%);
  --brand-font: "Bebas Neue", "Space Grotesk", sans-serif;
}
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
html {
  color-scheme: dark;
}
body {
  min-height: 100vh;
  font-family: "DM Sans", sans-serif;
  color: var(--text);
  background:
    radial-gradient(
      circle at 20% 0%,
      rgba(139, 92, 246, 0.14),
      transparent 24%
    ),
    radial-gradient(
      circle at 85% 10%,
      rgba(94, 118, 255, 0.1),
      transparent 20%
    ),
    radial-gradient(
      circle at 30% 100%,
      rgba(255, 255, 255, 0.04),
      transparent 22%
    ),
    linear-gradient(180deg, #07080c 0%, #05060a 46%, #030409 100%);
}
body:before,
body:after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: -1;
}
body:before {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: radial-gradient(circle at center, #000 42%, transparent 88%);
  opacity: 0.15;
}
body:after {
  background:
    radial-gradient(
      circle at 30% 20%,
      rgba(139, 92, 246, 0.16),
      transparent 18%
    ),
    radial-gradient(
      circle at 75% 30%,
      rgba(90, 102, 255, 0.12),
      transparent 22%
    );
  filter: blur(46px);
  opacity: 0.95;
}
h1,
h2,
h3,
h4,
h5,
h6,
.card-title,
.detail-info h2,
.slider-header h2,
.stat-card strong {
  font-family: "Space Grotesk", sans-serif;
  letter-spacing: -0.03em;
}
button,
input,
textarea,
select {
  font: inherit;
}
button {
  color: inherit;
}
[data-lucide] {
  width: 1em;
  height: 1em;
  display: inline-block;
  vertical-align: -0.125em;
  stroke-width: 2;
}
.btn-primary,
.btn-secondary,
.btn-danger,
.btn-icon,
.btn-close,
.btn-watched,
.btn-remove-wl,
.btn-add-result,
.btn-remove-selected,
.slider-arrow,
.tab,
.login-tab {
  transition:
    transform 0.2s ease,
    background 0.2s ease,
    border-color 0.2s ease,
    color 0.2s ease,
    box-shadow 0.2s ease,
    opacity 0.2s ease;
}
.btn-primary:focus-visible,
.btn-secondary:focus-visible,
.btn-danger:focus-visible,
.btn-icon:focus-visible,
.btn-close:focus-visible,
.btn-watched:focus-visible,
.btn-remove-wl:focus-visible,
.btn-add-result:focus-visible,
.btn-remove-selected:focus-visible,
.slider-arrow:focus-visible,
.tab:focus-visible,
.login-tab:focus-visible,
input:focus-visible {
  outline: 2px solid rgba(139, 92, 246, 0.86);
  outline-offset: 2px;
}
.btn-watched,
.btn-remove-wl,
.btn-add-result,
.btn-remove-selected {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.login-screen {
  position: fixed;
  inset: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px 20px;
  overflow: auto;
}
.login-card {
  position: relative;
  width: min(100%, 460px);
  margin: auto;
  padding: 34px;
  border-radius: 32px;
  background:
    linear-gradient(180deg, rgba(28, 30, 40, 0.99), rgba(13, 14, 20, 1)),
    linear-gradient(
      135deg,
      rgba(139, 92, 246, 0.18),
      rgba(93, 83, 232, 0.1) 50%,
      rgba(255, 255, 255, 0.02)
    );
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    var(--glow);
  overflow: hidden;
  backdrop-filter: blur(20px);
}
.login-card-glow {
  position: absolute;
  inset: -40% auto auto -18%;
  width: 240px;
  height: 240px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(139, 92, 246, 0.2), transparent 68%);
}
.login-identity,
.login-tabs,
.login-form,
.login-error,
.login-success,
.login-highlights {
  position: relative;
  z-index: 1;
}
.login-badge,
.header-kicker,
.slider-kicker,
.modal-kicker,
.empty-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 12px;
  border-radius: 999px;
  border: 1px solid rgba(139, 92, 246, 0.22);
  background: rgba(139, 92, 246, 0.1);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.14em;
}
.login-logo {
  width: 100px;
  margin: 18px 0 10px;
}
.login-card h1 {
  font-size: clamp(2.3rem, 6vw, 3rem);
  font-weight: 400;
}
.login-subtitle {
  margin-top: 10px;
  color: var(--muted);
  line-height: 1.7;
  font-size: 1rem;
  max-width: 34ch;
}
.login-highlights {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 24px 0;
}
.login-highlights span {
  padding: 9px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 600;
}
.login-tabs {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  padding: 8px;
  margin-bottom: 24px;
  background: rgba(10, 11, 16, 0.88);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: 18px;
}
.login-tab {
  border: 0;
  border-radius: 14px;
  padding: 12px 14px;
  background: transparent;
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
}
.login-tab:hover {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
}
.login-tab.active {
  background: rgba(114, 102, 255, 0.16);
  color: #f4f2ff;
  box-shadow:
    inset 0 0 0 1px rgba(132, 120, 255, 0.36),
    0 10px 24px rgba(22, 18, 48, 0.36);
}
.login-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.form-group label,
.search-section label {
  font-size: 0.84rem;
  font-weight: 700;
  color: #cfddf7;
}
.form-group-sm {
  width: 110px;
}
.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="password"],
.search-box input {
  width: 100%;
  padding: 13px 15px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(12, 14, 21, 0.96), rgba(11, 13, 18, 0.92)),
    var(--input);
  color: var(--text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}
.form-group input::placeholder,
.search-box input::placeholder {
  color: var(--soft);
}
.form-group input:focus,
.search-box input:focus {
  border-color: rgba(139, 92, 246, 0.48);
  box-shadow:
    0 0 0 4px rgba(139, 92, 246, 0.12),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
}
.form-hint {
  color: var(--soft);
  font-size: 0.78rem;
}
.btn-primary,
.btn-secondary,
.btn-danger {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: 46px;
  padding: 11px 18px;
  border-radius: 16px;
  border: 1px solid transparent;
  cursor: pointer;
  font-weight: 700;
}
.btn-primary {
  background: var(--btn);
  color: #f8f8ff;
  border-color: rgba(255, 255, 255, 0.06);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.12),
    0 12px 28px rgba(27, 23, 66, 0.46);
}
.btn-primary:hover {
  background: var(--btnh);
  transform: translateY(-1px);
}
.btn-primary:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}
.btn-secondary {
  background: rgba(255, 255, 255, 0.03);
  border-color: rgba(255, 255, 255, 0.06);
  color: var(--text);
}
.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(139, 92, 246, 0.18);
}
.btn-danger {
  background: rgba(255, 102, 122, 0.08);
  border-color: rgba(255, 102, 122, 0.32);
  color: #ff9aa6;
}
.btn-danger:hover {
  background: linear-gradient(135deg, #ff6b7a, #ff8d63);
  border-color: transparent;
  color: #fff5f4;
}
.btn-full {
  width: 100%;
}
.btn-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  cursor: pointer;
  backdrop-filter: blur(14px);
}
.btn-icon:hover {
  background: rgba(255, 255, 255, 0.06);
}
.btn-lang {
  width: auto;
  min-width: 38px;
  height: 38px;
  padding: 0 10px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 12px;
  color: var(--text-muted);
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
}
.btn-lang:hover {
  color: var(--accent);
  border-color: var(--accent-dim);
  background: rgba(255, 200, 87, 0.06);
}
.btn-lang-login {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  padding: 6px 12px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s, background 0.2s;
}
.btn-lang-login:hover {
  color: var(--accent);
  border-color: var(--accent-dim);
  background: rgba(255, 200, 87, 0.06);
  border-color: rgba(139, 92, 246, 0.22);
}
.btn-close {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  cursor: pointer;
  font-size: 1.4rem;
  line-height: 1;
}
.btn-close:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text);
}
.login-error,
.login-success {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 16px;
  font-size: 0.88rem;
  line-height: 1.45;
}
.login-error {
  border: 1px solid rgba(255, 107, 122, 0.26);
  background: rgba(255, 107, 122, 0.12);
  color: #ff9aa6;
}
.login-success {
  border: 1px solid rgba(55, 211, 159, 0.26);
  background: rgba(55, 211, 159, 0.12);
  color: #8cf8ce;
}
.app-shell {
  width: min(100%, 1480px);
  margin: 0 auto;
  padding: 28px 20px 48px;
}
.app-header {
  margin-bottom: 20px;
}
.header-surface,
.slider-section,
.modal,
.stat-card,
.pending-ratings-banner,
.empty-state-panel,
.section-empty-state {
  border: 1px solid rgba(255, 255, 255, 0.085);
  background:
    linear-gradient(180deg, rgba(27, 29, 38, 0.98), rgba(16, 18, 24, 1)),
    var(--panel);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.045),
    var(--shadow);
  backdrop-filter: blur(18px);
}
.header-surface {
  position: relative;
  overflow: hidden;
  padding: 32px;
  border-radius: 28px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 26px 60px rgba(0, 0, 0, 0.42);
}
.header-surface:before {
  content: "";
  position: absolute;
  inset: auto auto -110px -40px;
  width: 260px;
  height: 260px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(139, 92, 246, 0.14),
    transparent 70%
  );
}
.header-surface:after {
  content: "";
  position: absolute;
  inset: -130px -90px auto auto;
  width: 300px;
  height: 300px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(104, 112, 255, 0.09),
    transparent 70%
  );
}
.header-top,
.tabs,
.slider-header,
.modal-header,
.modal-body,
.section-empty-state,
.pending-ratings-banner,
.stats-bar {
  position: relative;
  z-index: 1;
}
.header-top {
  display: flex;
  justify-content: space-between;
  gap: 24px;
  align-items: flex-start;
}
.header-content {
  max-width: 820px;
}
.header-title-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: 12px;
}
.header-content h1 {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-size: clamp(2.25rem, 4vw, 3.3rem);
  letter-spacing: -0.05em;
}
.header-logo {
  height: 80px;
  filter: drop-shadow(0 14px 22px rgba(0, 0, 0, 0.34));
}
.room-pill {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 14px;
  min-width: 140px;
  border-radius: 18px;
  background: rgba(11, 12, 18, 0.76);
  border: 1px solid rgba(139, 92, 246, 0.16);
}
.room-pill span {
  font-size: 0.72rem;
  color: var(--soft);
  text-transform: uppercase;
  letter-spacing: 0.12em;
}
.room-pill strong {
  font-family: "Space Grotesk", sans-serif;
  font-size: 0.98rem;
}
.brand-wordmark {
  display: inline-block;
  font-family: var(--brand-font);
  font-weight: 400;
  letter-spacing: 0.055em;
  line-height: 0.92;
  text-transform: uppercase;
  color: #fdfdff;
  text-shadow:
    0 0 24px rgba(114, 102, 255, 0.16),
    0 4px 18px rgba(0, 0, 0, 0.42);
}
.login-title {
  margin-top: 2px;
}
.login-title .brand-wordmark {
  font-size: clamp(3.1rem, 8vw, 4.8rem);
}
.header-content h1 .brand-wordmark {
  font-size: clamp(2.8rem, 5vw, 4.5rem);
}
.subtitle {
  margin-top: 14px;
  color: #b5bdd1;
  line-height: 1.75;
  font-size: 1rem;
  max-width: 56ch;
}
.header-actions {
  display: flex;
  align-items: center;
  gap: 12px;
}
.tabs {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 28px;
}
.tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 10px 16px;
  border-radius: 16px;
  border: 1px solid rgba(255, 255, 255, 0.07);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  cursor: pointer;
  font-size: 0.92rem;
  font-weight: 700;
}
.tab:hover {
  color: var(--text);
  border-color: rgba(139, 92, 246, 0.22);
  background: rgba(139, 92, 246, 0.08);
}
.tab.active {
  color: #f7f4ff;
  border-color: rgba(132, 120, 255, 0.24);
  background: rgba(114, 102, 255, 0.14);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.03),
    0 8px 18px rgba(27, 18, 56, 0.28);
}
.saving-indicator {
  position: sticky;
  top: 18px;
  z-index: 30;
  width: fit-content;
  margin: 0 auto 18px;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid rgba(55, 211, 159, 0.26);
  background: rgba(18, 46, 37, 0.88);
  color: #8dfbc8;
  font-size: 0.83rem;
  font-weight: 700;
  box-shadow: 0 18px 32px rgba(0, 0, 0, 0.25);
}
.app-main,
.content-stack {
  display: flex;
  flex-direction: column;
  gap: 18px;
}
.stats-bar {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 14px;
}
.stat-card {
  padding: 20px;
  border-radius: 20px;
}
.stat-label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 14px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.stat-card strong {
  display: block;
  font-size: 2rem;
  line-height: 1;
}
.stat-foot {
  display: block;
  margin-top: 6px;
  color: var(--soft);
  font-size: 0.84rem;
  line-height: 1.45;
}
.pending-ratings-banner {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  border-radius: 24px;
}
.pending-ratings-banner span {
  flex: 1;
  color: var(--muted);
  line-height: 1.5;
}
.pending-ratings-banner i {
  color: var(--gold);
  flex-shrink: 0;
}
.btn-pending-rate {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  padding: 0 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 200, 87, 0.26);
  background: rgba(255, 200, 87, 0.1);
  color: #ffd98c;
  cursor: pointer;
  font-size: 0.82rem;
  font-weight: 700;
  white-space: nowrap;
}
.btn-pending-rate:hover {
  background: rgba(255, 200, 87, 0.18);
  border-color: rgba(255, 200, 87, 0.44);
}
.slider-section {
  padding: 28px;
  border-radius: 24px;
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 18px 44px rgba(0, 0, 0, 0.34);
}
.slider-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start;
  margin-bottom: 18px;
}
.slider-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}
.slider-header h2 {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 1.42rem;
  letter-spacing: -0.045em;
  color: #fafbff;
}
.slider-support {
  max-width: 720px;
  color: #a8afc2;
  line-height: 1.72;
  font-size: 0.94rem;
}
.slider-tools {
  display: flex;
  align-items: center;
  gap: 10px;
}
.slider-count {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.06);
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
}
.slider-container {
  position: relative;
}
.slider-track {
  display: flex;
  gap: 18px;
  overflow-x: auto;
  padding: 8px 2px 4px;
  scroll-behavior: smooth;
  scrollbar-width: none;
}
.slider-track::-webkit-scrollbar {
  display: none;
}
.slider-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 50%;
  background: rgba(14, 16, 23, 0.94);
  color: var(--text);
  cursor: pointer;
  display: none;
  align-items: center;
  justify-content: center;
  box-shadow: 0 14px 32px rgba(0, 0, 0, 0.35);
  backdrop-filter: blur(12px);
}
.slider-arrow:hover {
  background: rgba(139, 92, 246, 0.12);
  border-color: rgba(139, 92, 246, 0.24);
}
.slider-arrow-left {
  left: -6px;
}
.slider-arrow-right {
  right: -6px;
}
.slider-track .movie-card,
.slider-track .watchlist-card {
  min-width: 220px;
  max-width: 220px;
  flex-shrink: 0;
}
.movie-card,
.watchlist-card {
  position: relative;
  overflow: hidden;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background:
    linear-gradient(180deg, rgba(29, 32, 42, 0.98), rgba(17, 19, 26, 1)),
    var(--card);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.04),
    0 16px 34px rgba(0, 0, 0, 0.34);
}
.movie-card {
  cursor: pointer;
}
.movie-card:hover,
.watchlist-card:hover {
  transform: translateY(-3px);
  border-color: rgba(132, 120, 255, 0.2);
  background:
    linear-gradient(180deg, rgba(34, 38, 51, 1), rgba(20, 22, 30, 1)),
    var(--card-hover);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 22px 42px rgba(0, 0, 0, 0.4);
}
.poster-container {
  position: relative;
  aspect-ratio: 2/3;
  overflow: hidden;
  background:
    radial-gradient(circle at top, rgba(139, 92, 246, 0.12), transparent 58%),
    linear-gradient(180deg, #1b1f2b, #10131b);
}
.poster-container:after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 56%;
  background: linear-gradient(180deg, transparent, rgba(5, 6, 10, 0.94));
  pointer-events: none;
}
.poster-container img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.28s ease;
}
.movie-card:hover .poster-container img,
.watchlist-card:hover .poster-container img {
  transform: scale(1.04);
}
.no-poster,
.detail-poster-empty,
.selected-item-placeholder,
.search-result-poster-fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  background:
    radial-gradient(circle at top, rgba(139, 92, 246, 0.12), transparent 58%),
    linear-gradient(180deg, #1b1f2b, #10131b);
  color: rgba(255, 255, 255, 0.82);
}
.no-poster {
  width: 100%;
  height: 100%;
  font-size: 2.8rem;
}
.selected-item-placeholder {
  width: 44px;
  height: 66px;
  border-radius: 12px;
  flex-shrink: 0;
}
.movie-card .rank-badge {
  position: absolute;
  top: 14px;
  left: 14px;
  z-index: 2;
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 0.9rem;
  font-weight: 800;
  color: #f7f5ff;
  background: linear-gradient(180deg, #7c6aff, #5f53e8);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 0 0 2px rgb(155 160 179 / 78%),
    0 10px 18px rgba(19, 15, 48, 0.3);
  backdrop-filter: blur(8px);
}
.rank-badge.rank-1 {
  color: #10131b;
  background: linear-gradient(135deg, #fff3a0, #ffc857);
}
.rank-badge.rank-2 {
  background: linear-gradient(135deg, #f4f7ff, #9cb3d8);
}
.rank-badge.rank-3 {
  background: linear-gradient(135deg, #ffca93, #ff8d63);
}
.btn-info {
  position: absolute;
  top: 14px;
  right: 14px;
  z-index: 2;
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(10, 11, 17, 0.78);
  color: var(--text);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  backdrop-filter: blur(10px);
  opacity: 0.4;
}
.btn-info:hover {
  opacity: 1;
  background: rgba(139, 92, 246, 0.18);
}
.movie-card:hover .btn-info,
.watchlist-card:hover .btn-info,
.btn-info:focus-visible {
  opacity: 1;
}
.card-info {
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 16px;
}
.card-title {
  font-size: 1rem;
  font-weight: 650;
  line-height: 1.3;
  color: #fbfcff;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.card-year,
.card-genre,
.card-rating-details {
  color: #a3abc0;
}
.card-year {
  font-size: 0.8rem;
  font-weight: 650;
}
.card-genre {
  font-size: 0.77rem;
  line-height: 1.58;
  min-height: 1.1rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.card-rating {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
}
.rating-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 56px;
  min-height: 32px;
  padding: 0 12px;
  border-radius: 999px;
  font-size: 0.86rem;
  font-weight: 700;
}
.rating-badge.high {
  background: rgba(55, 211, 159, 0.18);
  color: #82f6cb;
}
.rating-badge.mid {
  background: rgba(255, 200, 87, 0.16);
  color: #ffd98c;
}
.rating-badge.low {
  background: rgba(255, 107, 122, 0.16);
  color: #ff9aa6;
}
.rating-badge.none {
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
}
.card-rating-details {
  font-size: 0.76rem;
  line-height: 1.45;
}
.watchlist-actions,
.rec-actions {
  display: flex;
  gap: 8px;
  width: 100%;
}
.rec-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: stretch;
}
.btn-watched,
.btn-remove-wl {
  min-height: 38px;
  border-radius: 14px;
  cursor: pointer;
  font-size: 0.78rem;
  font-weight: 700;
}
.btn-watched {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid rgba(139, 92, 246, 0.18);
  background: rgba(139, 92, 246, 0.1);
  color: #c7b4ff;
  line-height: 1.25;
  text-align: center;
  white-space: normal;
}
.btn-watched:hover:not(:disabled) {
  background: rgba(139, 92, 246, 0.16);
  border-color: rgba(139, 92, 246, 0.28);
}
.rec-actions .btn-watched:only-child,
.btn-rec-dismiss {
  grid-column: 1 / -1;
}
.btn-rec-watched {
  border-color: rgba(96, 118, 255, 0.2);
  background: rgba(96, 118, 255, 0.1);
  color: #b6c3ff;
}
.btn-rec-dismiss {
  border-color: rgba(255, 107, 122, 0.24);
  background: rgba(255, 107, 122, 0.1);
  color: #ff98a6;
}
.btn-rec-dismiss:hover:not(:disabled) {
  background: rgba(255, 107, 122, 0.18);
  border-color: rgba(255, 107, 122, 0.42);
}
.btn-remove-wl {
  min-width: 40px;
  border: 1px solid rgba(255, 107, 122, 0.24);
  background: rgba(255, 107, 122, 0.1);
  color: #ff98a6;
}
.btn-remove-wl:hover {
  background: rgba(255, 107, 122, 0.18);
  border-color: rgba(255, 107, 122, 0.42);
}
.card-tmdb-score {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: #ffd98c;
  font-size: 0.78rem;
  font-weight: 700;
}
.recommendation-card {
  border-color: rgba(255, 200, 87, 0.14);
}
.recommendation-card .card-info {
  gap: 10px;
}
.recommendation-card .card-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  white-space: normal;
  min-height: 2.6em;
}
.recommendation-card .card-year {
  min-height: 1rem;
}
.recommendation-card .card-tmdb-score {
  min-height: 1rem;
}
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 22px;
  background:
    radial-gradient(circle at top, rgba(114, 102, 255, 0.12), transparent 22%),
    rgba(3, 4, 7, 0.82);
  backdrop-filter: blur(16px);
}
.modal {
  width: min(100%, 620px);
  max-height: min(92vh, 900px);
  overflow-y: auto;
  border-radius: 30px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow:
    inset 0 1px 0 rgba(255, 255, 255, 0.05),
    0 36px 90px rgba(0, 0, 0, 0.56),
    0 0 0 1px rgba(255, 255, 255, 0.02);
}
.modal-sm {
  width: min(100%, 480px);
}
.modal-lg {
  width: min(100%, 860px);
}
.modal-header {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  padding: 22px 24px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  padding-bottom: 18px;
}
.modal-header h2 {
  margin-top: 8px;
  font-size: 1.36rem;
  letter-spacing: -0.04em;
  color: #fbfcff;
}
.modal-body {
  padding: 22px 24px 24px;
}
.modal-emphasis {
  margin-bottom: 18px;
  font-size: 1.06rem;
  font-weight: 700;
}
.form-row {
  display: flex;
  gap: 14px;
}
.flex-1 {
  flex: 1;
}
.section-title {
  padding-top: 14px;
  margin-top: 2px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
}
.rating-section {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}
.rating-option {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 14px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.025);
}
.rating-option label {
  cursor: pointer;
  font-weight: 600;
  color: var(--muted);
}
.rating-slider-group {
  display: flex;
  align-items: center;
  gap: 12px;
}
.rating-slider-group input[type="range"] {
  flex: 1;
  appearance: none;
  height: 8px;
  border-radius: 999px;
  background: linear-gradient(
    90deg,
    rgba(95, 73, 216, 0.42),
    rgba(167, 139, 250, 0.7)
  );
  outline: none;
}
.rating-slider-group input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  width: 22px;
  height: 22px;
  border: 2px solid #f5f1ff;
  border-radius: 50%;
  background: #8b5cf6;
  box-shadow: 0 4px 12px rgba(41, 28, 82, 0.34);
  cursor: pointer;
}
.rating-value {
  min-width: 42px;
  font-family: "Space Grotesk", sans-serif;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
  text-align: center;
}
.form-actions {
  display: flex;
  gap: 12px;
}
.form-actions-single {
  margin-top: 18px;
}
.search-box {
  display: flex;
  gap: 10px;
  margin-top: 8px;
}
.search-results,
.selected-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
  max-height: 320px;
  overflow-y: auto;
}
.search-result-item,
.selected-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.05);
  background: rgba(255, 255, 255, 0.025);
}
.search-result-item:hover {
  border-color: rgba(139, 92, 246, 0.16);
  background: rgba(139, 92, 246, 0.05);
}
.search-result-item.selected {
  opacity: 0.58;
}
.search-result-item img,
.selected-item img {
  width: 44px;
  height: 66px;
  object-fit: cover;
  border-radius: 12px;
  background: #0d1524;
}
.search-result-poster-fallback {
  width: 44px;
  height: 66px;
  border-radius: 12px;
}
.search-result-info,
.selected-item-info {
  flex: 1;
  min-width: 0;
}
.search-result-info .title,
.selected-item-info .title {
  display: block;
  font-weight: 700;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.search-result-info .year,
.selected-item-info .meta {
  margin-top: 4px;
  color: var(--muted);
  font-size: 0.8rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.btn-add-result,
.btn-remove-selected {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.btn-add-result {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid rgba(139, 92, 246, 0.24);
  background: rgba(139, 92, 246, 0.1);
  color: #ccb8ff;
  cursor: pointer;
}
.btn-add-result:hover:not(:disabled) {
  background: rgba(139, 92, 246, 0.18);
}
.btn-add-result.added {
  border-color: rgba(55, 211, 159, 0.28);
  background: rgba(55, 211, 159, 0.14);
  color: #8cf8ce;
}
.btn-add-result:disabled {
  cursor: default;
}
.selected-section {
  margin-top: 16px;
}
.btn-remove-selected {
  width: 34px;
  height: 34px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 107, 122, 0.08);
  color: #ff98a6;
  cursor: pointer;
}
.btn-remove-selected:hover {
  background: rgba(255, 107, 122, 0.16);
}
.inline-feedback {
  padding: 14px 6px;
  color: var(--muted);
  font-size: 0.88rem;
}
.inline-feedback.error {
  color: #ff98a6;
}
.detail-header {
  display: flex;
  gap: 24px;
  padding: 28px;
  margin: -24px -24px 24px;
  border-radius: 24px 24px 18px 18px;
  background:
    linear-gradient(180deg, rgba(26, 29, 40, 0.66), rgba(13, 15, 21, 0.98)),
    linear-gradient(135deg, rgba(139, 92, 246, 0.22), rgba(96, 102, 246, 0.12));
  background-size: cover;
  background-position: center top;
  box-shadow: inset 0 -1px 0 rgba(255, 255, 255, 0.04);
}
.detail-poster,
.detail-poster-empty {
  width: 170px;
  height: 255px;
  border-radius: 20px;
  flex-shrink: 0;
  box-shadow: 0 20px 38px rgba(0, 0, 0, 0.32);
}
.detail-poster {
  object-fit: cover;
}
.detail-info {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 12px;
  min-width: 0;
}
.detail-info h2 {
  font-size: clamp(1.85rem, 4vw, 2.45rem);
  line-height: 1.02;
}
.detail-original-title,
.detail-genres,
.detail-section p,
.detail-loading,
.detail-no-rating {
  color: var(--muted);
}
.detail-original-title {
  font-size: 0.9rem;
}
.detail-meta,
.detail-user-ratings,
.detail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.detail-meta span,
.detail-rating-item {
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(255, 255, 255, 0.065);
  font-size: 0.82rem;
}
.detail-tmdb-score {
  color: #ffd98c;
  font-size: 0.9rem;
  font-weight: 700;
}
.detail-rating-item {
  color: #a8f6ff;
}
.detail-section + .detail-section {
  margin-top: 22px;
}
.detail-section h3 {
  margin-bottom: 10px;
  font-size: 1rem;
}
.detail-section p {
  line-height: 1.72;
  font-size: 0.94rem;
}
.detail-cast-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
  gap: 12px;
}
.detail-cast-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 18px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.03);
}
.detail-cast-item img,
.cast-no-photo {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #102038;
}
.cast-no-photo {
  display: flex;
  align-items: center;
  justify-content: center;
}
.cast-text {
  min-width: 0;
}
.cast-name,
.cast-character {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.cast-name {
  font-weight: 700;
}
.cast-character {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.78rem;
}
.section-empty-state {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px;
  border-style: dashed;
  border-radius: 24px;
}
.section-empty-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 54px;
  height: 54px;
  border-radius: 18px;
  background: rgba(139, 92, 246, 0.12);
  color: var(--accent);
  flex-shrink: 0;
}
.section-empty-copy {
  flex: 1;
}
.section-empty-copy h3 {
  font-size: 1.05rem;
  margin-bottom: 6px;
}
.section-empty-copy p {
  color: var(--muted);
  line-height: 1.55;
}
.section-hint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  margin-bottom: 14px;
  border-radius: 16px;
  border: 1px solid rgba(255, 200, 87, 0.18);
  background: rgba(255, 200, 87, 0.08);
  color: #f2d29e;
  line-height: 1.5;
  font-size: 0.86rem;
}
.btn-refresh-recs {
  width: 38px;
  height: 38px;
  border-radius: 14px;
}
.empty-state {
  padding: 6px 0 0;
}
.empty-state-panel {
  display: grid;
  justify-items: center;
  gap: 14px;
  padding: 44px 32px;
  border-radius: 28px;
  text-align: center;
}
.empty-icon {
  width: 126px;
  filter: drop-shadow(0 16px 26px rgba(0, 0, 0, 0.32));
}
.empty-state-panel h2 {
  font-size: 1.8rem;
}
.empty-state-panel p {
  max-width: 560px;
  color: var(--muted);
  line-height: 1.65;
}
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}
::-webkit-scrollbar-track {
  background: transparent;
}
::-webkit-scrollbar-thumb {
  background: rgba(134, 160, 206, 0.32);
  border-radius: 999px;
}
::-webkit-scrollbar-thumb:hover {
  background: rgba(134, 160, 206, 0.5);
}
@media (max-width: 980px) {
  .header-top,
  .slider-header,
  .section-empty-state,
  .form-row,
  .detail-header {
    flex-direction: column;
  }
  .header-actions,
  .slider-tools {
    width: 100%;
    justify-content: flex-start;
  }
  .detail-info {
    align-items: flex-start;
  }
  .detail-meta,
  .detail-user-ratings,
  .detail-actions {
    justify-content: flex-start;
  }
}
@media (max-width: 768px) {
  .app-shell {
    padding: 16px 14px 28px;
  }
  .login-card,
  .header-surface,
  .slider-section,
  .modal-body {
    padding-left: 20px;
    padding-right: 20px;
  }
  .header-title-row {
    align-items: flex-start;
    margin-top: 6px;
    gap: 12px;
  }
  .header-logo {
    height: 44px;
  }
  .room-pill {
    padding: 8px 12px;
    min-width: auto;
  }
  .header-actions {
    flex-direction: row;
    width: auto;
  }
  .header-top {
    flex-direction: row;
    align-items: center;
    gap: 16px;
  }
  .tabs {
    gap: 8px;
    flex-wrap: nowrap;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    padding-bottom: 4px;
  }
  .tabs::-webkit-scrollbar {
    display: none;
  }
  .tab {
    flex: 0 0 auto;
    min-height: 40px;
    padding: 8px 14px;
    font-size: 0.85rem;
  }
  .subtitle {
    display: none;
  }
  .header-surface {
    padding-top: 16px;
    padding-bottom: 20px;
  }
  .tabs {
    margin-top: 16px;
  }
  #btn-add span {
    display: none;
  }
  #btn-add {
    padding: 8px 12px;
    min-height: 40px;
  }
  .stats-bar {
    grid-template-columns: 1fr 1fr;
  }
  .slider-track {
    gap: 14px;
  }
  .slider-track .movie-card,
  .slider-track .watchlist-card {
    min-width: 180px;
    max-width: 180px;
  }
  .slider-arrow {
    width: 36px;
    height: 36px;
  }
  .section-empty-state,
  .pending-ratings-banner {
    align-items: flex-start;
  }
  .detail-poster,
  .detail-poster-empty {
    width: 140px;
    height: 210px;
  }
  .detail-cast-grid {
    grid-template-columns: 1fr;
  }
}
@media (max-width: 560px) {
  .login-card {
    padding: 24px 18px;
  }
  .stats-bar {
    grid-template-columns: 1fr;
  }
  .tab {
    flex: 0 0 auto;
  }
  .search-box,
  .watchlist-actions,
  .form-actions {
    flex-direction: column;
  }
  .rec-actions {
    grid-template-columns: 1fr;
  }
  .btn-rec-dismiss {
    grid-column: auto;
  }
  .slider-track .movie-card,
  .slider-track .watchlist-card {
    min-width: 158px;
    max-width: 158px;
  }
  .slider-support,
  .subtitle,
  .empty-state-panel p {
    font-size: 0.92rem;
  }
}
