:root {
  --bg: #0b0b10;
  --fg: #f4f6fb;
  --muted: #9aa0af;
  --accent: #e50914;
  --card: #12121a;
  --border: #1f1f2b;
  --shadow: 0 18px 40px rgba(0, 0, 0, 0.4);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: radial-gradient(circle at 20% 20%, rgba(229, 9, 20, 0.14), transparent 30%), var(--bg);
  color: var(--fg);
}

.page {
  max-width: 960px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

.hero {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 20px;
  background: linear-gradient(135deg, rgba(229, 9, 20, 0.2), rgba(229, 9, 20, 0.08));
  border: 1px solid rgba(255, 255, 255, 0.06);
  border-radius: 16px;
  box-shadow: var(--shadow);
}

.hero h1 {
  margin: 6px 0;
  letter-spacing: -0.02em;
}

.hero .lede {
  margin: 0;
  color: var(--muted);
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 12px;
  color: var(--accent);
  margin: 0;
}

.meta {
  display: grid;
  gap: 8px;
  align-content: start;
}

.meta div {
  padding: 10px 12px;
  background: var(--card);
  border-radius: 12px;
  border: 1px solid var(--border);
  text-align: right;
}

.table-wrap {
  margin-top: 24px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
}

table {
  width: 100%;
  border-collapse: collapse;
}

thead {
  background: rgba(255, 255, 255, 0.05);
}

th, td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
}

th {
  text-align: left;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 12px;
  color: var(--muted);
}

tbody tr:hover {
  background: rgba(229, 9, 20, 0.08);
}

.controls {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.control {
  display: flex;
  flex-direction: column;
  gap: 6px;
  color: var(--muted);
  font-size: 14px;
}

.control input,
.control select {
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--fg);
}

.poster {
  width: 140px;
  height: 80px;
  border-radius: 10px;
  overflow: hidden;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.poster img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.poster .placeholder {
  color: var(--muted);
  font-weight: 700;
  font-size: 18px;
}

.genre-text {
  font-size: 13px;
  color: var(--muted);
}

.imdb-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 6px;
  margin-left: 6px;
  font-size: 12px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  text-decoration: none;
  color: var(--fg);
}

.pill {
  display: inline-block;
  padding: 4px 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--border);
  font-size: 12px;
}

.empty {
  padding: 18px;
  text-align: center;
  color: var(--muted);
}

.scroll-visible {
  opacity: 1 !important;
  pointer-events: all !important;
}

.table a {
  color: var(--fg);
  text-decoration: none;
}

.table a:hover {
  text-decoration: underline;
}

#scroll-top {
  position: fixed;
  right: 16px;
  bottom: 16px;
  width: 44px;
  height: 44px;
  z-index: 10;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--card);
  color: var(--fg);
  font-size: 20px;
  cursor: pointer;
  box-shadow: var(--shadow);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease, transform 0.2s ease;
}

#scroll-top:hover {
  transform: translateY(-2px);
}

@media (max-width: 720px) {
  .hero {
    flex-direction: column;
  }

  th:nth-child(3), td:nth-child(3),
  th:nth-child(4), td:nth-child(4),
  th:nth-child(5), td:nth-child(5) {
    display: none;
  }
}
