/* http://meyerweb.com/eric/tools/css/reset/
   v2.0 | 20110126
   License: none (public domain)
*/

html,
body,
div,
span,
applet,
object,
iframe,
h1,
h2,
h3,
h4,
h5,
h6,
p,
blockquote,
pre,
a,
abbr,
acronym,
address,
big,
cite,
code,
del,
dfn,
em,
img,
ins,
kbd,
q,
s,
samp,
small,
strike,
strong,
sub,
sup,
tt,
var,
b,
u,
i,
center,
dl,
dt,
dd,
ol,
ul,
li,
fieldset,
form,
label,
legend,
table,
caption,
tbody,
tfoot,
thead,
tr,
th,
td,
article,
aside,
canvas,
details,
embed,
figure,
figcaption,
footer,
header,
hgroup,
menu,
nav,
output,
ruby,
section,
summary,
time,
mark,
audio,
video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
}
/* HTML5 display-role reset for older browsers */
article,
aside,
details,
figcaption,
figure,
footer,
header,
hgroup,
menu,
nav,
section {
  display: block;
}
body {
  line-height: 1;
}
ol,
ul {
  list-style: none;
}
blockquote,
q {
  quotes: none;
}
blockquote:before,
blockquote:after,
q:before,
q:after {
  content: "";
  content: none;
}
table {
  border-collapse: collapse;
  border-spacing: 0;
}
:root {
  --color-white: #ffffff;
  --color-lightblue-90: #0da9fd;
  --color-bluegray-100: #242a32;
  --color-bluegray-80: #39414d;
  --color-bluegray-10: #e0e6ed;
  --color-bluegray-30: #a6b1c3;
  --color-bluegray-90: #2f3844;
  --color-gray-300: #d1d3d4;
  --color-yellow: #ffc700;
  --color-ffffff: #ffffff;
  --color-242a32: #242a32;
  --color-lightblue-90: #4a90e2;
}

* {
  box-sizing: border-box;
}

a {
  color: inherit;
  text-decoration: none;
}

body {
  font-size: 16px;
  color: var(--color-white);
  background-color: var(--color-bluegray-100);
}

#wrap,
section {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

main {
  margin: 64px 0;
  min-height: 65vh;
}

.main-title {
  font-family: Poppins;
  font-weight: 600;
  font-size: 36px;
  line-height: 100%;
  letter-spacing: 0%;
  margin-bottom: 50px;
}

@media screen and (max-width: 1310px) {
  .main-title {
    font-size: 36px;
  }
}

.star {
  width: 16px;
}

button {
  border: 0;
  padding: 8px 16px;
  cursor: pointer;
}

button.primary {
  color: var(--color-white);
  font-weight: bold;
  background-color: var(--color-lightblue-90);
  border-radius: 4px;
}

#wrap {
  background-color: var(--color-bluegray-100);
}

#wrap h2 {
  font-size: 1.4rem;
  font-weight: bold;
  margin-bottom: 32px;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  padding: 0 24px;
}

.search-container {
  display: flex;
  justify-content: center;
  margin-top: 48px;
}

.search-form {
  display: flex;
  align-items: center;
  width: 525px;
  height: 36px;
  border-radius: 32px;
  border: 2px solid var(--color-white);
  padding: 6px 16px;
  background: transparent;
  justify-content: space-between;
  opacity: 1;
}

@media screen and (max-width: 768px) {
  .search-container {
    margin-top: 90px;
    justify-content: center;
    display: flex;
    align-items: center;
    padding: 0 24px;
  }

  .search-form {
    width: 100%;
    max-width: 360px;
    margin-top: 0;
  }

  .main-title {
    font-size: 36px;
    margin-bottom: 56px;
    text-align: center;
    padding: 0;
  }
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  background: transparent;
  font-family: "DM Sans", sans-serif;
  font-weight: 400;
  font-size: 16px;
  line-height: 24px;
  letter-spacing: 0;
  color: var(--color-white);
}

@media screen and (min-width: 769px) and (max-width: 1080px) {
  .search-form {
    width: 325px;
    top: 36px;
  }
}

