@font-face {
    font-family: "Paperozi";
    src: url("https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-4Regular.woff2") format("woff2");
    font-weight: 400;
    font-display: swap;
}

@font-face {
    font-family: "Paperozi";
    src: url("https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-5Medium.woff2") format("woff2");
    font-weight: 500;
    font-display: swap;
}

@font-face {
    font-family: "Paperozi";
    src: url("https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-6SemiBold.woff2") format("woff2");
    font-weight: 600;
    font-display: swap;
}

@font-face {
    font-family: "Paperozi";
    src: url("https://cdn.jsdelivr.net/gh/projectnoonnu/2408-3@1.0/Paperlogy-7Bold.woff2") format("woff2");
    font-weight: 700;
    font-display: swap;
}

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    color: #333;
    font-family: "Paperozi", sans-serif;
    background: linear-gradient(135deg, #0b2545 0%, #16386b 55%, #2f6ba8 100%);
}

#kc-page-title,
.naru-login-intro,
.naru-field label,
.naru-field input,
.naru-checkbox,
.naru-form-link,
#input-error,
#kc-login,
#kc-registration,
#kc-social-providers h2,
#kc-social-providers a,
.pf-v5-c-alert {
    font-family: "Paperozi", sans-serif;
}

.pf-v5-c-login {
    display: flex;
    justify-content: center;
    min-height: 100vh;
    padding: 40px 16px;
    box-sizing: border-box;
}

.pf-v5-c-login__container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: none;
    padding: 0;
    gap: 0;
}

#kc-header {
    display: none;
}

.pf-v5-c-login__main {
    display: block;
    margin: 0 auto;
    width: 420px;
    max-width: 100%;
    padding: 40px 36px 34px;
    background: #fff;
    border-radius: 6px;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.28);
    box-sizing: border-box;
}

.pf-v5-c-login__main-header {
    display: block;
    padding: 0;
}

.pf-v5-c-login__main-header::before {
    content: "";
    display: block;
    width: 176px;
    height: 52px;
    margin: 0 auto 22px;
    background: url("../img/logo.png") center / contain no-repeat;
}

#kc-page-title {
    margin: 0;
    color: #0057b8;
    font-size: 26px;
    font-weight: 700;
    line-height: 1.3;
    text-align: center;
}

.pf-v5-c-login__main-body {
    padding: 0;
}

.naru-login-intro {
    margin: 10px 0 26px;
    padding-bottom: 24px;
    border-bottom: 2px solid #0057b8;
    color: #666;
    font-size: 14px;
    text-align: center;
}

.naru-field {
    margin-bottom: 16px;
}

.naru-field label {
    display: block;
    margin-bottom: 8px;
    color: #333;
    font-size: 13px;
    font-weight: 600;
}

.naru-field input {
    width: 100%;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #ccc;
    border-radius: 4px;
    background: #fff;
    color: #333;
    font-size: 14px;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s;
}

.naru-field input:focus {
    border-color: #0057b8;
}

.naru-input-group {
    position: relative;
}

.naru-input-group input {
    padding-right: 46px;
}

.naru-password-toggle {
    position: absolute;
    top: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: none;
    background: none;
    color: #999;
    cursor: pointer;
}

.naru-password-toggle:hover {
    color: #0057b8;
}

.naru-password-toggle svg {
    width: 20px;
    height: 20px;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.naru-password-toggle .icon-hide {
    display: none;
}

.naru-password-toggle[aria-pressed="true"] .icon-show {
    display: none;
}

.naru-password-toggle[aria-pressed="true"] .icon-hide {
    display: block;
}

#input-error {
    display: block;
    margin: 8px 0 0;
    color: #d64545;
    font-size: 13px;
    line-height: 1.5;
}

.naru-field input[aria-invalid="true"] {
    padding-right: 40px;
    border-color: #d64545;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Ccircle cx='8' cy='8' r='8' fill='%23d64545'/%3E%3Crect x='7.1' y='3.4' width='1.8' height='6' rx='.9' fill='%23fff'/%3E%3Ccircle cx='8' cy='11.6' r='1' fill='%23fff'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    background-size: 16px 16px;
}

.naru-input-group input[aria-invalid="true"] {
    padding-right: 72px;
    background-position: right 46px center;
}

.naru-form-options {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin: 4px 0 18px;
}

.naru-checkbox {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #555;
    font-size: 13px;
    cursor: pointer;
}

.naru-checkbox input {
    width: 15px;
    height: 15px;
    margin: 0;
    accent-color: #0057b8;
}

.naru-form-link {
    color: #666;
    font-size: 13px;
    text-decoration: none;
}

.naru-form-link:hover {
    color: #0057b8;
    text-decoration: underline;
}

#kc-registration {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    margin-top: 20px;
    color: #666;
    font-size: 13px;
}

#kc-registration a {
    padding: 8px 20px;
    border: 1px solid #0057b8;
    border-radius: 4px;
    color: #0057b8;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background 0.2s, color 0.2s;
}

#kc-registration a:hover {
    background: #0057b8;
    color: #fff;
}

#kc-login {
    width: 100%;
    height: 48px;
    margin-top: 8px;
    border: none;
    border-radius: 4px;
    background: #0057b8;
    color: #fff;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: background 0.2s;
}

#kc-login:hover {
    background: #004099;
}

.pf-v5-c-alert {
    margin-bottom: 20px;
    padding: 12px 14px;
    border: 1px solid #f3c9c9;
    border-radius: 4px;
    background: #fdeded;
    color: #c0392b;
    font-size: 13px;
    line-height: 1.5;
}

.pf-v5-c-alert__icon {
    display: none;
}

.pf-v5-c-alert__title {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
}

.pf-v5-c-alert.pf-m-success {
    border-color: #cbe6d3;
    background: #eef8f1;
    color: #1e7a45;
}

#kc-social-providers {
    margin-top: 26px;
    padding-top: 22px;
    border-top: 1px solid #e5e5e5;
}

#kc-social-providers hr {
    display: none;
}

#kc-social-providers h2 {
    margin: 0 0 14px;
    color: #888;
    font-size: 13px;
    font-weight: 600;
    text-align: center;
}

#kc-social-providers ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
}

#kc-social-providers a {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 48px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
    color: #333;
    font-size: 15px;
    font-weight: 700;
    text-decoration: none;
    transition: opacity 0.2s;
}

#kc-social-providers a:hover {
    opacity: 0.88;
}

#kc-social-providers .kc-social-provider-logo {
    display: none;
}

#kc-social-providers a#social-naver {
    border-color: #03c75a;
    background: #03c75a;
    color: #fff;
}

#kc-social-providers a#social-kakao {
    border-color: #fee500;
    background: #fee500;
    color: #3c1e1e;
}

@media (max-width: 480px) {
    .pf-v5-c-login {
        padding: 24px 14px;
    }

    .pf-v5-c-login__container {
        min-height: calc(100vh - 48px);
    }

    .pf-v5-c-login__main {
        padding: 32px 22px 28px;
    }

    .pf-v5-c-login__main-header::before {
        width: 150px;
        height: 46px;
        margin-bottom: 18px;
    }

    #kc-page-title {
        font-size: 22px;
    }

    .naru-login-intro {
        margin-bottom: 22px;
        padding-bottom: 20px;
        font-size: 13px;
    }
}
