/* SweetAlert2 다크 테마 커스터마이징 */
div:where(.swal2-container) div:where(.swal2-popup) {
    background-color: #0f172a !important; /* 배경색: KRONA Dark */
    /* 만약 글래스모피즘(반투명)을 원하시면 아래 주석 해제 */
    /* background: rgba(30, 41, 59, 0.95) !important; */
    /* backdrop-filter: blur(10px); */
    
    border: 1px solid rgba(255, 255, 255, 0.1) !important; /* 테두리 */
    border-radius: 20px !important;       /* 둥근 모서리 */
    color: #ffffff !important;            /* 글자색 화이트 */
}

/* 제목 색상 강제 지정 */
div:where(.swal2-container) .swal2-title {
    color: #ffffff !important;
}

/* 본문 텍스트 색상 */
div:where(.swal2-container) .swal2-html-container {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* 확인 버튼 스타일 (Cyan Gradient) */
div:where(.swal2-container) .swal2-confirm {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
    color: #000 !important;
    font-weight: bold !important;
    border-radius: 10px !important;
    box-shadow: 0 4px 15px rgba(0, 242, 254, 0.3) !important;
}

/* 취소 버튼 스타일 */
div:where(.swal2-container) .swal2-cancel {
    background: transparent !important;
    border: 1px solid rgba(255,255,255,0.3) !important;
    color: #fff !important;
}

/* SweetAlert2 Toast 스타일 커스텀 */

/* 1. 토스트 팝업 자체의 패딩 조절 (전체적으로 날렵하게) */
.swal2-popup.swal2-toast {
    padding: 0.5em 1em !important;
    font-size: 0.9rem !important; /* 글자 크기도 살짝 조절 */
}

/* 2. 아이콘 전체를 비율대로 축소 (핵심!) */
.swal2-popup.swal2-toast .swal2-icon {
    /* 원본 크기를 무시하고 강제로 0.6배로 줄임 */
    transform: scale(0.6) !important; 
    
    /* scale을 쓰면 원래 자리를 차지하므로 여백을 제거해줘야 함 */
    margin: 0 !important; 
    margin-right: -10px !important; /* 아이콘과 텍스트 사이 간격 좁히기 */
}

/* 3. 성공 아이콘(V)이 중앙에 잘 오도록 미세 조정 (선택사항) */
.swal2-popup.swal2-toast .swal2-icon.swal2-success {
    transform-origin: center;  /* 필요 시 활성화 */
}

/* 4. 타이틀(메시지) 위치 보정 */
.swal2-popup.swal2-toast .swal2-title {
    margin: 0 0 0 10px !important; /* 아이콘과의 간격 확보 */
    font-weight: 500 !important;
}

/* =========================================================
   SweetAlert2 일반 팝업(Modal) 스타일 수정
   ========================================================= */

/* 1. 아이콘 크기를 강제로 70%로 축소 (비율 유지) */
.swal2-popup:not(.swal2-toast) .swal2-icon {
    transform: scale(0.7) !important; 
    margin-top: 2rem !important;      /* 줄어든 만큼 위쪽 여백 재조정 */
    margin-bottom: 0.5rem !important; /* 아래쪽 여백 좁히기 */
}

/* 2. 제목(Registration Failed)과 아이콘 사이 간격 좁히기 */
.swal2-popup:not(.swal2-toast) .swal2-title {
    padding-top: 0 !important;
    font-size: 1.6em !important; /* 제목 폰트도 너무 크면 살짝 조절 */
}

/* 3. 본문 텍스트(Your email...) 가독성 높이기 */
.swal2-popup:not(.swal2-toast) .swal2-html-container {
    margin-top: 10px !important;
    font-size: 1.1em !important;
    color: #cbd5e1 !important; /* 연한 회색 (text-gray-300 느낌) */
}

/* 4. (선택사항) 확인 버튼 디자인 (브랜드 컬러 적용) */
.swal2-popup:not(.swal2-toast) .swal2-confirm {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%) !important;
    border-radius: 12px !important;
    padding: 12px 30px !important;
    font-weight: bold !important;
    box-shadow: 0 4px 15px rgba(0, 242, 254, 0.3) !important;
}
/* SweetAlert2 Toast 포커스 및 클릭 방지 */

