/* Game-, Serien- und Film-Detailseiten: 16:9 Kino-Backdrop, Bento-Stats & Runder Cast */

main {
  position: relative;
}

/* ---------- 1. Großflächiger Cinematic Widescreen-Backdrop ---------- */
.detail-hero-backdrop {
  position: absolute;
  top: -24px;
  left: 50%;
  transform: translateX(-50%);
  width: 100vw;
  height: 640px;
  background-size: cover;
  background-position: center 15%;
  pointer-events: none;
  z-index: 0;
  filter: saturate(1.1) brightness(0.85);
  background-repeat: no-repeat;
}

/* Mehrschichtiger Kinoverlauf: Links dunkel für Text, unten 100% Schwarz */
.detail-hero-backdrop::after {
  content: '';
  position: absolute;
  inset: 0;
  background: 
    linear-gradient(90deg, var(--bg) 0%, rgba(15, 17, 21, 0.94) 35%, rgba(15, 17, 21, 0.45) 70%, rgba(15, 17, 21, 0.9) 100%),
    linear-gradient(180deg, rgba(15, 17, 21, 0.15) 0%, rgba(15, 17, 21, 0.5) 60%, var(--bg) 100%);
}

.detail-head,
.movie-stats-bento,
.game-info-grid,
.season-block,
.cast-section,
.streaming-hub,
.game-screenshots-wrap {
  position: relative;
  z-index: 2;
}

/* Poster mit Tiefenschatten & leichtem Schein */
.detail-poster {
  width: 185px;
  min-width: 185px;
  height: 275px;
  aspect-ratio: 2 / 3;
  object-fit: cover;
  object-position: center;
  background: var(--bg-raised);
  border: 1px solid rgba(255, 255, 255, 0.12);
  flex-shrink: 0;
  border-radius: var(--radius-md);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.8), 0 0 20px rgba(0, 0, 0, 0.5);
}

.detail-title {
  font-size: 56px;
  line-height: 0.95;
  margin: 0 0 10px;
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.8);
}

/* ---------- 2. Runde Schauspieler- & Rollen-Galerie (Cast) ---------- */
.cast-section {
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--line);
  position: relative;
  z-index: 2;
}
.cast-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
}
.cast-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 26px;
  color: var(--text);
  margin: 0;
  letter-spacing: 0.03em;
}
.cast-row {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 6px 4px 16px;
  scroll-snap-type: x proximity;
  scrollbar-width: thin;
  scrollbar-color: var(--line) transparent;
}
.cast-row::-webkit-scrollbar { height: 6px; }
.cast-row::-webkit-scrollbar-thumb { background: var(--line); border-radius: 999px; }

.cast-member {
  flex: 0 0 92px;
  width: 92px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  scroll-snap-align: start;
}
.cast-avatar {
  width: 74px;
  height: 74px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-card);
  border: 2px solid var(--line);
  margin-bottom: 8px;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.5);
  transition: transform 0.2s cubic-bezier(0.16, 1, 0.3, 1), border-color 0.2s ease, box-shadow 0.2s ease;
}
.cast-member:hover .cast-avatar {
  transform: scale(1.1);
  border-color: var(--accent);
  box-shadow: 0 8px 20px var(--accent-glow);
}
.cast-avatar-placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  color: var(--text-dim);
}
.cast-name {
  font-size: 12px;
  font-weight: 700;
  color: var(--text);
  line-height: 1.25;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}
.cast-character {
  font-size: 11px;
  color: var(--text-dim);
  margin-top: 2px;
  line-height: 1.2;
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  overflow: hidden;
}

/* ---------- 3. Detail-Layout & Bento Stats ---------- */
.badge-lg {
  font-size: 13px !important;
  font-weight: 700 !important;
  padding: 6px 14px !important;
  border-radius: var(--radius-sm) !important;
  max-width: none !important;
  height: auto !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
}

.game-meta-group {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 16px 0;
}

.game-quick-links-lg {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}
.game-link-btn {
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 13px;
  font-weight: 700;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s ease;
}
.game-link-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
  transform: translateY(-2px);
  background: rgba(255,255,255,0.06);
}

.movie-tagline {
  font-size: 17px;
  font-style: italic;
  color: var(--accent);
  margin: -6px 0 14px;
  opacity: 0.95;
  letter-spacing: 0.02em;
}

.movie-stats-bento {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
  gap: 10px;
  margin: 16px 0;
}
.movie-stat-box {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
}
.movie-stat-box-lbl {
  font-size: 10.5px;
  font-weight: 800;
  text-transform: uppercase;
  color: var(--text-dim);
}
.movie-stat-box-val {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 22px;
  color: var(--text);
  margin-top: 2px;
}

/* Game Pills & Info Grid */
.game-badge-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin: 12px 0 16px;
}
.game-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 700;
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--text);
  white-space: nowrap;
}
.game-pill-score {
  background: rgba(245, 197, 24, 0.12);
  border-color: rgba(245, 197, 24, 0.4);
  color: var(--accent);
}
.game-pill-meta {
  background: rgba(102, 204, 51, 0.16);
  border-color: rgba(102, 204, 51, 0.45);
  color: #66cc33;
}

.game-info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin: 14px 0 20px;
}
.game-info-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.game-info-lbl {
  font-size: 11px;
  font-weight: 800;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}
.game-info-val {
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text);
  line-height: 1.4;
}

/* Lightbox & Screenshots */
.game-screenshots-wrap {
  margin-top: 32px;
  text-align: center;
}
.game-screenshots-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  justify-content: center;
  margin-top: 14px;
}
.lightbox-wrap {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}
.lightbox-img-large {
  max-width: 100%;
  max-height: 70vh;
  border-radius: 8px;
  object-fit: contain;
  box-shadow: 0 10px 30px rgba(0,0,0,0.8);
}
.lightbox-nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  margin-top: 12px;
}
.lightbox-nav-btn {
  background: var(--bg-card);
  border: 1px solid var(--line);
  color: var(--text);
  font-size: 18px;
  font-weight: bold;
  padding: 8px 18px;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
}
.lightbox-nav-btn:hover {
  background: var(--accent);
  color: #000;
  border-color: var(--accent);
}

@media (max-width: 768px) {
  .detail-hero-backdrop {
    height: 420px;
  }
  .detail-hero-backdrop::after {
    background: 
      linear-gradient(180deg, rgba(15, 17, 21, 0.4) 0%, rgba(15, 17, 21, 0.85) 60%, var(--bg) 100%);
  }
}