/* 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;
}

* {
  box-sizing: border-box;
}

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

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

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

[hidden] {
  display: none !important;
}

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

main {
  display: flex;
  flex: 1;
  flex-direction: column;
  margin: 64px 0;
}

.star {
  width: 24px;
}

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);
}

.movie-section-title {
  font-size: clamp(20px, 4vw, 36px);
  font-weight: 600;
  margin-bottom: clamp(16px, 2vw, 32px);
  text-align: center;
}

@media (min-width: 800px) {
  .movie-section-title {
    text-align: left;
  }
}

#app {
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

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

@media (min-width: 800px) {
  .container {
    padding: 0 16px;
  }
}

@media (min-width: 1120px) {
  .container {
    padding: 0 80px;
  }
}

h1.logo {
  font-size: 2rem;
}

.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;
}

footer.footer {
  height: 160px;
  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;
}

.site-header {
  position: relative;
  z-index: 1;
  background-color: var(--color-bluegray-100);
}

.site-header--overlay {
  background-color: transparent;
}

.site-header-inner {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 12px;
  max-width: 1280px;
  height: 90px;
  margin: 0 auto;
  padding: 14px 45px 8px;
}

.logo {
}

@media (min-width: 800px) {
  .site-header-inner {
    padding: 14px 16px 8px;
  }
}

@media (min-width: 1120px) {
  .site-header-inner {
    flex-direction: row;
    gap: 0;
    padding: 20px 80px;
  }

  .logo {
    position: absolute;
    top: 50%;
    left: 80px;
    transform: translateY(-50%);
  }
}

#search-form {
  display: flex;
  justify-content: center;

  width: 100%;
}

#search-input-container {
  position: relative;
  align-items: center;

  display: flex;

  width: min(525px, 100%);
  height: 36px;

  padding: 0 16px;

  border-radius: 32px;
  border: 2px solid #d1d5db;

  background-color: transparent;
  color: #fff;
}

#search-button {
  position: absolute;
  right: 16px;

  display: flex;
  justify-content: center;

  width: 16px;
  height: 16px;
  padding: 0;

  align-items: center;

  background: transparent;
}

#search-button img {
  display: block;

  width: 16px;
  height: 16px;
}

#search-input {
  width: 100%;
  height: 100%;

  padding-right: 28px;

  border: 0;
  background-color: transparent;
  color: #fff;

  outline: none;
  text-decoration: none;
}

#search-input::placeholder {
  color: #fff;
}

.hero-section {
  position: relative;
  margin-top: -90px;
}

.hero-backdrop {
  position: relative;

  width: 100%;

  background-color: var(--color-bluegray-100);
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;

  overflow: hidden;
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    90deg,
    rgba(10, 18, 34, 0.88) 0%,
    rgba(10, 18, 34, 0.7) 42%,
    rgba(10, 18, 34, 0.35) 100%
  );
}

.hero-shell {
  position: relative;

  display: flex;
  flex-direction: column;

  max-width: 1280px;
  min-height: 300px;
  margin: 0 auto;
  padding: 90px 45px 20px;
}

.hero-content {
  display: flex;
  justify-content: center;
  flex-direction: column;
  flex: 1;

  width: min(600px, 100%);
}

.hero-rate {
  display: flex;
  align-items: center;
  color: var(--color-yellow);
  font-size: 1.5rem;
  font-weight: bold;
}

.hero-title {
  font-size: clamp(1.8rem, 5vw, 3rem);
  font-weight: bold;
  line-height: 1.2;
  margin: 10px 0;
}

@media (min-width: 800px) {
  .hero-shell {
    min-height: 500px;
    padding: 90px 54px 20px;
  }
}

.hero-detail-button {
  width: 100px;
}

#see-more-btn {
  width: 100%;

  margin-top: 40px;

  color: #fff;

  font-size: 20px;
  font-weight: 600;

  border: none;
  border-radius: 8px;
  background-color: var(--color-lightblue-90);
}

.no-result {
  display: flex;
  justify-content: center;
}

.no-result-content {
  display: flex;
  flex-direction: column;
  gap: 16px;
  align-items: center;
  text-align: center;
}

.no-result-image {
  width: 72px;
}

.no-result-text {
  font-size: 36px;
  font-weight: 600;
}

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: flex-end;
  z-index: 10;
  visibility: hidden;
  opacity: 0;
  transition:
    opacity 0.3s ease,
    visibility 0.3s ease;
}

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

.modal {
  background-color: var(--color-bluegray-90);
  padding: 40px 24px 20px;
  border-radius: 16px 16px 0 0;
  color: white;
  z-index: 2;
  position: relative;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
}

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

.modal-container {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.modal-image {
  display: none;
}

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

.modal-description {
  width: 100%;
  padding: 8px;
  line-height: 1.6rem;
  text-align: center;
}

.modal-description .rate {
  justify-content: center;
}

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

.rate-label {
  color: var(--color-white);
  margin-right: 16px;
}

.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;
}

.my-rating-title {
  font-weight: bold;
}

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

.my-rating-stars {
  display: flex;
  gap: 2px;
}

.star-rating-star {
  width: 32px;
  height: 32px;
  cursor: pointer;
}

.my-rating-label {
  color: var(--color-bluegray-10);
  font-size: 0.9rem;
}

@media (min-width: 800px) {
  .modal-image {
    display: block;
  }

  .modal-description .my-rating,
  .modal-description .detail {
    text-align: left;
  }

  .my-rating-row {
    flex-direction: row;
    align-items: center;
    gap: 12px;
  }
}

@media (min-width: 1120px) {
  .modal-background {
    align-items: center;
  }

  .modal {
    width: 960px;
    padding: 20px;
    border-radius: 16px;
    max-height: none;
    overflow-y: visible;
  }

  .modal-container {
    flex-direction: row;
    align-items: flex-start;
  }

  .modal-image img {
    width: 500px;
  }

  .modal-description {
    text-align: left;
    margin-left: 16px;
  }

  .modal-description .rate {
    justify-content: flex-start;
  }
}

.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;
}

:root {
  --thumbnail-rate-height: 16px;
  --thumbnail-title-height: 20px;
  --thumbnail-desc-gap: 4px;
}

.thumbnail-grid {
  display: grid;
  grid-template-columns: repeat(1, 200px);
  justify-content: center;
  gap: 32px;
}

@media (min-width: 800px) {
  .thumbnail-grid {
    grid-template-columns: repeat(3, 200px);
    gap: 70px;
  }
}

@media (min-width: 1120px) {
  .thumbnail-grid {
    grid-template-columns: repeat(4, 200px);
    gap: 53px;
  }
}

.thumbnail-list,
.skeleton-card {
  display: contents;
}

.thumbnail {
  width: 200px;
  height: 300px;
  border-radius: 8px;
}

.skeleton {
  background: linear-gradient(
    90deg,
    var(--color-bluegray-80) 0%,
    var(--color-bluegray-30) 50%,
    var(--color-bluegray-80) 100%
  );
  background-size: 200% 100%;
  animation: skeleton-loading 1.2s ease-in-out infinite;
}

.thumbnail-skeleton {
  display: block;
}

.item {
  display: flex;
  flex-direction: column;
  user-select: none;
  cursor: pointer;
}

.item-desc {
  display: flex;
  flex-direction: column;
  gap: var(--thumbnail-desc-gap);
  min-height: calc(
    var(--thumbnail-rate-height) + var(--thumbnail-title-height) +
      var(--thumbnail-desc-gap)
  );
  padding-top: 4px;
}

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

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

.item-desc > strong {
  display: block;
  min-height: var(--thumbnail-title-height);
  line-height: var(--thumbnail-title-height);
}

.rate-skeleton {
  display: flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  color: transparent;
}

.rate-icon-skeleton {
  display: block;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  flex-shrink: 0;
}

.rate-value-skeleton {
  display: block;
  width: 48px;
  height: var(--thumbnail-rate-height);
  border-radius: 999px;
}

.title-skeleton {
  width: 85%;
  height: var(--thumbnail-title-height);
  border-radius: 6px;
}

.item .star {
  width: 16px;
  top: 1px;
}

@keyframes skeleton-loading {
  0% {
    background-position: 200% 0;
  }

  100% {
    background-position: -200% 0;
  }
}
