/* =========================================
   PUBLIC · TRAILERS · INDEX PAGE
   Featured row + grid
========================================= */

.trailers-index-page {
  max-width: 1120px;
  margin: 0 auto;
  padding: 1.75rem 1rem 2.75rem;
  color: #e5e7eb;
}

/* ---------- Header ---------- */

.trailers-index-header {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 1.75rem;
}

.trailers-index-title {
  font-size: 1.3rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: #f9fafb;
}

.trailers-index-subtitle {
  font-size: 0.9rem;
  color: #9ca3af;
}

/* Filters */

.trailers-index-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.trailers-filter-pill {
  border-radius: 999px;
  border: 1px solid #1f2937;
  background-color: #020617;
  color: #9ca3af;
  font-size: 0.75rem;
  padding: 0.3rem 0.75rem;
  cursor: default;
}

.trailers-filter-pill--active {
  border-color: #f5b200;
  background: radial-gradient(circle at top left, #f5b200, #f97316);
  color: #020617;
  font-weight: 600;
}

/* ---------- Section headers ---------- */

.trailers-section-header {
  margin-bottom: 0.75rem;
}

.trailers-section-title {
  font-size: 1rem;
  font-weight: 600;
  color: #f3f4f6;
}

.trailers-section-subtitle {
  font-size: 0.85rem;
  color: #9ca3af;
}

/* ---------- Featured trailers ---------- */

.trailers-featured-section {
  margin-bottom: 2rem;
}

.trailers-featured-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

/* On larger screens show up to 3 featured items in a row */
@media (min-width: 768px) {
  .trailers-featured-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* ---------- Cards (shared) ---------- */

.trailer-card {
  border-radius: 1rem;
  overflow: hidden;
  background-color: #020617;
  border: 1px solid #111827;
}

/* Clickable wrapper */

.trailer-card-link {
  display: flex;
  flex-direction: column;
  height: 100%;
  text-decoration: none;
  color: inherit;
}

/* Media (thumbnail area) */

.trailer-card-media {
  position: relative;
  border-radius: 1rem;
  overflow: hidden;
}

.trailer-card-thumb {
  width: 100%;
  padding-top: 56.25%; /* 16:9 */
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  background-color: #020617;
}

.trailer-card-thumb--fallback {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.9rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: #6b7280;
  background-image: radial-gradient(circle at top, #0f172a, #020617);
}

/* Featured overlay */

.trailer-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to top,
    rgba(3, 7, 18, 0.95),
    rgba(3, 7, 18, 0.3)
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 0.9rem;
}

.trailer-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
  margin-bottom: 0.35rem;
}

/* Body for non-overlay cards */

.trailer-card-body {
  padding: 0.8rem 0.8rem 0.9rem;
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.trailer-card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem;
}

/* Badges */

.trailer-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.18rem 0.6rem;
  border-radius: 999px;
  font-size: 0.72rem;
  border: 1px solid transparent;
  white-space: nowrap;
}

.trailer-badge--accent {
  background: radial-gradient(circle at top left, #f5b200, #f97316);
  color: #020617;
  font-weight: 600;
}

.trailer-badge--soft {
  background-color: #020617;
  border-color: #374151;
  color: #e5e7eb;
}

.trailer-badge--outline {
  background-color: transparent;
  border-color: #374151;
  color: #9ca3af;
}

/* Titles & text */

.trailer-card-title {
  font-size: 0.95rem;
  line-height: 1.4;
  font-weight: 600;
  color: #f9fafb;
  margin: 0;
}

.trailer-card-desc {
  font-size: 0.8rem;
  line-height: 1.5;
  color: #9ca3af;
}

.trailer-card-meta {
  font-size: 0.75rem;
  color: #6b7280;
}

/* Hover states */

.trailer-card-link:hover .trailer-card-title {
  color: #f5b200;
}

.trailer-card-link:hover .trailer-card-thumb {
  transform: scale(1.01);
  transition: transform 0.15s ease-out;
}

/* Variants */

.trailer-card--featured {
  background-color: transparent;
  border: none;
}

.trailer-card--compact {
  background-color: #020617;
  border-color: #111827;
}

/* ---------- Grid of all trailers ---------- */

.trailers-grid-section {
  margin-top: 0.5rem;
}

.trailers-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

/* 2 columns on small/medium screens */
@media (min-width: 640px) {
  .trailers-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* 4 columns on large screens */
@media (min-width: 1024px) {
  .trailers-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* ---------- Empty state ---------- */

.trailers-empty {
  padding: 1.5rem 1rem;
  border-radius: 0.9rem;
  border: 1px dashed #374151;
  background-color: rgba(15, 23, 42, 0.7);
  color: #9ca3af;
  font-size: 0.9rem;
  margin-top: 0.5rem;
}

/* ---------- Responsive tweaks ---------- */

@media (min-width: 640px) {
  .trailers-index-page {
    padding-inline: 1.5rem;
  }

  .trailers-index-title {
    font-size: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .trailers-index-page {
    padding-top: 2.2rem;
    padding-bottom: 3rem;
  }

  .trailers-index-header {
    flex-direction: row;
    align-items: flex-end;
    justify-content: space-between;
  }
}
