/* 메인 팝업 — newup 팝업관리 연동 */
.sky-popup-root:not(.dspn) {
  position: fixed;
  inset: 0;
  z-index: 999998;
  pointer-events: none;
}

.sky-popup-layer {
  position: fixed;
  inset: 0;
  z-index: 999999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 72px 16px 24px;
  pointer-events: auto;
}

.sky-popup-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
}

.sky-popup-stage {
  position: relative;
  z-index: 1;
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: center;
  gap: 20px;
  max-width: min(100%, 1680px);
  max-height: calc(100vh - 100px);
  overflow: auto;
  padding: 4px;
}

.sky-popup-card {
  flex: 0 0 auto;
  max-width: calc(100vw - 32px);
  border-radius: 12px;
  overflow: hidden;
  background: linear-gradient(160deg, #1a1a1a 0%, #0d0d0d 100%);
  border: 1px solid rgba(229, 170, 6, 0.45);
  box-shadow:
    0 0 0 1px rgba(0, 0, 0, 0.65) inset,
    0 18px 48px rgba(0, 0, 0, 0.55),
    0 0 24px rgba(229, 170, 6, 0.08);
}

.sky-popup-body {
  line-height: 0;
  background: #111;
}

.sky-popup-body img {
  display: block;
  width: 100%;
  height: auto;
  max-height: min(72vh, 720px);
  object-fit: contain;
}

.sky-popup-body a {
  display: block;
  line-height: 0;
}

.sky-popup-html {
  padding: 12px 14px;
  color: #eee;
  font-size: 14px;
  line-height: 1.55;
  max-height: min(72vh, 720px);
  overflow: auto;
}

.sky-popup-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  background: linear-gradient(
    180deg,
    rgba(30, 30, 30, 0.98) 0%,
    rgba(12, 12, 12, 0.98) 100%
  );
  border-top: 1px solid rgba(229, 170, 6, 0.28);
}

.sky-popup-btn {
  appearance: none;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.04);
  color: #ddd;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.2;
  padding: 8px 14px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
  white-space: nowrap;
}

.sky-popup-btn i {
  font-size: 13px;
  opacity: 0.92;
}

.sky-popup-btn--dismiss:hover {
  border-color: rgba(229, 170, 6, 0.55);
  background: rgba(229, 170, 6, 0.12);
  color: #ffe418;
  box-shadow: 0 0 12px rgba(229, 170, 6, 0.15);
}

.sky-popup-btn--close {
  border-color: rgba(229, 170, 6, 0.35);
  background: linear-gradient(135deg, rgba(229, 170, 6, 0.22) 0%, rgba(180, 130, 0, 0.12) 100%);
  color: #ffe418;
}

.sky-popup-btn--close:hover {
  border-color: rgba(255, 228, 24, 0.65);
  background: linear-gradient(135deg, rgba(229, 170, 6, 0.35) 0%, rgba(180, 130, 0, 0.2) 100%);
  box-shadow: 0 0 14px rgba(229, 170, 6, 0.22);
}

.sky-popup-close-all {
  position: fixed;
  left: 50%;
  top: 22px;
  transform: translateX(-50%);
  z-index: 1000000;
  appearance: none;
  border: 1px solid rgba(229, 170, 6, 0.4);
  background: linear-gradient(135deg, rgba(20, 20, 20, 0.95) 0%, rgba(8, 8, 8, 0.95) 100%);
  color: #ffe418;
  font-size: 13px;
  font-weight: 700;
  padding: 10px 20px;
  border-radius: 999px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45);
  pointer-events: auto;
}

.sky-popup-close-all:hover {
  border-color: rgba(255, 228, 24, 0.65);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.45), 0 0 16px rgba(229, 170, 6, 0.18);
}

@media (max-width: 767px) {
  .sky-popup-layer {
    padding: 64px 10px 16px;
  }

  .sky-popup-stage {
    gap: 14px;
    max-height: calc(100vh - 88px);
  }

  .sky-popup-card {
    width: calc(100vw - 24px) !important;
    max-width: calc(100vw - 24px);
  }

  .sky-popup-foot {
    flex-wrap: wrap;
    justify-content: center;
  }

  .sky-popup-btn {
    flex: 1 1 auto;
    justify-content: center;
    min-width: 0;
  }
}
