@import url('colors.css');
@import url('fonts.css');

body {
  color: var(--primary-color);
  font-family: var(--primary-font);
  background-color: var(--primary-bg);
  padding: 0 40px;
}

.btn {
  width: 100px;
  height: 40px;
  border: none;
  background-color: var(--primary-color);
  color: var(--primary-bg);
  border-radius: 5px;
  cursor: pointer;
}

.btn:disabled {
  cursor: not-allowed;
}

.caption2 {
  color: var(--white-color);
}

.form-select {
  height: 40px;
  background-color: var(--primary-bg);
  border: none;
  margin-right: 20px;
  color: var(--secondary-color);
}

.filter-container {
  display: flex;
  gap: 10px;
}

.img-movie {
  width: 400px;
  min-height: 610px;
  max-height: 610px;
  object-fit: cover;
  border-top-right-radius: 20px;
  border-top-left-radius: 20px;
}

/* movie list */
.movie-list {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  margin-top: 20px;
}

/* movie card */
.image-container {
  width: 400px;
  min-height: 610px;
  max-height: 610px;
}

.movie-card {
  border: 1px solid white;
  width: 400px;
  height: 720px;
  border-radius: 20px;
  margin-bottom: 40px;
  cursor: pointer;
}

.info-container {
  padding: 5px 20px;
}

.loader-container {
  border: 5px solid #f3f3f3;
  border-radius: 50%;
  margin: auto;
  border-top: 5px solid var(--secondary-color);
  width: 20px;
  height: 20px;
  -webkit-animation: spin 2s linear infinite; /* Safari */
  animation: spin 2s linear infinite;
}

/* Safari */
@-webkit-keyframes spin {
  0% {
    -webkit-transform: rotate(0deg);
  }
  100% {
    -webkit-transform: rotate(360deg);
  }
}

@keyframes spin {
  0% {
    transform: rotate(0deg);
  }
  100% {
    transform: rotate(360deg);
  }
}

.img-detail-cover {
  width: 100%;
  height: 600px;
  object-fit: cover;
  filter: grayscale(100%);
  border-radius: 40px;
}

.img-detail {
  width: 300px;
}

.content-detail h2 {
  color: white;
}

.content-container {
  position: relative;
  margin-top: -160px;
  margin-left: 40px;
  display: flex;
  gap: 40px;
  align-items: flex-end;
}

.skeleton-container {
  background-color: transparent;
  border-radius: 8px;
  padding: 16px;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.skeleton-header {
  background-color: #e0e0e0;
  border-radius: 4px;
  margin-bottom: 16px;
}

.skeleton-content {
  display: flex;
}

@keyframes pulse {
  0% {
    background-color: #e0e0e0;
  }
  50% {
    background-color: #f5f5f5;
  }
  100% {
    background-color: #e0e0e0;
  }
}

.skeleton-header {
  animation: pulse 1s infinite ease-in-out;
}

.navigation-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.container-left {
  display: flex;
  align-items: center;
  gap: 40px;
}

.navigation-container > h5 {
  cursor: pointer;
  user-select: none;
}

.footer {
  text-align: center;
}

.not-found {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 98vh;
}

@media screen and (max-width: 768px) {
  body {
    padding: 0;
  }
  .movie-list {
    justify-content: center;
  }

  .image-container {
    width: 300px;
    min-height: 410px;
    max-height: 410px;
  }

  .img-movie {
    width: 300px;
    min-height: 410px;
    max-height: 410px;
    object-fit: cover;
    border-top-right-radius: 20px;
    border-top-left-radius: 20px;
  }

  .movie-card {
    border: 1px solid white;
    width: 300px;
    height: 520px;
    border-radius: 20px;
    margin-bottom: 40px;
    cursor: pointer;
  }
  .img-detail-cover {
    height: 200px;
    border-radius: 20px;
  }

  .img-detail {
    width: 120px;
  }

  .content-container {
    margin-top: 20px;
    margin-left: 0;
    align-items: flex-start;
  }
  .content-detail h1 {
    font-size: 20px !important;
  }
  .content-detail h2 {
    font-size: 16px !important;
  }
}

.switch-toggle {
  display: none;
}
.switch-label {
  display: block;
  width: 60px;
  height: 34px;
  background: var(--primary-color);
  border-radius: 34px;
  position: relative;
  cursor: pointer;
}
.switch-label::before {
  content: '';
  display: block;
  width: 26px;
  height: 26px;
  background: #fff;
  border-radius: 50%;
  position: absolute;
  top: 4px;
  left: 4px;
  transition: 0.3s;
}
.switch-toggle:checked + .switch-label {
  background: var(--secondary-color);
}
.switch-toggle:checked + .switch-label::before {
  transform: translateX(26px);
}

.body-container {
  color: var(--primary-color);
  background-color: var(--primary-bg);
}

.body-container-light {
  color: var(--primary-bg);
  background-color: var(--white-color);
}
