/* ================= RESET ================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* ================= VARIABLES ================= */
:root {
  --bg: #0f172a;
  --bg-dark: #020617;
  --card: #0b1224;
  --primary: #38bdf8;
  --text: #e5e7eb;
  --muted: #94a3b8;
}
body.light {
  --bg: #f8fafc;
  --bg-dark: #ffffff;
  --card: #e5e7eb;
  --primary: #2563eb;
  --text: #020617;
  --muted: #475569;
}

/* ================= BODY ================= */
body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
}

/* ================= NAVBAR ================= */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 18px 30px;
  background: var(--bg-dark);
  flex-wrap: wrap;
}

.logo {
  font-size: 24px;
  font-weight: 700;
  color: var(--primary);
}

nav {
  display: flex;
  gap: 22px;
}

nav a {
  text-decoration: none;
  color: var(--text);
  font-weight: 500;
}

nav a:hover {
  color: var(--primary);
}

/* ================= SEARCH ================= */
.search-box {
  display: flex;
  gap: 8px;
}

.search-box input {
  padding: 8px 12px;
  border-radius: 6px;
  border: none;
  outline: none;
}

.search-box button {
  padding: 8px 16px;
  border-radius: 6px;
  border: none;
  background: var(--primary);
  color: #020617;
  font-weight: 600;
  cursor: pointer;
}

.search-box button:hover {
  background: #0ea5e9;
}

/* ================= HERO ================= */
.hero {
  text-align: center;
  padding: 50px 20px 20px;
  background: linear-gradient(135deg, var(--bg-dark), var(--bg));
}

.hero h1 {
  font-size: 42px;
  margin-bottom: 10px;
}

.hero p {
  color: var(--muted);
  line-height: 1.4;
}

/* Divider */
.hero::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: var(--primary);
  margin: 25px auto 0;
  border-radius: 10px;
}

/* ================= POPULAR MOVIES ================= */
.movies-section {
  padding: 30px 20px 50px;
  text-align: center;
}

.movies-section h2 {
  color: var(--primary);
  font-size: 28px;
  margin-bottom: 30px;
}

/* Grid */
.movie-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 24px;
  max-width: 1200px;
  margin: 0 auto;
}

/* Posters */
.movie-grid img {
  width: 100%;
  height: 270px;
  object-fit: cover;
  border-radius: 16px;
  cursor: pointer;
  transition: transform 0.35s ease, box-shadow 0.35s ease;
}

.movie-grid img:hover {
  transform: translateY(-10px) scale(1.06);
  box-shadow: 0 25px 50px rgba(0,0,0,0.7);
}

/* ================= SEARCH RESULTS ================= */
.results {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 24px;
  padding: 30px 20px;
}

.resultCard {
  width: 200px;
  text-align: center;
  cursor: pointer;
}

.resultCard img {
  width: 100%;
  height: 300px;
  border-radius: 14px;
  object-fit: cover;
}

.resultCard h3 {
  margin-top: 10px;
  font-size: 14px;
}

/* ================= ABOUT + CONTACT ================= */
.about-contact-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 40px;
  max-width: 1200px;
  margin: 60px auto;
  padding: 0 20px;
}

.box {
  background: linear-gradient(135deg, var(--bg-dark), var(--card));
  border-radius: 22px;
  padding: 40px;
  box-shadow: 0 30px 60px rgba(0,0,0,0.7);
}

.box h2 {
  color: var(--primary);
  font-size: 28px;
  margin-bottom: 20px;
}

/* About text */
.about-box p {
  color: var(--muted);
  line-height: 1.7;
  font-size: 16px;
}

/* Contact inputs */
.contact-box input,
.contact-box textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 2px solid #334155;
  padding: 10px 5px;
  margin-bottom: 18px;
  color: var(--text);
  font-size: 15px;
  outline: none;
}

.contact-box input::placeholder,
.contact-box textarea::placeholder {
  color: #64748b;
}

.contact-box button {
  margin-top: 15px;
  padding: 12px 30px;
  border-radius: 8px;
  border: none;
  background: var(--primary);
  color: #020617;
  font-weight: 600;
  cursor: pointer;
}

.contact-box button:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px rgba(56,189,248,0.4);
}

.contact-email {
  margin-top: 25px;
  color: var(--muted);
  font-size: 14px;
}

/* ================= FOOTER ================= */
footer {
  background: var(--bg-dark);
  padding: 20px;
  text-align: center;
  color: var(--muted);
}

/* ================= RESPONSIVE ================= */
@media (max-width: 900px) {
  .about-contact-wrapper {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .navbar {
    flex-direction: column;
    gap: 16px;
  }

  nav {
    flex-direction: column;
  }

  .hero h1 {
    font-size: 30px;
  }
}