.img-search {
  width: 16px;
  height: 16px;
  background: transparent;
  opacity: 1;
}

.search-input::placeholder {
  color: var(--color-white);
}

.btn-submit {
  background: transparent;
  border: none;
  cursor: pointer;
  padding-right: 4px;
}

.background-container {
  position: relative;
  background-position: center center;
  background-size: cover;
  height: 500px;
  padding-left: 84px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
}

@media screen and (max-width: 1024px) {
  .background-container {
    padding-left: 48px;
    height: 420px;
  }
}

@media screen and (max-width: 768px) {
  .background-container {
    padding: 80px 24px 32px;
    height: auto;
    min-height: 320px;
    justify-content: flex-end;
  }
}

.overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 999;
}

.top-rated-container {
  user-select: none;
  position: relative;
  z-index: 2;
  max-width: 1280px;
  margin: 0 auto;
  width: 100%;
  padding: 0 24px;
}

.top-rated-movie > *:not(:last-child) {
  margin-bottom: 8px;
}

h1.logo {
  font-size: 2rem;
  position: absolute;
  top: 48px;
  left: 84px;
  cursor: pointer;
}

@media screen and (max-width: 1080px) {
  h1.logo {
    left: 24px;
    top: 48px;
    font-size: 1.5rem;
  }
}

@media screen and (max-width: 768px) {
  h1.logo {
    left: 24px;
    top: 20px;
    font-size: 1.5rem;
  }
}

.rate {
  display: flex;
  align-items: baseline;
  color: var(--color-yellow);
}

.rate > img {
  position: relative;
  top: 2px;
}

span.rate-value {
  margin-left: 8px;
  font-weight: bold;
  font-size: 1.66rem;
}

.title {
  font-size: 3rem;
  font-weight: bold;
}

@media screen and (max-width: 1024px) {
  .title {
    font-size: 2.2rem;
  }
}

@media screen and (max-width: 768px) {
  .title {
    font-size: 1.6rem;
  }
}

footer.footer {
  min-height: 180px;
  background-color: var(--color-bluegray-80);
  display: flex;
  flex-direction: column;
  justify-content: center;
  text-align: center;
  font-size: 1.1rem;
}

footer.footer p:not(:last-child) {
  margin-bottom: 8px;
}

.btn-more {
  background-color: #0da9fd;
  max-width: 1280px;
  height: 49px;
  gap: 10px;
  opacity: 1;
  border-radius: 8px;
  padding: 10px;
  color: #ffffff;
  font-size: 24px;
  font-family: Montserrat;
  font-weight: 600;
  font-style: SemiBold;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0.24px;
  text-align: center;
}
:root {
  --color-white: #ffffff;
  --color-lightblue-90: #0da9fd;
  --color-bluegray-100: #242a32;
  --color-bluegray-80: #39414d;
  --color-bluegray-10: #e0e6ed;
  --color-bluegray-30: #a6b1c3;
  --color-bluegray-90: #2f3844;
  --color-gray-300: #d1d3d4;
  --color-yellow: #ffc700;
  --color-ffffff: #ffffff;
  --color-242a32: #242a32;
  --color-lightblue-90: #4a90e2;
}

.tab {
  display: flex;
  margin: 32px 0;
}

