/* 회원가입 페이지 (register) 전용 스타일 */

/* 메인 컨테이너 */
.reg-container {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem;
}

/* 회원가입 카드 */
.reg-card {
    width: 100%;
    max-width: 480px;
    background: var(--surface-color);
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-xl);
    padding: 3rem 2.5rem;
    box-shadow:
        0 20px 60px rgba(30, 64, 175, 0.08),
        0 8px 24px rgba(0, 0, 0, 0.06);
    position: relative;
    overflow: hidden;
    animation: regCardIn 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

@keyframes regCardIn {
    from {
        opacity: 0;
        transform: translateY(20px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.reg-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg,
        var(--primary-color) 0%,
        var(--primary-medium) 50%,
        var(--accent-color) 100%);
}

/* 로고 섹션 */
.reg-logo-section {
    text-align: center;
    margin-bottom: 2rem;
}

.reg-logo {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.625rem;
    text-decoration: none;
    margin-bottom: 0.75rem;
}

.reg-logo-icon {
    width: 3rem;
    height: 3rem;
    object-fit: contain;
}

.reg-logo-text {
    font-size: 1.75rem;
    font-weight: 900;
    background: linear-gradient(135deg,
        var(--primary-color) 0%,
        var(--primary-medium) 50%,
        var(--accent-color) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -0.02em;
}

.reg-subtitle {
    font-size: 0.9375rem;
    color: var(--gray-500);
    font-weight: 500;
    margin-top: 0.5rem;
}

/* 폼 그룹 */
.reg-form-group {
    margin-bottom: 1.125rem;
}

.reg-form-label {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--gray-700);
    margin-bottom: 0.5rem;
    letter-spacing: -0.01em;
}

.reg-required {
    color: var(--danger-color);
    font-size: 0.75rem;
    font-weight: 700;
}

.reg-optional {
    color: var(--gray-400);
    font-size: 0.75rem;
    font-weight: 500;
}

/* 입력 필드 래퍼 */
.reg-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.reg-input-wrapper > i {
    position: absolute;
    left: 1rem;
    color: var(--gray-400);
    font-size: 1rem;
    transition: color 0.2s ease;
    pointer-events: none;
    z-index: 1;
}

.reg-input-wrapper:focus-within > i {
    color: var(--primary-color);
}

.reg-input {
    width: 100%;
    padding: 0.875rem 2.75rem 0.875rem 2.75rem;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius-lg);
    font-size: 0.9375rem;
    font-family: 'Noto Sans KR', sans-serif;
    font-weight: 500;
    color: var(--gray-800);
    background: var(--gray-50);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
}

.reg-input::placeholder {
    color: var(--gray-400);
    font-weight: 400;
}

.reg-input:hover {
    border-color: var(--gray-400);
    background: var(--surface-color);
}

.reg-input:focus {
    border-color: var(--primary-color);
    background: var(--surface-color);
    box-shadow:
        0 0 0 3px rgba(59, 130, 246, 0.12),
        0 2px 8px rgba(59, 130, 246, 0.08);
}

/* 필드 힌트 */
.reg-field-hint {
    display: block;
    margin-top: 0.375rem;
    font-size: 0.8125rem;
    font-weight: 500;
    color: var(--danger-color);
}

/* 입력 필드 유효성 상태 */
.reg-input-error .reg-input {
    border-color: var(--danger-color);
    background: #fff8f8;
}

.reg-input-error .reg-input:focus {
    border-color: var(--danger-color);
    box-shadow:
        0 0 0 3px rgba(220, 38, 38, 0.1),
        0 2px 8px rgba(220, 38, 38, 0.06);
}

.reg-input-error.reg-input-wrapper > i {
    color: var(--danger-color);
}

.reg-input-success .reg-input {
    border-color: var(--success-color);
}

.reg-input-success .reg-input:focus {
    border-color: var(--success-color);
    box-shadow:
        0 0 0 3px rgba(5, 150, 105, 0.1),
        0 2px 8px rgba(5, 150, 105, 0.06);
}

.reg-input-success.reg-input-wrapper > i {
    color: var(--success-color);
}