/* 1. 토스트 컨테이너가 클릭을 막지 않도록 설정 (배경 클릭 가능하게) */
div:where(.swal2-container).swal2-top-end,
div:where(.swal2-container).swal2-top-right,
div:where(.swal2-container).swal2-top-left,
div:where(.swal2-container).swal2-top-start,
div:where(.swal2-container).swal2-center-start,
div:where(.swal2-container).swal2-center-end {
    pointer-events: none !important; /* 토스트 주변 빈 공간 클릭 가능 */
}

/* 2. 토스트 팝업 자체는 클릭/호버 가능해야 함 (타이머 멈춤 기능을 위해) */
.swal2-popup.swal2-toast {
    pointer-events: auto !important; 
    outline: none !important; /* 포커스 테두리 제거 */
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05) !important;
}

/* 3. ★ 핵심: 아이콘이 포커스를 받지 않도록 설정 */
.swal2-popup.swal2-toast .swal2-icon {
    pointer-events: none !important; /* 마우스 이벤트 무시 */
    outline: none !important; /* 포커스 링 제거 */
}

/* 4. 타이틀도 선택 불가능하게 (깔끔함) */
.swal2-popup.swal2-toast .swal2-title {
    pointer-events: none !important;
    user-select: none !important;
}

/* 1. 모달 전체 배경 (어둡게 처리) */
.aurum-modal-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100vw; height: 100vh;
    /* 방법 1: 8자리 헥사코드 */
    /* background: #0f172ad9;  */
    
    /* 또는 방법 2: RGBa (더 직관적임) */
    background: rgba(30, 41, 59, 0.85);
    
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

/* 2. 모달 컨텐츠 박스 */
.aurum-modal-content {
    background: #11161f; /* 다크 테마 배경색 */
    width: 85%;
    max-width: 360px; 
    padding: 30px 24px;
    border-radius: 20px;
    border: 1px solid rgba(212, 175, 55, 0.3); /* 은은한 골드 테두리 */
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5), 
                0 0 15px rgba(212, 175, 55, 0.1); /* 수정했던 그로우 효과 */
    text-align: center;
}

.modal-icon-container {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px; /* 중앙 정렬 및 아래 여백 */
    border-width: 1px;
    border-style: solid;
    background: transparent; /* 원 내부 미세한 배경색 */
}

/* 3. 아이콘 및 텍스트 */
.modal-icon {
    font-size: 15px;
    margin-bottom: 15px;
}

.modal-icon-symbol {
    font-size: 32px;
    font-weight: bold;
}

.modal-warning {
    border-color: #d4af37;
    color: #d4af37;
}

.modal-success {
    border-color: #28a745;
    color: #28a745;
}

.modal-title {
    color: #d4af37; /* 골드 타이틀 */
    font-size: 0.7rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.modal-text {
    color: #a0a0a0;
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 25px;
}


/* 4. 버튼 스타일 (Aurum 메인 버튼과 통일) */
.btn-modal-primary, .btn-modal-close {
    background: linear-gradient(135deg, #d4af37, #b8860b);
    border: none;
    color: #000;
    font-weight: 800;
    padding: 14px 0;
    border-radius: 12px;
    width: 100%;
    transition: transform 0.2s ease;
}

.btn-modal-secondary {
    background: #333;
    border: none;
    color: #fff;
    font-weight: 600;
    padding: 14px 0;
    border-radius: 12px;
    width: 100%;
}

.btn-modal-primary:active, .btn-modal-secondary:active {
    transform: scale(0.98);
}


/* 로딩 플레이스홀더 스타일 */
.loading-placeholder {
    display: inline-block;
    width: 100%; 
    height: 0.3em;
    /* 배경색인 #1e293b보다 약간 밝은 톤으로 그라데이션 */
    background: linear-gradient(
        90deg, 
        #1e293b 25%, 
        #334155 50%, 
        #1e293b 75%
    );
    background-size: 200% 100%;
    animation: skeleton-loading 1.5s infinite ease-in-out;
    border-radius: 6px;
}

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