/**
 * HC Login Pro - Profile Module CSS
 * 
 * @package HC_Login_Pro
 */

/* 프로필 페이지 기본 스타일 */
.hc-profile-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-profile-container {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
}

.hc-profile-form-wrapper {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

/* 아바타 스타일 */
.hc-profile-avatar-section {
    text-align: center;
    margin-bottom: 30px;
}

.hc-profile-avatar-wrapper {
    display: inline-block;
    position: relative;
}

.hc-profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    position: relative;
    cursor: pointer;
    border: 3px solid #1B9CFC;
    transition: all 0.3s ease;
    background: #f8fafc;
}

.hc-profile-avatar:hover {
    transform: scale(1.05);
    box-shadow: 0 10px 25px rgba(27, 156, 252, 0.3);
}

.hc-avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hc-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: 600;
    background: linear-gradient(135deg, #1B9CFC, #00D775);
    color: white;
}

.hc-avatar-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
    color: white;
}

.hc-profile-avatar:hover .hc-avatar-overlay {
    opacity: 1;
}

.hc-avatar-icon {
    font-size: 24px;
    margin-bottom: 5px;
}

.hc-avatar-text {
    font-size: 12px;
    font-weight: 500;
}

.hc-profile-avatar.uploading {
    opacity: 0.7;
    pointer-events: none;
}

.hc-profile-avatar.uploading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #ffffff;
    border-top: 2px solid transparent;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 제목 스타일 */
.hc-profile-title {
    font-size: 24px;
    font-weight: 600;
    text-align: center;
    margin: 0 0 30px 0;
}

/* 폼 그룹 스타일 */
.hc-profile-form-group {
    margin-bottom: 20px;
}

.hc-profile-form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    margin-bottom: 8px;
}

.hc-profile-form-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: #ffffff;
}

.hc-profile-form-input:focus {
    outline: none;
    border-color: #1B9CFC;
    box-shadow: 0 0 0 3px rgba(27, 156, 252, 0.1);
}

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

.hc-profile-form-input[readonly] {
    background-color: #f9fafb;
    color: #9ca3af;
    cursor: not-allowed;
}

.hc-profile-form-input[type="textarea"] {
    resize: vertical;
    min-height: 100px;
}

/* 공개/비공개 설정 스타일 */
.hc-profile-privacy-options {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.hc-privacy-option {
    display: flex;
    align-items: flex-start;
    padding: 15px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #ffffff;
}

.hc-privacy-option:hover {
    border-color: #1B9CFC;
    background: #f8fafc;
}

.hc-privacy-option input[type="radio"] {
    margin: 0 12px 0 0;
    margin-top: 2px;
}

.hc-privacy-option input[type="radio"]:checked + .hc-privacy-text {
    color: #1B9CFC;
    font-weight: 600;
}

.hc-privacy-text {
    font-size: 15px;
    font-weight: 500;
    line-height: 1.4;
    display: block;
}

.hc-privacy-option:has(input[type="radio"]:checked) {
    border-color: #1B9CFC;
    background: rgba(27, 156, 252, 0.05);
}

/* 버튼 스타일 */
.hc-profile-form-button {
    width: 100%;
    padding: 14px 20px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #4b5563;
    color: white;
    margin-bottom: 15px;
    border: 2px solid #4b5563;
}

.hc-profile-form-button:hover {
    background: #374151;
    border-color: #374151;
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(75, 85, 99, 0.3);
}

.hc-profile-form-button:active {
    transform: translateY(0);
}

.hc-profile-form-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

.hc-profile-form-button.active {
    background: linear-gradient(135deg, #1B9CFC, #00D775);
    border-color: #1B9CFC;
}

.hc-profile-form-button.active:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 25px rgba(27, 156, 252, 0.3);
}

/* 섹션 구분 */
.hc-profile-section {
    margin-bottom: 30px;
    padding-bottom: 30px;
    border-bottom: 1px solid #e5e7eb;
}

.hc-profile-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.hc-profile-section-title {
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 20px 0;
    padding-bottom: 10px;
    border-bottom: 2px solid #1B9CFC;
}

/* 메시지 스타일 */
.hc-profile-message {
    padding: 12px 16px;
    border-radius: 12px;
    margin-bottom: 20px;
    font-size: 14px;
    display: none;
}

.hc-profile-message.success {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
}

.hc-profile-message.error {
    background-color: #fee2e2;
    color: #991b1b;
    border: 1px solid #fecaca;
}

/* 모달 스타일 */
.hc-password-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.hc-password-modal.show {
    display: flex;
}

.hc-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(5px);
}

.hc-modal-container {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    padding: 0;
    max-width: 450px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px) scale(0.9);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

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

