/* ===== RESET & BASE ===== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #121212;
  font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
  color: #fff;
  line-height: 1.5;
}

/* ===== HEADER ===== */
header {
  background-color: #1f1f1f;
  padding: 10px 0;
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid #333;
}

nav {
  max-width: 1000px;
  margin: auto;
  display: flex;
  justify-content: space-around;
  flex-wrap: wrap;
}

nav a {
  color: #fff;
  text-decoration: none;
  font-weight: bold;
  padding: 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  transition: background 0.3s;
}

nav a:hover,
nav a.active {
  background: #e50914;
  border-radius: 4px;
}

/* ===== CONTAINER ===== */
.container {
  max-width: 1000px;
  margin: auto;
  padding: 30px 20px;
}

/* ===== H1 with Icon ===== */
.container h1 {
  font-size: 2rem;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.container h1 img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

/* ===== FORM ===== */
form {
  display: flex;
  margin-bottom: 30px;
}

form input {
  flex: 1;
  padding: 12px;
  font-size: 16px;
  border: none;
  border-radius: 6px 0 0 6px;
  background: #1e1e1e;
  color: white;
}

form button {
  background: #e50914;
  border: none;
  padding: 0 20px;
  border-radius: 0 6px 6px 0;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
}

form button img {
  width: 20px;
  height: 20px;
  object-fit: contain;
}

/* ===== MOVIES LIST ===== */
.movies {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: center;
}

.movie {
  position: relative;
  width: 200px;
  background: #1e1e1e;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.2s;
}

.movie:hover {
  transform: scale(1.05);
}

.movie img {
  width: 100%;
  display: block;
}

/* ===== OVERLAY ON HOVER ===== */
.overlay {
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  opacity: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  transition: opacity 0.3s;
  padding: 10px;
}

.movie:hover .overlay {
  opacity: 1;
}

.overlay h3 {
  margin-bottom: 10px;
  font-size: 16px;
}

/* ===== BUTTONS ===== */
.btn {
  display: inline-block;
  padding: 8px 12px;
  margin: 4px;
  text-decoration: none;
  color: #fff;
  background: #e50914;
  border-radius: 4px;
  font-weight: bold;
  font-size: 14px;
}

/* ===== MODALS ===== */
.modal {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(0, 0, 0, 0.85);
  display: none;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

.modal-content {
  position: relative;
  width: 80%;
  height: 60%;
  background: #000;
  padding: 20px;
  overflow-y: auto;
  border-radius: 6px;
}

.modal-close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 28px;
  color: #ccc;
  cursor: pointer;
}

#details-content h2 {
  margin-top: 0;
  font-size: 24px;
}

#details-content p {
  margin: 10px 0;
  line-height: 1.5;
}