/* 비밀번호 토글 */
.reg-pw-toggle {
    position: absolute;
    right: 0.75rem;
    background: none;
    border: none;
    color: var(--gray-400);
    cursor: pointer;
    padding: 0.375rem;
    font-size: 1rem;
    transition: color 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.reg-pw-toggle:hover {
    color: var(--gray-600);
}

/* 약관 동의 섹션 */
.reg-agreement-section {
    margin-top: 1.5rem;
    margin-bottom: 1.25rem;
    border: 1px solid var(--gray-200);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

/* 전체 동의 */
.reg-agree-all {
    display: flex;
    align-items: center;
    gap: 0.625rem;
    padding: 0.875rem 1rem;
    background: var(--gray-50);
    border-bottom: 1px solid var(--gray-200);
    cursor: pointer;
    transition: background 0.2s ease;
    user-select: none;
}

.reg-agree-all:hover {
    background: var(--gray-100);
}

.reg-agree-all-label {
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--gray-800);
    letter-spacing: -0.01em;
}

/* 개별 약관 항목 */
.reg-agree-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 1rem;
    cursor: pointer;
    transition: background 0.2s ease;
    user-select: none;
}

.reg-agree-item:not(:last-child) {
    border-bottom: 1px solid var(--gray-100);
}

.reg-agree-item:hover {
    background: var(--gray-50);
}

.reg-agree-item-left {
    display: flex;
    align-items: center;
    gap: 0.625rem;
}

.reg-agree-item-label {
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--gray-700);
}

.reg-agree-item-label .reg-required {
    margin-left: 0.25rem;
}

.reg-agree-item-link {
    font-size: 0.8125rem;
    color: var(--gray-400);
    text-decoration: none;
    transition: color 0.2s ease;
    flex-shrink: 0;
    padding: 0.25rem;
}

.reg-agree-item-link:hover {
    color: var(--primary-color);
}

/* 커스텀 체크박스 */
.reg-checkbox {
    display: none;
}

.reg-checkbox-custom {
    width: 1.25rem;
    height: 1.25rem;
    border: 1.5px solid var(--gray-300);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    flex-shrink: 0;
    background: var(--surface-color);
}

.reg-checkbox-custom i {
    font-size: 0.625rem;
    color: var(--white);
    opacity: 0;
    transform: scale(0.5);
    transition: all 0.2s ease;
}

.reg-checkbox:checked + .reg-checkbox-custom {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.reg-checkbox:checked + .reg-checkbox-custom i {
    opacity: 1;
    transform: scale(1);
}

/* 회원가입 버튼 */
.reg-submit-btn {
    width: 100%;
    padding: 0.9375rem 1.5rem;
    background: linear-gradient(135deg,
        var(--primary-color) 0%,
        var(--accent-color) 100%);
    color: var(--white);
    border: none;
    border-radius: var(--radius-lg);
    font-size: 1rem;
    font-weight: 700;
    font-family: 'Noto Sans KR', sans-serif;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: -0.01em;
}

.reg-submit-btn:hover {
    opacity: 0.9;
    box-shadow: 0 4px 12px rgba(30, 64, 175, 0.2);
}

.reg-submit-btn:active {
    opacity: 1;
    box-shadow: none;
}

.reg-submit-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

/* 구분선 */
.reg-divider {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin: 1.5rem 0;
}

.reg-divider::before,
.reg-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gray-200);
}

.reg-divider-text {
    font-size: 0.8125rem;
    color: var(--gray-400);
    font-weight: 500;
    white-space: nowrap;
}

/* 로그인 이동 버튼 */
.reg-login-btn {
    width: 100%;
    padding: 0.875rem 1.5rem;
    background: var(--surface-color);
    color: var(--primary-color);
    border: 1.5px solid rgba(59, 130, 246, 0.3);
    border-radius: var(--radius-lg);
    font-size: 0.9375rem;
    font-weight: 600;
    font-family: 'Noto Sans KR', sans-serif;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    letter-spacing: -0.01em;
}

.reg-login-btn:hover {
    background: rgba(59, 130, 246, 0.06);
    border-color: var(--primary-color);
    box-shadow:
        0 4px 12px rgba(59, 130, 246, 0.1),
        0 2px 6px rgba(0, 0, 0, 0.04);
}

.reg-login-btn:active {
    background: rgba(59, 130, 246, 0.1);
}

/* 배경 장식 */
.reg-bg-decoration {
    position: absolute;
    pointer-events: none;
    opacity: 0.04;
}

.reg-bg-circle-1 {
    width: 300px;
    height: 300px;
    border-radius: 50%;
    background: var(--primary-color);
    top: -100px;
    right: -80px;
}

.reg-bg-circle-2 {
    width: 200px;
    height: 200px;
    border-radius: 50%;
    background: var(--accent-color);
    bottom: -60px;
    left: -60px;
}

/* ============================================
   반응형 디자인
   ============================================ */

