@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;700&family=Noto+Sans+KR:wght@300;400;500;700&family=Outfit:wght@200;300;400;600&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans KR', 'Inter', sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    /* 야경 도시 분위기의 깊고 고급스러운 그라데이션 */
    background: 
        radial-gradient(circle at 80% 20%, rgba(235, 140, 50, 0.15) 0%, transparent 50%),
        radial-gradient(circle at 20% 80%, rgba(30, 80, 150, 0.2) 0%, transparent 60%),
        linear-gradient(135deg, #1b1e22 0%, #2c3035 50%, #15181a 100%);
    background-size: cover;
    position: relative;
    overflow: hidden;
}

/* 이미지 속 촘촘한 도트 마스크 패턴 재현 */
body::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: 
        radial-gradient(rgba(0, 0, 0, 0.15) 1.5px, transparent 1.5px),
        radial-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 8px 8px;
    background-position: 0 0, 4px 4px;
    pointer-events: none;
    z-index: 1;
}

.login-container {
    width: 100%;
    max-width: 520px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 30px;
    position: relative;
    z-index: 2;
    animation: fadeInDown 0.8s ease-out;
}

/* 로고 영역 */
.logo-area {
    margin-bottom: 5px;
    display: flex;
    justify-content: center;
    align-items: center;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.kumho-logo {
    display: block;
}

/* 글래스모피즘 로그인 박스 */
.login-box {
    width: 100%;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: 4px;
    box-shadow: 
        0 20px 50px rgba(0, 0, 0, 0.4),
        inset 0 1px 0 rgba(255, 255, 255, 0.2);
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.login-box:hover {
    box-shadow: 
        0 25px 60px rgba(0, 0, 0, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.25);
}

/* 헤더 영역 */
.login-header {
    padding: 30px 40px 0 40px;
    text-align: center;
}

.login-header h2 {
    font-family: 'Outfit', sans-serif;
    font-weight: 200;
    font-size: 2.3rem;
    color: #ffffff;
    letter-spacing: 2.5px;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
    padding-bottom: 25px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
}

/* 폼 본문 */
.login-body {
    padding: 30px 40px 40px 40px;
}

.input-group {
    margin-bottom: 22px;
    display: flex;
    flex-direction: column;
}

.input-group label {
    font-size: 0.82rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 8px;
    font-weight: 500;
    letter-spacing: 0.5px;
}

.input-group input {
    width: 100%;
    padding: 13px 16px;
    border: none;
    border-radius: 3px;
    background: #ffffff;
    color: #222222;
    font-size: 1.15rem;
    font-family: 'Outfit', 'Inter', sans-serif;
    font-weight: 400;
    outline: none;
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.12);
    transition: box-shadow 0.2s, background-color 0.2s;
}

.input-group input:focus {
    background-color: #f7f9fa;
    box-shadow: 
        inset 0 2px 4px rgba(0, 0, 0, 0.12),
        0 0 0 3px rgba(63, 169, 245, 0.4);
}

/* 체크박스 영역 (SAVE ID) */
.options-group {
    margin-bottom: 28px;
}

.checkbox-container {
    display: inline-flex;
    align-items: center;
    position: relative;
    padding-left: 28px;
    cursor: pointer;
    font-size: 0.8rem;
    font-family: 'Outfit', sans-serif;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.9);
    user-select: none;
    letter-spacing: 0.8px;
}

.checkbox-container input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    left: 0;
    height: 17px;
    width: 17px;
    background-color: transparent;
    border: 1.5px solid rgba(255, 255, 255, 0.6);
    border-radius: 2px;
    transition: all 0.2s;
}

.checkbox-container:hover input ~ .checkmark {
    border-color: #ffffff;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.4);
}

.checkbox-container input:checked ~ .checkmark {
    background-color: #3897f0;
    border-color: #3897f0;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.checkbox-container input:checked ~ .checkmark:after {
    display: block;
}

.checkbox-container .checkmark:after {
    left: 5px;
    top: 1px;
    width: 4px;
    height: 9px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

/* 로그인 버튼 */
#loginBtn {
    width: 100%;
    padding: 14px;
    background: #3897f0;
    border: none;
    border-radius: 3px;
    color: #ffffff;
    font-family: 'Outfit', sans-serif;
    font-size: 1.15rem;
    font-weight: 500;
    letter-spacing: 1.5px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(56, 151, 240, 0.3);
    transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
}

#loginBtn:hover {
    background: #4fa4f3;
    box-shadow: 0 6px 20px rgba(56, 151, 240, 0.5);
    transform: translateY(-1px);
}

#loginBtn:active {
    transform: translateY(1px);
    box-shadow: 0 2px 10px rgba(56, 151, 240, 0.3);
}

#loginBtn:disabled {
    background: rgba(255, 255, 255, 0.2);
    color: rgba(255, 255, 255, 0.4);
    box-shadow: none;
    cursor: not-allowed;
    transform: none;
}

/* 에러 메시지 */
.error-message {
    display: none;
    margin-top: 18px;
    padding: 10px 12px;
    background: rgba(233, 30, 99, 0.2);
    border: 1px solid rgba(233, 30, 99, 0.4);
    border-radius: 3px;
    color: #ff85a2;
    font-size: 0.85rem;
    text-align: center;
    animation: shake 0.4s ease-in-out;
}

/* 키프레임 애니메이션 */
@keyframes fadeInDown {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-6px); }
    40%, 80% { transform: translateX(6px); }
}

/* 모바일 반응형 처리 */
@media (max-width: 480px) {
    .login-container {
        padding: 15px;
    }
    
    .login-header h2 {
        font-size: 1.8rem;
    }
    
    .login-body {
        padding: 25px 25px 30px 25px;
    }
}
