/* Login Page Styles */

.login-wrapper {
    min-height: calc(100vh - 80px - 220px); /* viewport - header - footer */
    display: flex;
    justify-content: center;
    background-color: #fff;
    padding: 100px 20px 60px;
}

.login-container {
    width: 100%;
    max-width: 486px;
    display: flex;
    flex-direction: column;
    gap: 60px;
}

.login-title {
    font-size: 28px;
    font-weight: 700;
    line-height: 38px;
    text-align: center;
    color: #3a3a3a;
}

.login-form {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.form-group {
    position: relative;
}

/* 라벨 스타일 */
.form-label {
    display: block;
    font-size: 18px;
    font-weight: 700;
    line-height: 24px;
    color: #3a3a3a;
    margin-bottom: 12px;
}

.form-label-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

/* 비밀번호 찾기 링크 */
.link-forgot-password {
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: #00CC4C;
    text-decoration: none;
    transition: color 0.2s;
}

.link-forgot-password:hover {
    color: #00B343;
    text-decoration: underline;
}

/* 스크린 리더 전용 (접근성) */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    border: 0;
}

/* 입력 필드 기본 스타일 */
.form-input {
    width: 100%;
    height: 48px;
    padding: 0 16px;
    border: 1px solid transparent;
    border-radius: 12px;
    font-size: 16px;
    color: #3a3a3a;
    background-color: #f6f6f6;
    transition: border-color 0.2s, background-color 0.2s;
    box-sizing: border-box;
}

.form-input::placeholder {
    color: #999;
}

/* 포커스 상태 */
.form-input:focus {
    outline: none;
    border-color: #1a1a1a;
    background-color: #fff;
}

/* 에러 상태 - 입력 필드는 테두리 변경 없음 */


/* 에러 메시지 */
.error-message {
    display: none;
    margin-top: 12px;
    font-size: 14px;
    font-weight: 400;
    line-height: 20px;
    color: #FF6262;
}

.error-message.visible {
    display: block;
}

/* 일반 에러 메시지 박스 */
.error-message-box {
    display: none;
    padding: 12px 16px;
    background-color: #FFF0F0;
    border: 1px solid #FFD5D5;
    border-radius: 12px;
    color: #FF5B5B;
    font-size: 14px;
    text-align: center;
}

.error-message-box.visible {
    display: block;
}

/* 로그인 버튼 */
.btn-login {
    width: 100%;
    height: 48px;
    margin-top: 36px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}

/* 버튼 비활성화 상태 */
.btn-login:disabled {
    background-color: #d3d3d3;
    color: #fff;
    cursor: not-allowed;
}

/* 버튼 활성화 상태 */
.btn-login:not(:disabled) {
    background-color: #0F2A44;
    color: #fff;
}

.btn-login:not(:disabled):hover {
    background-color: #1A3A5C;
}

/* 로딩 상태 */
.btn-login.loading {
    position: relative;
    color: transparent;
}

.btn-login.loading::after {
    content: '';
    position: absolute;
    width: 20px;
    height: 20px;
    top: 50%;
    left: 50%;
    margin-left: -10px;
    margin-top: -10px;
    border: 2px solid #fff;
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* 하단 회원가입 링크 영역 */
.login-footer {
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    line-height: 20px;
    color: #3a3a3a;
}

.footer-text {
    color: #3a3a3a;
}

.link-signup {
    color: #3a3a3a;
    text-decoration: underline;
    transition: color 0.2s;
}

.link-signup:hover {
    opacity: 0.8;
}

.link-signup-green {
    color: #00CC4C;
}

/* Responsive */
@media (max-width: 480px) {
    .login-wrapper {
        padding: 60px 16px 40px;
    }

    .login-container {
        gap: 40px;
    }

    .login-title {
        font-size: 24px;
        line-height: 32px;
    }

    .form-label-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}