/* 로그인 · 회원가입 공통 */

body.auth-page {
    overflow: auto;
}

.auth-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem 3rem;
    width: 100%;
}

.auth-card {
    width: 100%;
    max-width: 420px;
    padding: 2rem;
    background: var(--card-bg);
    border: 2px solid var(--border);
}

.auth-title {
    font-family: var(--font-header);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.auth-notice {
    font-family: var(--font-main);
    font-size: 0.85rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 1.5rem;
    padding: 1rem;
    border: 1px solid rgba(255, 255, 255, 0.35);
    background: rgba(15, 15, 87, 0.25);
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.auth-field label {
    display: block;
    font-family: var(--font-main);
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
}

.auth-label-row {
    display: flex;
    align-items: baseline;
    flex-wrap: wrap;
    gap: 0.5rem 0.75rem;
    margin-bottom: 0.35rem;
}

.auth-label-row label {
    margin-bottom: 0;
}

.auth-id-check-msg {
    font-family: var(--font-main);
    font-size: 0.85rem;
    color: var(--secondary);
    min-height: 1.2em;
}

.auth-id-row {
    display: flex;
    gap: 0.5rem;
    align-items: stretch;
}

.auth-id-row input[type="text"] {
    flex: 1;
    min-width: 0;
    width: auto;
}

.auth-id-check-btn {
    flex-shrink: 0;
    padding: 0.5rem 0.85rem;
    font-family: var(--font-main);
    font-size: 0.9rem;
    cursor: pointer;
    color: var(--text);
    background: transparent;
    border: 2px solid var(--border);
    white-space: nowrap;
    transition: border-color 0.2s ease, color 0.2s ease;
}

.auth-id-check-btn:hover {
    border-color: var(--secondary);
    color: var(--secondary);
}

.auth-field input[type="text"],
.auth-field input[type="password"] {
    width: 100%;
    padding: 0.75rem 1rem;
    background: transparent;
    border: 2px solid var(--border);
    color: var(--text);
    font-family: var(--font-main);
    font-size: 1rem;
    outline: none;
}

.auth-password-wrap {
    position: relative;
    width: 100%;
}

.auth-password-wrap input[type="text"],
.auth-password-wrap input[type="password"] {
    padding-right: 2.75rem;
}

.auth-password-toggle {
    position: absolute;
    right: 0.35rem;
    top: 50%;
    transform: translateY(-50%);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.25rem;
    height: 2.25rem;
    padding: 0;
    border: none;
    background: transparent;
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
    font-size: 1.15rem;
    line-height: 1;
}

.auth-password-toggle:hover {
    color: var(--secondary);
}

.auth-field input:focus {
    border-color: var(--secondary);
}

.auth-submit {
    margin-top: 0.5rem;
    padding: 0.75rem 1.25rem;
    font-family: var(--font-main);
    font-size: 1rem;
    cursor: pointer;
    color: var(--text);
    background: transparent;
    border: 2px solid var(--border);
    transition: border-color 0.2s ease, color 0.2s ease;
}

.auth-submit:hover {
    border-color: var(--secondary);
    color: var(--secondary);
}

.auth-submit-error {
    margin: 0.75rem 0 0;
    padding: 0;
    text-align: left;
    font-family: var(--font-main);
    font-size: 0.9rem;
    line-height: 1.4;
    color: blue;
    font-weight: bold;
}

.auth-submit-error[hidden] {
    display: none;
}

.auth-login-cred-error {
    margin: 0.75rem 0 0;
    padding: 0;
    text-align: left;
    font-family: var(--font-main);
    font-size: 0.9rem;
    line-height: 1.4;
    color: #ffcdd2;
}

.auth-login-cred-error[hidden] {
    display: none;
}

.auth-alert {
    font-family: var(--font-main);
    font-size: 0.9rem;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.08);
}

.auth-alert.is-error {
    border-color: #e57373;
    color: #ffcdd2;
}

.auth-alert.is-success {
    border-color: rgb(0, 0, 255);
    color: rgb(0, 0, 255);
}

.auth-alert[hidden] {
    display: none;
}
