/* 팝업 오버레이 배경 */
.popup-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 9998;
    display: none;
    align-items: center;
    justify-content: center;
    overflow-y: auto;
    padding: 20px;
    box-sizing: border-box;
}

.popup-overlay.active {
    display: flex;
}

/* 팝업 콘텐츠 컨테이너 - 중앙 정렬 */
.popup-container {
    position: relative;
    margin: auto;
    max-width: 400px;
    width: 100%;
    max-height: calc(100vh - 40px);
    display: flex;
    flex-direction: column;
}

/* 팝업 콘텐츠 */
.popup-content {
    position: relative;
    background: #ffffff;
    border-radius: 12px;
    overflow-y: auto;
    overflow-x: hidden;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
    animation: popupSlideIn 0.3s ease;
    scrollbar-width: thin;
    scrollbar-color: #888 #f1f1f1;
}

/* 팝업 헤더 */
.popup-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #e0e0e0;
    background: #f8f9fa;
    border-radius: 12px 12px 0 0;
    flex-shrink: 0;
}

.popup-header-left {
    display: flex;
    align-items: center;
    gap: 8px;
}

.popup-header-left input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.popup-header-left label {
    margin: 0;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    user-select: none;
}

.popup-close-btn {
    background: none;
    border: none;
    font-size: 20px;
    color: #666;
    cursor: pointer;
    padding: 5px 10px;
    transition: color 0.2s;
    line-height: 1;
}

.popup-close-btn:hover {
    color: #000;
}

/* 팝업 본문 */
.popup-body {
    padding: 0;
    overflow-y: auto;
}

.popup-body img {
    width: 100%;
    height: auto;
    display: block;
}

.popup-body a {
    display: block;
    text-decoration: none;
}

/* 애니메이션 */
@keyframes popupSlideIn {
    from {
        transform: translateY(-20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

/* 모바일 반응형 */
@media (max-width: 768px) {
    .popup-overlay {
        padding: 15px;
    }

    .popup-container {
        max-width: 100%;
        max-height: calc(100vh - 30px);
    }

    .popup-header {
        padding: 12px 15px;
    }

    .popup-header-left label {
        font-size: 13px;
    }

    .popup-close-btn {
        font-size: 18px;
        padding: 3px 8px;
    }
}

@media (max-width: 480px) {
    .popup-overlay {
        padding: 10px;
    }

    .popup-container {
        max-height: calc(100vh - 20px);
    }

    .popup-header {
        padding: 10px 12px;
    }

    .popup-header-left label {
        font-size: 12px;
    }

    .popup-header-left input[type="checkbox"] {
        width: 16px;
        height: 16px;
    }
}

/* 스크롤바 스타일 */
.popup-content::-webkit-scrollbar {
    width: 8px;
}

.popup-content::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.popup-content::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.popup-content::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* 이달의 보험상품 업데이트 예정일 배너 스타일 */
.update-banner-link {
    display: block;
    width: 100%;
    background: linear-gradient(90deg,#0c6799,#0d8ad8);
    border-radius: 14px;
    padding: 12px 18px;
    color: #ffffff;
    text-decoration: none;
    box-shadow: 0 6px 18px rgba(0,0,0,0.18);
    position: relative;
    overflow: hidden;
    margin-top: -6px;
    transition: all 0.25s ease;
}

.update-banner-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 26px rgba(12,103,153,0.45);
    color: #e6ff9f;
}

.update-banner-inner {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
}

.update-banner-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.update-banner-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255,255,255,0.15);
}

.update-banner-title {
    text-align: left;
    font-size: 14px;
    font-weight: 600;
}

.update-banner-sub {
    text-align: left;
    font-size: 11px;
    opacity: 0.9;
}

.update-banner-pill {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 999px;
    background: rgba(255,255,255,0.18);
    font-size: 11px;
    font-weight: 600;
}

.update-banner-highlight {
    position: absolute;
    top: -40%;
    right: -20%;
    width: 120px;
    height: 120px;
    background: radial-gradient(circle, rgba(255,255,255,0.35) 0%, transparent 60%);
    opacity: 0.8;
}

/* 유튜브 배너 물결 효과 */
.youtube-banner-wave {
    position: relative;
    overflow: hidden;
    background: linear-gradient(90deg, #ff4b2b, #ff416c);
    transition: all 0.3s ease;
    cursor: pointer;
}

/* 호버 효과 */
.youtube-banner-wave:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(255, 75, 43, 0.4) !important;
    background: linear-gradient(90deg, #ff5c3d, #ff5270) !important;
    color: #ffffff !important;
}

.youtube-banner-wave:hover::before {
    animation-duration: 8s;
    background: 
        radial-gradient(circle at 30% 30%, rgba(255,255,255,0.25) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255,255,255,0.2) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255,255,255,0.15) 0%, transparent 60%);
}

.youtube-banner-wave:hover::after {
    animation-duration: 10s;
    background: 
        radial-gradient(circle at 60% 40%, rgba(255,255,255,0.2) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(255,255,255,0.18) 0%, transparent 50%);
}

/* 호버 시 내부 요소 효과 */
.youtube-banner-wave:hover .youtube-icon {
    transform: scale(1.15) rotate(5deg);
    transition: transform 0.3s ease;
    box-shadow: 0 4px 12px rgba(255, 0, 0, 0.3);
}

.youtube-banner-wave:hover .youtube-button {
    background: rgba(255,255,255,0.3) !important;
    transform: translateX(5px);
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(255,255,255,0.2);
}

/* 호버 시 텍스트 약간 밝게 */
.youtube-banner-wave:hover div {
    opacity: 1 !important;
    transition: opacity 0.3s ease;
}

.youtube-banner-wave::before {
    content: '';
    position: absolute;
    width: 400%;
    height: 400%;
    top: -150%;
    left: -150%;
    background: 
        radial-gradient(circle at 30% 30%, rgba(255,255,255,0.15) 0%, transparent 50%),
        radial-gradient(circle at 70% 70%, rgba(255,255,255,0.1) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(255,255,255,0.08) 0%, transparent 60%);
    animation: wave-animation-1 12s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

.youtube-banner-wave::after {
    content: '';
    position: absolute;
    width: 400%;
    height: 400%;
    top: -150%;
    left: -150%;
    background: 
        radial-gradient(circle at 60% 40%, rgba(255,255,255,0.12) 0%, transparent 50%),
        radial-gradient(circle at 40% 60%, rgba(255,255,255,0.1) 0%, transparent 50%);
    animation: wave-animation-2 15s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes wave-animation-1 {
    0% {
        transform: translate(0%, 0%) rotate(0deg);
    }
    25% {
        transform: translate(10%, 15%) rotate(90deg);
    }
    50% {
        transform: translate(0%, 30%) rotate(180deg);
    }
    75% {
        transform: translate(-10%, 15%) rotate(270deg);
    }
    100% {
        transform: translate(0%, 0%) rotate(360deg);
    }
}

@keyframes wave-animation-2 {
    0% {
        transform: translate(0%, 0%) rotate(0deg);
    }
    33% {
        transform: translate(-15%, 10%) rotate(120deg);
    }
    66% {
        transform: translate(15%, -10%) rotate(240deg);
    }
    100% {
        transform: translate(0%, 0%) rotate(360deg);
    }
}