.tab-item {
  cursor: pointer;
  user-select: none;

  display: flex;
  align-items: center;
  justify-content: center;
  width: 120px;
  height: 40px;

  border-radius: 40px;
  background: linear-gradient(90deg, #14191f 0%, #0a0d12 100%);
}

.tab-item.selected {
  background: linear-gradient(90deg, #4b8bf4 0%, #1c2a3a 100%);
}

.tab-item:hover {
  background: linear-gradient(90deg, #2f3e54 0%, #4b8bf4 100%);
}

.tab li:not(:last-child) {
  margin-right: 8px;
}

.result-none {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  height: 200px;
  font-size: 18px;
  gap: 25px;
}

.result-none-text {
  font-family: "Poppins";
  font-weight: 600;
  font-size: 36px;
  line-height: 100%;
  letter-spacing: 0%;
}
:root {
  --color-white: #ffffff;
  --color-lightblue-90: #0da9fd;
  --color-bluegray-100: #242a32;
  --color-bluegray-80: #39414d;
  --color-bluegray-10: #e0e6ed;
  --color-bluegray-30: #a6b1c3;
  --color-bluegray-90: #2f3844;
  --color-gray-300: #d1d3d4;
  --color-yellow: #ffc700;
  --color-ffffff: #ffffff;
  --color-242a32: #242a32;
  --color-lightblue-90: #4a90e2;
}

.thumbnail-list {
  margin: 0 auto 56px;
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 72px;
}

@media screen and (max-width: 1310px) {
  .thumbnail-list {
    grid-template-columns: repeat(4, 1fr);
    gap: 53px;
  }
}

@media screen and (max-width: 1050px) {
  .thumbnail-list {
    grid-template-columns: repeat(3, 1fr);
    gap: 70px;
    margin-bottom: 40px;
  }
}

@media screen and (max-width: 769px) {
  .thumbnail-list {
    grid-template-columns: repeat(2, 1fr);
    gap: 70px;
    margin-bottom: 70px;
  }
}

@media screen and (max-width: 653px) {
  .thumbnail-list {
    grid-template-columns: repeat(1, 1fr);
    gap: 70px;
  }
}

.thumbnail {
  width: 100%;
  aspect-ratio: 2 / 3;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
  display: block;
}

.item {
  user-select: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.item-desc {
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-family: "Inter", sans-serif;
  font-weight: 700;
  font-size: 20px;
  line-height: 100%;
  letter-spacing: 0%;
}

.item-desc > *:not(:last-child) {
  position: relative;
  margin-bottom: 4px;
  line-height: 1.2rem;
}

p.rate {
  display: flex;
  align-items: baseline;
  color: var(--color-yellow);
}

p.rate > span {
  margin-left: 4px;
}

.item .star {
  width: 18px;
  height: 18px;
  top: 1px;
}

/* Skeleton */

@keyframes skeleton-shimmer {
  0% {
    background-position: -400px 0;
  }
  100% {
    background-position: 400px 0;
  }
}

.movie-skeleton {
  display: flex;
  flex-direction: column;
  gap: 10px;
  width: 100%;
}

.movie-skeleton__poster,
.movie-skeleton__title,
.movie-skeleton__info {
  background: linear-gradient(
    90deg,
    var(--color-bluegray-80) 25%,
    var(--color-bluegray-90) 50%,
    var(--color-bluegray-80) 75%
  );
  background-size: 800px 100%;
  animation: skeleton-shimmer 1.4s infinite linear;
  border-radius: 4px;
}

.movie-skeleton__poster {
  width: 100%;
  aspect-ratio: 2 / 3;
  border-radius: 8px;
}

.movie-skeleton__details {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.movie-skeleton__title {
  height: 20px;
  width: 80%;
}

.movie-skeleton__info {
  height: 16px;
  width: 50%;
}
:root {
  --color-white: #ffffff;
  --color-lightblue-90: #0da9fd;
  --color-bluegray-100: #242a32;
  --color-bluegray-80: #39414d;
  --color-bluegray-10: #e0e6ed;
  --color-bluegray-30: #a6b1c3;
  --color-bluegray-90: #2f3844;
  --color-gray-300: #d1d3d4;
  --color-yellow: #ffc700;
  --color-ffffff: #ffffff;
  --color-242a32: #242a32;
  --color-lightblue-90: #4a90e2;
}

/* modal.css */

body.modal-open {
  overflow: hidden;
}

.modal-background {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5); /* 반투명 배경을 위해 설정 */
  backdrop-filter: blur(10px); /* 블러 효과 적용 */
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 1000;
  visibility: hidden; /* 모달이 기본적으로 보이지 않도록 설정 */
  opacity: 0;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

.modal-background.active {
  visibility: visible;
  opacity: 1;
}

hr {
  border: 1px solid #67788e;
  width: 100%;
}

.modal {
  background-color: var(--color-bluegray-90);
  padding: 20px;
  border-radius: 16px;
  color: white;
  z-index: 2;
  position: relative;
  width: min(1000px, calc(100vw - 32px));
  max-height: 90vh;
  overflow-y: auto;
}

.modal-container {
  width: 100%;
  opacity: 1;
  padding-top: 40px;
  padding-right: 24px;
  padding-bottom: 40px;
  padding-left: 24px;
  gap: 24px;
  border-radius: 16px;
}

.modal-title {
  font-family: DM Sans;
  font-weight: 700;
  font-style: Bold;
  font-size: 32px;
  line-height: 100%;
  letter-spacing: 0%;
}

.modal-release-date-and-genres {
  font-family: DM Sans;
  font-weight: 400;
  font-style: Regular;
  font-size: 20px;
  line-height: 100%;
  letter-spacing: 0%;
}

.modal-rating-text {
  font-size: 20px;
  margin: 0;
  margin-right: 16px;
  font-family: DM Sans;
  font-weight: 400;
  font-style: Regular;
  font-size: 20px;
  line-height: 100%;
  letter-spacing: 0%;
  padding-top: 2px;
}

.star-rating {
  display: flex;
  align-items: center;
  gap: 8px;
}

.stars-row {
  display: flex;
  align-items: center;
  gap: 4px;
}

.rating-text {
  display: flex;
  align-items: center;
  gap: 4px;
}

.modal-star {
  width: 32px;
  height: 32px;
}

.rating-label {
  font-family: Montserrat;
  font-weight: 600;
  font-style: SemiBold;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0.18px;
  margin-left: 10px;
  margin-top: 5px;
}

.rating-score {
  font-family: Montserrat;
  font-weight: 600;
  font-style: SemiBold;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0.18px;
  color: #95a1b2;
  margin-top: 5px;
}

.modal-user-rating-text {
  font-family: Montserrat;
  font-weight: 600;
  font-style: SemiBold;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0.18px;
  margin-bottom: 24px;
}

.modal-overview-title {
  font-family: Montserrat;
  font-weight: 600;
  font-style: SemiBold;
  font-size: 24px;
  line-height: 100%;
  letter-spacing: 0.18px;
}

.modal-overview {
  font-family: Montserrat;
  font-weight: 300;
  font-style: Light;
  font-style: Bold;
  font-size: 24px;
  line-height: 147%;
  letter-spacing: 0.18px;
  max-height: 218px;
  overflow-y: auto;
  overflow-x: hidden;
}

.modal-overview::-webkit-scrollbar {
  width: 6px;
}

.modal-overview::-webkit-scrollbar-track {
  background: transparent;
}

.modal-overview::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.3);
  border-radius: 3px;
}

.modal-rating {
  margin: 0;
  margin-left: 2px;
  color: #ffc700;
  font-family: Montserrat;
  font-weight: 600;
  font-size: 24px;
  line-height: 1;
  letter-spacing: 0.18px;
  padding-top: 1.5px;
  font-style: SemiBold;
  line-height: 100%;
}

.average-star {
  width: 24px;
  height: 24px;
  margin-right: 2.5px;
}

.close-modal {
  position: absolute;
  margin: 0;
  padding: 0;
  top: 24px;
  right: 24px;
  background: none;
  border: none;
  color: white;
  font-size: 20px;
  cursor: pointer;
  width: 25px;
  height: 25px;
}

.modal-container {
  display: flex;
}

.modal-image img {
  width: 380px;
  border-radius: 16px;
}

.modal-image {
  width: 400px;
  height: 600px;
  flex-shrink: 0;
  opacity: 1;
  border-radius: 16px;
}

.average {
  display: flex;
  align-items: center;
  line-height: 1;
}

.modal-description {
  display: flex;
  flex-direction: column;
  width: 100%;
  padding: 8px;
  margin-left: 16px;
  line-height: 1.6rem;
  gap: 16px;
}

.modal-description .rate > img {
  position: relative;
  top: 5px;
}

.modal-description > *:not(:last-child) {
  margin-bottom: 8px;
}

.modal-description h2 {
  font-size: 2rem;
  margin: 0 0 8px;
}

.detail {
  max-height: 430px;
  overflow-y: auto;
}

/* 태블릿 */

@media screen and (min-width: 390px) and (max-width: 1024px) {
  .modal-background {
    align-items: flex-end;
  }

  .modal {
    width: 100vw;
    max-height: 140vh;
    border-radius: 16px 16px 0 0;
    padding: 16px 24px;
    overflow-y: hidden;
  }

  .modal-container {
    flex-direction: column;
    align-items: center;
    padding: 12px 0;
    gap: 20px;
  }

  /* 포스터: 중앙 정렬, 작게 */
  .modal-image {
    width: 150px;
    height: auto;
    flex-shrink: 0;
  }

  .modal-image img {
    width: 110px;
    height: auto;
    border-radius: 8px;
    object-fit: cover;
  }

  /* 설명 영역 전체 */
  .modal-description {
    width: 100%;
    margin-left: 0;
    padding: 0;
    gap: 6px;
    align-items: center;
  }

  /* 제목/장르/평균 별점: 중앙 */
  .modal-title {
    font-size: 28px;
    text-align: center;
  }

  .modal-release-date-and-genres {
    font-size: 16px;
    text-align: center;
  }

  .average {
    justify-content: center;
  }

  .modal-rating {
    font-size: 16px;
  }

  .average-star {
    width: 14px;
    height: 14px;
  }

  /* 내 별점 + 줄거리: 왼쪽 정렬 */
  .modal-user-rating {
    width: 100%;
    text-align: left;
  }

  .modal-user-rating-text {
    font-size: 20px;
    margin-bottom: 10px;
    margin-left: 2px;
  }

  .modal-rating-text {
    font-size: 16px;
  }

  .rating-label,
  .rating-score {
    font-size: 20px;
    margin-bottom: 2px;
  }

  .modal-star {
    width: 20px;
    height: 20px;
  }

  .modal-overview-title {
    width: 100%;
    font-size: 20px;
    text-align: left;
  }

  .modal-overview {
    width: 100%;
    font-size: 20px;
    max-height: 80px;
    overflow-y: auto;
    text-align: left;
  }
}

/* 모바일 */

@media screen and (max-width: 390px) {
  .modal-background {
    align-items: flex-end;
  }

  .modal {
    width: 100vw;
    border-radius: 16px 16px 0 0;
    padding: 24px;
    overflow-y: hidden;
  }

  .modal-container {
    flex-direction: column;
    align-items: center;
    padding: 12px 0;
    gap: 12px;
  }

  /* 이미지 숨김 */
  .modal-image {
    display: none;
  }

  .modal-description {
    width: 100%;
    margin-left: 0;
    padding: 0;
    gap: 10px;
    align-items: center;
  }

  .modal-title {
    font-size: 20px;
    text-align: center;
    padding: 0 36px;
  }

  .modal-release-date-and-genres {
    font-size: 16px;
    text-align: center;
  }

  .average {
    justify-content: center;
  }

  /* 내 별점: 중앙 정렬 */
  .modal-user-rating {
    width: 100%;
    align-items: center;
    text-align: center;
    flex-direction: column;
  }

  .modal-user-rating-text {
    font-size: 18px;
    margin-bottom: 8px;
  }

  .star-rating {
    flex-direction: column;
    align-items: center;
    gap: 8px;
  }

  .modal-star {
    width: 28px;
    height: 28px;
  }

  .rating-label,
  .rating-score {
    font-size: 18px;
  }

  .modal-rating {
    font-size: 20px;
  }

  .modal-rating-text {
    font-size: 16px;
  }

  .average-star {
    width: 16px;
    height: 16px;
  }

  /* 줄거리 제목: 중앙, 본문: 왼쪽 */
  .modal-overview-title {
    width: 100%;
    font-size: 18px;
    text-align: center;
  }

  .modal-overview {
    width: 100%;
    font-size: 18px;
    max-height: none;
    text-align: left;
  }
}
