/**
 * NanoNside - 회원가입 페이지 스타일
 */

/* 회원가입 페이지 레이아웃 */
.auth-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: #f9fafb;
    padding: 1rem;
}

.auth-card {
    background-color: white;
    border-radius: 1rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    padding: 2rem;
    width: 100%;
    max-width: 400px;
}

.register-card {
    max-width: 480px;
}

/* 로고 */
.auth-logo {
    text-align: center;
    margin-bottom: 1.5rem;
}

.auth-logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: #f59e0b;
    text-decoration: none;
    display: inline-block;
}

.auth-logo-text:hover {
    color: #d97706;
}

/* 스텝 인디케이터 */
.register-steps {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 2rem;
    padding: 0 1rem;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.step-number {
    width: 2rem;
    height: 2rem;
    border-radius: 50%;
    background-color: #e5e7eb;
    color: #9ca3af;
    font-size: 0.875rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.step.active .step-number {
    background-color: #f59e0b;
    color: white;
}

.step.completed .step-number {
    background-color: #10b981;
    color: white;
}

.step-label {
    font-size: 0.75rem;
    color: #9ca3af;
    font-weight: 500;
    white-space: nowrap;
}

.step.active .step-label {
    color: #f59e0b;
}

.step.completed .step-label {
    color: #10b981;
}

.step-line {
    flex: 1;
    height: 2px;
    background-color: #e5e7eb;
    margin: 0 0.5rem;
    margin-bottom: 1.5rem;
    max-width: 60px;
}

.step-line.completed {
    background-color: #10b981;
}

/* 타이틀 */
.auth-title {
    text-align: center;
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1.5rem;
}

/* 에러 메시지 박스 */
.auth-error {
    background-color: #fee2e2;
    border: 1px solid #fecaca;
    border-radius: 0.5rem;
    padding: 0.75rem 1rem;
    margin-bottom: 1rem;
    color: #991b1b;
    font-size: 0.875rem;
    line-height: 1.5;
}

.auth-error.hidden {
    display: none;
}

/* 약관 동의 */
.terms-all {
    background-color: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 0.5rem;
    padding: 1rem;
    margin-bottom: 1rem;
}

.terms-all-label {
    font-weight: 600;
    font-size: 1rem;
}

.terms-list {
    margin-bottom: 1.5rem;
}

.terms-item {
    border-bottom: 1px solid #e5e7eb;
    padding: 0.75rem 0;
}

.terms-item:last-child {
    border-bottom: none;
}

.terms-item-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.terms-badge {
    display: inline-block;
    padding: 0.125rem 0.5rem;
    border-radius: 9999px;
    font-size: 0.75rem;
    font-weight: 500;
    margin-right: 0.5rem;
}

.terms-badge.required {
    background-color: #fee2e2;
    color: #991b1b;
}

.terms-badge.optional {
    background-color: #e5e7eb;
    color: #6b7280;
}

.terms-view-btn {
    background: none;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s;
}

.terms-view-btn:hover {
    background-color: #f3f4f6;
    border-color: #9ca3af;
}

/* 약관 모달 */
.terms-modal {
    max-width: 600px;
}

.terms-content {
    max-height: 400px;
    overflow-y: auto;
    line-height: 1.8;
    font-size: 0.875rem;
    color: #374151;
    white-space: pre-line;
}

/* 체크박스 */
.checkbox-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
    width: 1.25rem;
    height: 1.25rem;
    accent-color: #f59e0b;
    cursor: pointer;
}

.checkbox-label {
    font-size: 0.875rem;
    color: #374151;
}

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

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: #374151;
    margin-bottom: 0.5rem;
}

.form-label .required {
    color: #ef4444;
}

.form-input {
    width: 100%;
    border: 1px solid #d1d5db;
    border-radius: 0.5rem;
    padding: 0.625rem 1rem;
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.form-input:focus {
    border-color: #f59e0b;
    box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.15);
    outline: none;
}

.form-input::placeholder {
    color: #9ca3af;
}

.form-input.error {
    border-color: #ef4444;
}

.form-input.error:focus {
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.15);
}

.form-input.success {
    border-color: #10b981;
}

.form-input:disabled {
    background-color: #f3f4f6;
    cursor: not-allowed;
}

/* 입력 필드 + 버튼 */
.input-with-button {
    display: flex;
    gap: 0.5rem;
}

.input-with-button .form-input {
    flex: 1;
}

/* 폼 메시지 */
.form-message {
    font-size: 0.75rem;
    margin-top: 0.375rem;
    min-height: 1rem;
}

.form-message.error {
    color: #ef4444;
}

.form-message.success {
    color: #10b981;
}

/* 비밀번호 강도 */
.password-strength {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.375rem;
}

