/* Google Font 및 기본 스타일 설정 */
:root {
    --primary-color: #00a8e8;
    --background-start: #1d2b4a;
    --background-end: #0f182a;
    --form-background: rgba(22, 33, 62, 0.6);
    --text-color: #f0f0f0;
    --input-border-color: rgba(0, 168, 232, 0.4);
    --input-focus-color: var(--primary-color);
}

body {
    font-family: 'Poppins', sans-serif;
    color: var(--text-color);
    margin: 0;
    height: 100vh;
    overflow: hidden; /* 스크롤 방지 */
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, var(--background-start), var(--background-end));
}

/* 움직이는 배경 애니메이션 */
.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><path d="M10 10 L90 90 M90 10 L10 90" stroke-width="0.1" stroke="rgba(0, 168, 232, 0.2)"/></svg>');
    animation: move-background 180s linear infinite;
}

@keyframes move-background {
    from { background-position: 0 0; }
    to { background-position: 1000px 1000px; }
}


/* 로그인 컨테이너 (글래스모피즘 효과) */
.login-container {
    background: var(--form-background);
    padding: 2.5rem 3rem;
    border-radius: 15px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px); /* Safari 브라우저 호환성 */
    box-shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    text-align: center;
    width: 100%;
    max-width: 420px;
    box-sizing: border-box;
    z-index: 1;
    transition: transform 0.3s ease;
}

.login-container:hover {
    transform: translateY(-5px);
}

/* 헤더 (로고 아이콘 + WAAP) */
.login-header {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-bottom: 0.5rem;
}

.logo-icon {
    width: 32px;
    height: 32px;
    color: var(--primary-color);
}

.login-header h1 {
    font-size: 2.8rem;
    font-weight: 700;
    margin: 0;
    color: var(--text-color);
    letter-spacing: 2px;
}

.subtitle {
    font-size: 0.9rem;
    font-weight: 300;
    margin-bottom: 2.5rem;
    color: #a0a0a0;
}

/* 입력 필드 (아이콘 포함) */
.input-group {
    position: relative;
    margin-bottom: 1.5rem;
}

.input-icon {
    position: absolute;
    left: 15px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--input-border-color);
    transition: color 0.3s ease;
}

.input-icon svg {
    width: 20px;
    height: 20px;
}

.input-group input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem; /* 아이콘 공간 확보 */
    background: transparent;
    border: 1px solid var(--input-border-color);
    border-radius: 8px;
    color: var(--text-color);
    font-size: 1rem;
    box-sizing: border-box;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.input-group input::placeholder {
    color: #888;
}

.input-group input:focus {
    outline: none;
    border-color: var(--input-focus-color);
    box-shadow: 0 0 10px rgba(0, 168, 232, 0.5);
}

.input-group input:focus + .input-icon {
    color: var(--input-focus-color);
}

/* 로그인 버튼 */
.login-button {
    width: 100%;
    padding: 1rem;
    background: var(--primary-color);
    border: none;
    border-radius: 8px;
    color: #fff;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
}

.login-button:hover {
    background-color: #0091ca;
    transform: translateY(-2px);
}

.login-button:active {
    transform: translateY(0);
}

/* --- 커스텀 체크박스 스타일 추가 --- */
.options-group {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    margin-bottom: 1.5rem;
    text-align: left;
}

/* 기본 HTML 체크박스는 접근성을 유지한 채로 숨깁니다. */
.options-group input[type="checkbox"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.options-group label {
    position: relative;
    padding-left: 30px;
    font-size: 0.9rem;
    color: #a0a0a0;
    cursor: pointer;
    user-select: none;
}

.options-group label::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 18px;
    height: 18px;
    border: 1px solid var(--input-border-color);
    background: transparent;
    border-radius: 4px;
    transition: all 0.2s ease;
}

/* 탭 키로 포커스 시 시각적 효과 추가 */
.options-group input[type="checkbox"]:focus-visible + label::before {
    box-shadow: 0 0 8px var(--input-focus-color);
    border-color: var(--input-focus-color);
}

.options-group input[type="checkbox"]:checked + label::before {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
}

.options-group label::after {
    content: '';
    position: absolute;
    left: 6px;
    top: 3px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    opacity: 0;
    transition: opacity 0.2s ease;
}

.options-group input[type="checkbox"]:checked + label::after {
    opacity: 1;
}


/* 반응형 웹 디자인: 모바일 환경 */
@media (max-width: 500px) {
    .login-container {
        max-width: 90%;
        padding: 2rem;
    }

    .login-header h1 {
        font-size: 2.2rem;
    }
}

