/* CSS를 활용하여 레이아웃 및 스타일링을 완성해주세요 */
:root{
    --text-font : 1rem;
    --text-style : #121212;
    --white : #fff;
    --green : #03cf5d;

    /* 데스크탑 기준 max width */
    --max-width : 31.35rem;

    --side-gap : 1.25rem;
}

html, body{
    margin: 0rem;
    padding: 0rem;
    width: 100%;
    height: 100%;
}

figure, input, button, label, span, a{
    margin: 0rem;
    padding: 0rem;
    font-size: var(--text-font);
    color: var(--text-style);
}

a{
    text-decoration: none;
}

button{
    border: none;
}

.header{
    display: flex;
    justify-content: center;
    margin-top: 6.25rem;
    margin-bottom: 2.8125rem;
}

.main{
    padding: var(--side-gap);
}



.mainform{
    display: flex;
    flex-flow: wrap row;
    
    button{
        inline-size: 100%;
        block-size: 2.8125rem;
        background-color: var(--green);
        margin-top: 1.25rem;
        color: var(--white);
    }
    /* 아이디 패스워드 input 영역 */
    input[type="text"], input[type="password"]{
        font-size: 0.875rem;
        inline-size: 100%;
        block-size: 3rem;
        background-color: var(--white);
        padding-left: 14px;
        border: 1px solid #dadada;
    }
    input[type="text"]:hover, input[type="password"]:hover{
        background-color: #e9f0fd;
    }
    input[type="text"]:focus, input[type="password"]:focus{
        background-color: #e9f0fd;
        outline: 1px solid #03cf5d;
        font-size: var(--text-font);
    }
    input[type="text"]{
        margin-bottom: 0.625rem;
    }

    /* label + 체크박스 인풋 영역 */
    .loginState, .ipSecurity{
        margin-top: 0.625rem;
    }
    .ipSecurity{
        display: none;
        input[type="checkbox"]{
            margin-left: 0.3125rem;
            appearance: none;
            width: 2.2rem;
            height: 1.5rem;
            font-size: var(--text-font);
        }
        input[type="checkbox"]::after{
            content: "OFF";
            font-weight: 600;
            color: gray;
            
        }
        input[type="checkbox"]:checked:after{
            content: "ON";
            color: var(--green);
        }
    }
    .loginState{
        display: inline-flex;
        align-items: center;
        margin-left: auto;
        input[type="checkbox"]{
            margin-right: 0.3125rem;
            appearance: none;
            width: 1.5rem;
            height: 1.5rem;
            background-image: url("../images/unchecked.svg");
        }
        input[type="checkbox"]:checked{
            background-image: url("../images/checked.svg");
        }
    }

    @media (768px <= width){
        .ipSecurity{
            display: block;
            margin-left: auto;
        }
        .loginState{
            margin-left: 0px;
        }
    }
}
@media (768px <= width){
    .header{
        margin-bottom: 3.125rem;
    }
    .main{
        display: flex;
        justify-content: center;
    }
    .mainform{
        justify-content: center;
        max-width: var(--max-width);

        flex-flow: wrap row;
        input[type="text"], input[type="password"]{
            inline-size: calc(28.75rem - 0.875rem);
        }
        button{
            inline-size: 28.75rem;
        }
        .loginState{
            margin-left: 1.3rem;
        }
        .ipSecurity{
            margin-right: 1.3rem;
        }
    }
}

.loginState:hover, .ipSecurity:hover, .loginState input:hover, .ipSecurity input:hover, button:hover{
    cursor: pointer;
}