/* ===== RESET & BODY ===== */
body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #111;
  color: #fff;
}

/* ===== HEADER ===== */
.main-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: #1a1a1a;
  padding: 15px 30px;
  position: sticky;
  top: 0;
  z-index: 999;
  box-shadow: 0 2px 4px rgba(0,0,0,0.5);
}

.logo {
  font-size: 24px;
  font-weight: bold;
  color: #ffcc00;
}

.nav-menu a {
  margin: 0 15px;
  color: #fff;
  text-decoration: none;
  font-weight: 500;
}

.nav-menu a:hover {
  color: #ffcc00;
}

/* ===== TÌM KIẾM ===== */
.search-box {
  position: relative;
  display: flex;
  align-items: center;
}

.search-box input {
  padding: 8px 35px 8px 12px;
  border-radius: 5px;
  border: none;
  outline: none;
  background: #333;
  color: white;
  width: 200px;
}

.search-icon {
  position: absolute;
  right: 10px;
  font-size: 16px;
  color: #aaa;
  pointer-events: none;
}

/* Responsive header */
@media screen and (max-width: 768px) {
  .main-header {
    flex-wrap: wrap;
    gap: 10px;
  }

  .search-box {
    width: 100%;
  }

  .search-box input {
    width: 100%;
  }
}

/* ===== PHIM ĐỀ CỬ ===== */
.featured-section {
  padding: 20px 30px;
}

.featured-section h2 {
  font-size: 22px;
  margin-bottom: 10px;
  color: #ffcc00;
}

.featured-carousel {
  display: flex;
  overflow-x: auto;
  scroll-behavior: smooth;
  gap: 15px;
  padding-bottom: 10px;
  scrollbar-width: thin;
  scrollbar-color: #444 transparent;
}

.featured-carousel::-webkit-scrollbar {
  height: 8px;
}

.featured-carousel::-webkit-scrollbar-thumb {
  background: #444;
  border-radius: 10px;
}

.featured-card {
  flex: 0 0 auto;
  width: 160px;
  background-color: #1e1e1e;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: transform 0.2s;
}

.featured-card:hover {
  transform: scale(1.05);
}

.featured-card img {
  width: 100%;
  height: 230px;
  object-fit: cover;
}

.featured-card h4 {
  text-align: center;
  font-size: 14px;
  padding: 5px;
  color: #fff;
}

/* ===== DANH SÁCH PHIM CHÍNH ===== */
.movie-section {
  padding: 20px 30px;
}

.movie-section h2 {
  font-size: 22px;
  margin-bottom: 10px;
  color: #ffcc00;
}

#movieList {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 10px 0;
}

/* Thẻ phim */
.movie-card {
  width: 200px;
  background-color: #1e1e1e;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
}

.movie-card:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 16px rgba(255, 255, 255, 0.1);
}

.movie-card img {
  width: 100%;
  height: 270px;
  object-fit: cover;
  border-bottom: 1px solid #333;
  display: block;
}

.movie-card h3 {
  text-align: center;
  padding: 10px;
  font-size: 16px;
  color: #f5f5f5;
}

/* Container chính căn giữa, chiều cao full */
.detail-container {
  max-width: 900px;
  margin: 40px auto;   /* tự động căn giữa ngang */
  padding: 30px;
  background-color: #121212;
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0,0,0,0.6);

  display: flex;
  gap: 40px;
  align-items: center; /* căn giữa theo chiều dọc */
  justify-content: center; /* căn giữa ngang cho flex items */
  flex-wrap: wrap;
}

/* Ảnh phim to hơn */
.detail-thumbnail {
  width: 400px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.5);
  object-fit: cover;
}

/* Thông tin phim */
.detail-info {
  flex: 1;
  min-width: 300px; /* không bị quá nhỏ */
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #f5f5f5;
}

/* Tiêu đề phim to */
.detail-info h2 {
  font-size: 36px;
  margin: 0 0 20px;
  color: #ffcc00;
}

/* Mô tả phim rõ ràng */
.detail-info p {
  font-size: 18px;
  line-height: 1.6;
  margin-bottom: 30px;
  color: #ddd;
}

/* Nút xem phim lớn, nổi bật */
.watch-button {
  display: inline-block;
  padding: 16px 36px;
  background-color: #ffcc00;
  color: #111;
  font-weight: 700;
  font-size: 18px;
  border-radius: 10px;
  text-decoration: none;
  transition: background-color 0.3s ease;
  width: fit-content;
  user-select: none;
}

.watch-button:hover {
  background-color: #ffdb4d;
  color: #000;
}

/* Responsive cho màn hình nhỏ */
@media screen and (max-width: 768px) {
  .detail-container {
    flex-direction: column;
    margin: 20px;
  }
  
  .detail-thumbnail {
    width: 100%;
    max-width: 400px;
  }
  
  .detail-info {
    text-align: center;
  }
  
  .watch-button {
    width: 100%;
  }
}
#movieList {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 16px;
}
.movie-card {
  width: 200px;
  background-color: #1e1e1e;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3);
  transition: transform 0.2s;
}

.movie-card:hover {
  transform: scale(1.05);
}

/* 🎯 Làm thẻ đầu rộng hơn */
.highlight-card {
  width: 420px; /* Gấp đôi bình thường */
  border: 2px solid #ffcc00;
  box-shadow: 0 0 10px rgba(255, 204, 0, 0.5);
}
.back-button {
  display: inline-block;
  padding: 10px 20px;
  background-color: #ffcc00;
  color: #111;
  font-weight: bold;
  border-radius: 8px;
  text-decoration: none;
  transition: background-color 0.3s, transform 0.2s;
  margin-top: 10px;
}

.back-button:hover {
  background-color: #e6b800;
  transform: translateY(-2px);
}