/**
 * OTP 2차 인증 모달 스타일
 */

/* OTP 모달 오버레이 */
.otp-modal-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    backdrop-filter: blur(3px);
}

/* 모달 활성화 시 로그인 필드 잠금 스타일 */
.login-locked {
    pointer-events: none !important;
    user-select: none !important;
}

.login-locked input,
.login-locked input[readonly] {
    background-color: #d5d5d5 !important;
    border-color: #bbb !important;
    color: #888 !important;
    cursor: not-allowed !important;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.1) !important;
}

.login-locked .btnLogin,
.login-locked .btnLogin2 {
    background-color: #ccc !important;
    border-color: #bbb !important;
    color: #888 !important;
    cursor: not-allowed !important;
}

/* 모달 박스 */
.otp-modal {
    background: #fff;
    border-radius: 12px;
    width: 400px;
    max-width: 90%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.3);
    animation: otpModalFadeIn 0.3s ease;
}

@keyframes otpModalFadeIn {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 모달 헤더 */
.otp-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e0e0e0;
    background: #014099;
    color: #fff;
    border-radius: 12px 12px 0 0;
}

.otp-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.otp-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #fff;
    padding: 0;
    line-height: 1;
}

.otp-modal-close:hover {
    opacity: 0.8;
}

/* 모달 바디 */
.otp-modal-body {
    padding: 24px;
    text-align: center;
}

/* QR코드 컨테이너 */
.otp-qrcode-container {
    margin-bottom: 20px;
}

.otp-qrcode-container img {
    max-width: 200px;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px;
    background: #fff;
}

/* 안내 문구 */
.otp-instruction {
    color: #666;
    font-size: 14px;
    margin-bottom: 20px;
    line-height: 1.6;
}

/* OTP 입력 영역 */
.otp-input-container {
    margin: 20px auto;
    display: inline-block;
    text-align: left;
}

.otp-input-container label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #333;
    padding-left: 2px;
}

.otp-input-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.otp-input {
    width: 180px;
    height: 48px;
    text-align: center;
    font-size: 24px;
    letter-spacing: 8px;
    border: 2px solid #ddd;
    border-radius: 8px;
    transition: border-color 0.2s;
}

.otp-input:focus {
    outline: none;
    border-color: #014099;
}

/* 주의사항 힌트 */
.otp-hint {
    margin: 12px 0 0 0;
    padding: 0;
    font-size: 11px;
    color: #999;
    text-align: left;
    list-style: none;
}

.otp-hint li {
    margin-bottom: 3px;
}

.otp-hint li:before {
    content: "※ ";
    color: #bbb;
}

/* 타이머 */
.otp-timer {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 14px;
    color: #666;
}

.otp-timer-count {
    font-weight: bold;
    color: #014099;
}

.otp-refresh-btn {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 18px;
    color: #014099;
    padding: 5px;
    transition: transform 0.3s;
}

.otp-refresh-btn:hover {
    transform: rotate(180deg);
}

/* 모달 푸터 */
.otp-modal-footer {
    padding: 16px 24px 24px;
    display: flex;
    justify-content: space-between;
    gap: 10px;
}

/* 버튼 스타일 */
.otp-btn {
    flex: 1;
    padding: 12px 20px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.otp-btn-primary {
    background: #014099;
    color: #fff;
    border: none;
}

.otp-btn-primary:hover {
    background: #012d6e;
}

.otp-btn-secondary {
    background: #f5f5f5;
    color: #333;
    border: 1px solid #ddd;
}

.otp-btn-secondary:hover {
    background: #eee;
}

/* 에러 메시지 */
.otp-error {
    color: #d32f2f;
    font-size: 13px;
    margin-top: 10px;
    display: none;
}

/* 로딩 */
.otp-loading {
    display: none;
    text-align: center;
    padding: 20px;
}

.otp-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #014099;
    border-radius: 50%;
    animation: otpSpin 1s linear infinite;
    margin: 0 auto 10px;
}

@keyframes otpSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 전체 화면 로딩 오버레이 */
.fullpage-loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 99999;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.fullpage-loading-overlay.show {
    display: flex;
}

.fullpage-loading-spinner {
    width: 60px;
    height: 60px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #fff;
    border-radius: 50%;
    animation: otpSpin 1s linear infinite;
    margin-bottom: 20px;
}

.fullpage-loading-text {
    color: #fff;
    font-size: 18px;
    font-weight: 500;
}