/* 1200px 이하 */
@media (max-width: 1200px) {
    .reg-container {
        padding: 1.75rem;
    }

    .reg-card {
        max-width: 460px;
        padding: 2.75rem 2.25rem;
    }
}

/* 900px 이하 */
@media (max-width: 900px) {
    .reg-container {
        padding: 1.5rem;
    }

    .reg-card {
        max-width: 440px;
        padding: 2.5rem 2rem;
    }

    .reg-logo-icon {
        width: 2.75rem;
        height: 2.75rem;
    }

    .reg-logo-text {
        font-size: 1.625rem;
    }

    .reg-subtitle {
        font-size: 0.875rem;
    }
}

/* 768px 이하 */
@media (max-width: 768px) {
    .reg-container {
        padding: 2rem;
    }

    .reg-card {
        max-width: 100%;
        padding: 2.25rem 1.75rem;
        border-radius: var(--radius-lg);
    }

    .reg-logo-section {
        margin-bottom: 1.75rem;
    }

    .reg-logo-icon {
        width: 2.5rem;
        height: 2.5rem;
    }

    .reg-logo-text {
        font-size: 1.5rem;
    }

    .reg-form-label {
        font-size: 0.8125rem;
    }

    .reg-input {
        padding: 0.8125rem 2.5rem 0.8125rem 2.5rem;
        font-size: 0.875rem;
    }

    .reg-input-wrapper > i {
        font-size: 0.9375rem;
    }

    .reg-submit-btn {
        padding: 0.875rem 1.25rem;
        font-size: 0.9375rem;
    }

    .reg-login-btn {
        padding: 0.8125rem 1.25rem;
        font-size: 0.875rem;
    }

    .reg-divider {
        margin: 1.25rem 0;
    }

    .reg-agree-all {
        padding: 0.75rem 0.875rem;
    }

    .reg-agree-all-label {
        font-size: 0.875rem;
    }

    .reg-agree-item {
        padding: 0.625rem 0.875rem;
    }

    .reg-agree-item-label {
        font-size: 0.8125rem;
    }

    .reg-agree-item-link {
        font-size: 0.75rem;
    }

    .reg-field-hint {
        font-size: 0.75rem;
        margin-top: 0.3125rem;
    }
}

/* 480px 이하 */
@media (max-width: 480px) {
    .reg-container {
        padding: 1.5rem;
        align-items: flex-start;
    }

    .reg-card {
        padding: 2rem 1.5rem;
        box-shadow:
            0 10px 30px rgba(30, 64, 175, 0.06),
            0 4px 12px rgba(0, 0, 0, 0.04);
    }

    .reg-logo-section {
        margin-bottom: 1.5rem;
    }

    .reg-logo-icon {
        width: 2.25rem;
        height: 2.25rem;
    }

    .reg-logo-text {
        font-size: 1.375rem;
    }

    .reg-subtitle {
        font-size: 0.8125rem;
    }

    .reg-form-group {
        margin-bottom: 0.875rem;
    }

    .reg-form-label {
        font-size: 0.8125rem;
        margin-bottom: 0.375rem;
    }

    .reg-input {
        padding: 0.75rem 2.375rem 0.75rem 2.375rem;
        font-size: 0.875rem;
        border-radius: var(--radius-md);
    }

    .reg-input-wrapper > i {
        left: 0.875rem;
        font-size: 0.875rem;
    }

    .reg-submit-btn {
        padding: 0.8125rem 1rem;
        font-size: 0.875rem;
        border-radius: var(--radius-md);
    }

    .reg-divider {
        margin: 1rem 0;
    }

    .reg-divider-text {
        font-size: 0.75rem;
    }

    .reg-login-btn {
        padding: 0.75rem 1rem;
        font-size: 0.8125rem;
        border-radius: var(--radius-md);
    }

    .reg-agreement-section {
        margin-top: 1.25rem;
        margin-bottom: 1rem;
    }

    .reg-agree-all {
        padding: 0.6875rem 0.75rem;
    }

    .reg-agree-all-label {
        font-size: 0.8125rem;
    }

    .reg-agree-item {
        padding: 0.5625rem 0.75rem;
    }

    .reg-agree-item-label {
        font-size: 0.75rem;
    }

    .reg-agree-item-link {
        font-size: 0.6875rem;
    }

    .reg-checkbox-custom {
        width: 1.125rem;
        height: 1.125rem;
    }

    .reg-agree-item-label .reg-required {
        margin-left: 0.125rem;
    }

    .reg-field-hint {
        font-size: 0.6875rem;
        margin-top: 0.25rem;
    }
}