.strength-bar {
    flex: 1;
    height: 4px;
    background-color: #e5e7eb;
    border-radius: 2px;
    overflow: hidden;
}

.strength-fill {
    height: 100%;
    width: 0;
    transition: width 0.3s, background-color 0.3s;
    border-radius: 2px;
}

.strength-fill.weak {
    width: 20%;
    background-color: #ef4444;
}

.strength-fill.fair {
    width: 40%;
    background-color: #ef4444;
}

.strength-fill.medium {
    width: 60%;
    background-color: #f59e0b;
}

.strength-fill.strong {
    width: 80%;
    background-color: #10b981;
}

.strength-fill.very-strong {
    width: 100%;
    background-color: #10b981;
}

.strength-text {
    font-size: 0.75rem;
    min-width: 60px;
    color: #6b7280;
}

.strength-text.weak {
    color: #ef4444;
}

.strength-text.fair {
    color: #ef4444;
}

.strength-text.medium {
    color: #f59e0b;
}

.strength-text.strong {
    color: #10b981;
}

.strength-text.very-strong {
    color: #10b981;
}

/* 인증번호 섹션 */
.verify-section {
    margin-top: 0.75rem;
}

.verify-section.hidden {
    display: none;
}

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

.verify-timer {
    position: absolute;
    right: 70px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 0.875rem;
    color: #ef4444;
    font-weight: 500;
}

/* 버튼 */
.btn-primary {
    background-color: #f59e0b;
    color: white;
    font-weight: 500;
    padding: 0.75rem 1.5rem;
    border-radius: 0.5rem;
    border: none;
    cursor: pointer;
    transition: background-color 0.2s;
    font-size: 1rem;
    text-decoration: none;
    display: inline-block;
    text-align: center;
}

.btn-primary:hover {
    background-color: #d97706;
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-primary.w-full {
    width: 100%;
}

.btn-secondary {
    background-color: #f3f4f6;
    color: #374151;
    font-weight: 500;
    padding: 0.625rem 1rem;
    border-radius: 0.5rem;
    border: 1px solid #d1d5db;
    cursor: pointer;
    transition: background-color 0.2s;
    font-size: 0.875rem;
    white-space: nowrap;
}

.btn-secondary:hover {
    background-color: #e5e7eb;
}

.btn-secondary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.btn-sm {
    padding: 0.5rem 0.75rem;
    font-size: 0.75rem;
}

/* 하단 링크 */
.auth-links {
    text-align: center;
    margin-top: 1.5rem;
    font-size: 0.875rem;
    color: #6b7280;
}

.auth-links a {
    color: #f59e0b;
    text-decoration: none;
    transition: color 0.2s;
    margin-left: 0.25rem;
}

.auth-links a:hover {
    color: #d97706;
    text-decoration: underline;
}

/* 가입완료 페이지 */
.register-complete {
    text-align: center;
    padding: 1rem 0;
}

.complete-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    height: 80px;
    background-color: #d1fae5;
    border-radius: 50%;
    color: #10b981;
    margin-bottom: 1.5rem;
}

.complete-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 1rem;
}

.complete-message {
    font-size: 0.875rem;
    color: #6b7280;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.complete-message strong {
    color: #1f2937;
}

/* 모달 */
.modal-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 50;
    padding: 1rem;
}

.modal-overlay.hidden {
    display: none;
}

.modal-content {
    background-color: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #e5e7eb;
}

.modal-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1f2937;
}

.modal-close {
    padding: 0.5rem;
    color: #6b7280;
    cursor: pointer;
    background: none;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.375rem;
    transition: background-color 0.2s;
}

.modal-close:hover {
    background-color: #f3f4f6;
    color: #1f2937;
}

.modal-body {
    flex: 1;
    overflow-y: auto;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    margin-top: 1.5rem;
    padding-top: 1rem;
    border-top: 1px solid #e5e7eb;
}

/* 반응형 */
@media (max-width: 640px) {
    .auth-container {
        padding: 0.5rem;
        align-items: flex-start;
        padding-top: 2rem;
    }

    .auth-card {
        padding: 1.5rem;
        border-radius: 0.75rem;
    }

    .register-card {
        max-width: 100%;
    }

    .auth-logo-text {
        font-size: 1.25rem;
    }

    .auth-title {
        font-size: 1.125rem;
    }

    .register-steps {
        padding: 0;
    }

    .step-label {
        font-size: 0.625rem;
    }

    .step-line {
        max-width: 40px;
    }

    .input-with-button {
        flex-direction: column;
    }

    .input-with-button .btn-secondary {
        width: 100%;
    }

    .verify-timer {
        right: 10px;
    }

    .verify-input-group .form-input {
        padding-right: 60px;
    }
}
