.movie-wrapper {
  max-width: 1100px;
  margin: 40px auto;
  padding: 0 24px;
}

.movie-notice {
  border: 1px solid #005BFF;
  background: #f4f6ff;
  padding: 12px;
  font-size: 13px;
  margin-bottom: 20px;
}

.movie-toolbar {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.movie-toolbar button {
  background: #005BFF;
  color: #fff;
  border: none;
  font-size: 13px;
  padding: 6px 14px;
  cursor: pointer;
}

.movie-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.movie-card {
  aspect-ratio: 2 / 3;
  background: #eee;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
}

.movie-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* 오버레이 */
.movie-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  display: flex;
  justify-content: center;
  align-items: flex-end;
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}

.movie-overlay:not(.hidden) {
  opacity: 1;
  pointer-events: auto;
}

.overlay-paper {
  width: min(420px, 90vw);
  background: #fff;
  border-radius: 16px 16px 0 0;
  padding: 14px;
  transform: translateY(30px);
  transition: transform .25s ease;
}

.movie-overlay:not(.hidden) .overlay-paper {
  transform: translateY(0);
}

.overlay-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 6px;
}

.delete-btn {
  margin-bottom: 8px;
  background: none;
  border: 1px solid #005BFF;
  color: #005BFF;
  font-size: 12px;
  padding: 4px 10px;
  cursor: pointer;
}

.delete-btn:hover {
  background: #005BFF;
  color: #fff;
}

.overlay-actions {
  position: absolute;
  top: 12px;
  right: 12px;
  display: flex;
  gap: 6px;
}

.movie-overlay img {
  width: 100%;
  height: auto;
  max-height: 80vh;
  object-fit: contain;
  display: block;
}

.movie-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 999;
}

.overlay-panel {
  background: #fff;
  width: min(420px, 92vw);
  max-height: 92vh;
  border-radius: 16px;
  padding: 14px;
  overflow-y: auto;

  animation: overlayPop .28s ease;
}

@keyframes overlayPop {
  from {
    transform: translateY(14px) scale(.97);
    opacity: 0;
  }
  to {
    transform: translateY(0) scale(1);
    opacity: 1;
  }
}


/* 카드 자체는 이미 있을 텐데, 없다면 이렇게 */
.movie-card {
  position: relative;
  overflow: hidden;
}

/* 별점 배지 */
.movie-rating-badge {
  position: absolute;
  left: 8px;
  bottom: 8px;
  padding: 3px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.65);
  color: #fff;
  font-size: 11px;
  line-height: 1;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.2s ease, transform 0.2s ease;
  pointer-events: none;
}

/* 호버했을 때 보여주기 */
.movie-card:hover .movie-rating-badge {
  opacity: 1;
  transform: translateY(0);
}

.movie-card {
  position: relative;
}

.movie-rating {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(0,0,0,0.6);
  color: #fff;
  font-size: 12px;
  padding: 4px 6px;
  border-radius: 6px;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.movie-card:hover .movie-rating {
  opacity: 1;
}