.hc-modal-title {
    font-size: 20px;
    font-weight: 600;
    margin: 0;
}

.hc-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #9ca3af;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

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

.hc-modal-body {
    padding: 30px;
}

.hc-modal-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.hc-modal-actions .hc-profile-form-button {
    flex: 1;
    margin-bottom: 0;
}

.hc-button-secondary {
    background: #6b7280 !important;
}

.hc-button-secondary:hover {
    background: #4b5563 !important;
    box-shadow: 0 10px 25px rgba(107, 114, 128, 0.3) !important;
}

/* 모달이 열렸을 때 body 스크롤 방지 */
body.modal-open {
    overflow: hidden;
}

/* 배경 스타일 */
.hc-profile-page.gradient-bg {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.hc-profile-page.solid-bg {
    background-color: #f8fafc;
}

.hc-profile-page.image-bg {
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* 템플릿별 스타일 */
.hc-profile-form-wrapper.hc-template-modern {
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
}

.hc-profile-form-wrapper.hc-template-elegant {
    border: 1px solid #e5e7eb;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.hc-profile-form-wrapper.hc-template-glass {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.hc-profile-form-wrapper.hc-template-dark {
    background: #1f2937;
    color: #f9fafb;
}

.hc-profile-form-wrapper.hc-template-dark .hc-profile-form-input {
    background: #374151;
    border-color: #4b5563;
    color: #f9fafb;
}

.hc-profile-form-wrapper.hc-template-dark .hc-profile-form-input::placeholder {
    color: #9ca3af;
}

/* 모바일 반응형 */
@media screen and (max-width: 768px) {
    .hc-profile-page {
        padding: 20px 0;
        margin: 0;
        width: 100%;
        min-height: 100vh;
        overflow-x: hidden;
        display: flex;
        align-items: center;
        justify-content: center;
    }
    
    .hc-profile-container {
        width: 100%;
        max-width: 100%;
        padding: 0 20px;
        margin: 0 auto;
        box-sizing: border-box;
    }
    
    .hc-profile-form-wrapper {
        width: 100%;
        max-width: 400px;
        margin: 20px auto;
        box-sizing: border-box;
        padding: 30px 25px;
    }
    
    .hc-modal-container {
        width: 95%;
        margin: 20px;
    }
    
    .hc-modal-header {
        padding: 20px 25px 15px;
    }
    
    .hc-modal-body {
        padding: 25px;
    }
    
    .hc-modal-actions {
        flex-direction: column;
    }
    
    .hc-privacy-option {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .hc-privacy-option input[type="radio"] {
        width: auto;
        margin-right: 0;
        margin-bottom: 8px;
    }
    
    /* iOS 자동 줌 방지 */
    input[type="text"],
    input[type="email"],
    input[type="password"],
    input[type="tel"] {
        font-size: 16px !important;
    }
}

/* 공개 프로필 스타일 */
.hc-public-profile-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.hc-public-profile-container {
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

.hc-public-profile-wrapper {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    padding: 40px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.hc-public-avatar-section {
    text-align: center;
    margin-bottom: 30px;
}

.hc-public-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    margin: 0 auto 20px;
    border: 3px solid #1B9CFC;
    background: #f8fafc;
}

.hc-public-avatar-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.hc-public-avatar-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: 600;
    background: linear-gradient(135deg, #1B9CFC, #00D775);
    color: white;
}

.hc-public-profile-title {
    font-size: 28px;
    font-weight: 700;
    text-align: center;
    margin: 0 0 10px 0;
}

.hc-public-profile-subtitle {
    font-size: 16px;
    text-align: center;
    margin: 0 0 30px 0;
}

.hc-public-profile-info {
    margin-bottom: 30px;
}

.hc-public-info-item {
    display: flex;
    align-items: flex-start;
    padding: 15px 0;
    border-bottom: 1px solid #e5e7eb;
}

.hc-public-info-item:last-child {
    border-bottom: none;
}

.hc-public-info-label {
    font-size: 14px;
    font-weight: 600;
    width: 100px;
    flex-shrink: 0;
    margin-right: 20px;
}

.hc-public-info-value {
    font-size: 16px;
    flex: 1;
    line-height: 1.5;
}

.hc-public-description {
    background: #f8fafc;
    padding: 20px;
    border-radius: 12px;
    margin-top: 20px;
    border-left: 4px solid #1B9CFC;
}

.hc-public-description-text {
    font-size: 16px;
    line-height: 1.6;
    margin: 0;
}

.hc-error-message {
    background: #fee2e2;
    color: #991b1b;
    padding: 20px;
    border-radius: 12px;
    text-align: center;
    font-size: 16px;
    border: 1px solid #fecaca;
} 