/* ==========================================================================
   PAGE SPECIFIC: PROFILE.CSS
   ========================================================================== */
.profile-dashboard {
    display: grid;
    grid-template-columns: 250px 1fr;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    margin-top: 20px;
    align-items: stretch;
    overflow: hidden;
}
.profile-sidebar {
    background: transparent;
    padding: 30px 0;
    border-right: 1px solid #f1f5f9;
}
.profile-main-content {
    background: transparent;
    padding: 30px;
    min-width: 0;
}

.profile-dashboard .profile-nav-link {
    display: block;
    padding: 12px 20px;
    margin: 4px 15px;
    color: #4b5563;
    text-decoration: none;
    font-weight: 700;
    border-radius: 8px;
    transition: all 0.2s ease;
    border: none;
}

.profile-dashboard .profile-nav-link:hover, 
.profile-dashboard .profile-nav-link:focus, 
.profile-dashboard .profile-nav-link:active {
    text-decoration: none;
}

.profile-dashboard .profile-nav-link[data-tab="overview"]:hover {
    background: #f1f5f9;
    color: var(--primary);
}
.profile-dashboard .profile-nav-link[data-tab="overview"].active {
    background: rgba(15, 23, 42, 0.05);
    color: var(--primary);
}

.profile-dashboard .profile-nav-link[data-tab="edit"]:hover {
    background: #f1f5f9;
    color: var(--primary);
}
.profile-dashboard .profile-nav-link[data-tab="edit"].active {
    background: rgba(15, 23, 42, 0.05);
    color: var(--primary);
}

.profile-dashboard .profile-nav-link[data-tab="security"] {
    color: #ea580c;
}
.profile-dashboard .profile-nav-link[data-tab="security"]:hover {
    background: rgba(234, 88, 12, 0.05);
    color: #ea580c;
}
.profile-dashboard .profile-nav-link[data-tab="security"].active {
    background: rgba(234, 88, 12, 0.1);
    color: #ea580c;
}

.profile-minimal-header {
    background: #ffffff;
    border-bottom: 1px solid #e2e8f0;
}
.profile-minimal-logo {
    color: var(--dark);
}
.profile-minimal-back {
    background: #f8fafc;
    color: #4b5563;
    border: 1px solid #e2e8f0;
}
.profile-minimal-back:hover {
    background: #f1f5f9;
    color: var(--dark);
}

.profile-dashboard .profile-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    background: transparent;
    height: auto;
}
.profile-dashboard .profile-nav-link i {
    width: 20px;
    text-align: center;
    margin-right: 8px;
}
.profile-dashboard .logout-link {
    color: #dc2626;
    margin-top: 15px;
    border-top: 1px solid #f1f5f9;
    border-radius: 0;
    padding-top: 15px;
    margin-left: 0;
    margin-right: 0;
    padding-left: 35px;
}

img {
    -webkit-user-drag: none;
    -khtml-user-drag: none;
    -moz-user-drag: none;
    -o-user-drag: none;
    user-select: none;
    -webkit-user-select: none;
}

@media (max-width: 768px) {
    .page-container {
        padding: 0;
        margin: 0;
    }
    .profile-dashboard {
        display: grid;
        grid-template-columns: 1fr;
        gap: 0;
        margin: 0;
        padding: 0;
        border-radius: 0;
        box-shadow: none;
        overflow: visible;
    }
    .sidebar-profile-info,
    .profile-sidebar > div:first-child,
    .mobile-hidden {
        display: none;
        margin: 0;
        padding: 0;
        height: 0;
        border: none;
        overflow: hidden;
    }
    
    .profile-sidebar {
        position: sticky;
        top: 58px;
        z-index: 900;
        height: auto;
        margin: 0;
        padding: 0;
        padding-top: 0;
        border-right: none;
        border-bottom: 1px solid #ffffff;
        background: #ffffff;
        box-shadow: 0 4px 15px rgba(0,0,0,0.05);
    }
    .profile-main-content {
        padding: 20px 15px;
    }
    
    .profile-dashboard .profile-nav {
        display: flex;
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
        padding: 0;
        margin: 0;
        gap: 5px;
        width: 100%;
    }
    .profile-dashboard .profile-nav::-webkit-scrollbar {
        display: none;
    }
    .profile-dashboard .profile-nav-link {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        white-space: nowrap;
        margin: 0;
        border-radius: 0;
        padding: 5px 2px;
        text-align: center;
        background: transparent;
        color: #64748b;
        font-size: 0.75rem;
    }
    .profile-dashboard .profile-nav-link i {
        margin-right: 0;
        margin-bottom: 4px;
        font-size: 1.1rem;
    }
    .profile-dashboard .logout-link {
        border-top: none;
        padding-top: 10px;
        padding-left: 2px;
        color: #dc2626;
    }
    
    .nav-text-long {
        display: none;
    }

    .profile-dashboard .profile-nav-link.active,
    .profile-dashboard .profile-nav-link[data-tab="overview"].active,
    .profile-dashboard .profile-nav-link[data-tab="edit"].active,
    .profile-dashboard .profile-nav-link[data-tab="security"].active {
        background: transparent;
        color: var(--primary);
    }
    .profile-dashboard .profile-nav-link[data-tab="security"] {
        color: #ea580c;
    }
    .profile-dashboard .profile-nav-link[data-tab="security"].active {
        color: #ea580c;
    }
    
    .profile-display-name {
        font-size: 1.5rem;
    }
    
    .profile-section-title {
        font-size: 1.3rem;
    }
}

.profile-section-title {
    font-size: 1.8rem; 
    font-family: 'Playfair Display', serif; 
    margin-bottom: 25px; 
    color: var(--dark); 
    border-bottom: 2px solid #f1f5f9; 
    padding-bottom: 10px;
}

.profile-input {
    width: 100%; 
    padding: 12px; 
    border: 1px solid #cbd5e1; 
    border-radius: 6px;
    background: #fff;
    transition: border-color 0.2s;
}
.profile-input:focus {
    outline: none;
    border-color: var(--primary);
}
.profile-input:disabled {
    background: #f8fafc; 
    color: #64748b; 
    cursor: not-allowed;
}

.profile-textarea {
    width: 100%; 
    padding: 12px; 
    border: 1px solid #cbd5e1; 
    border-radius: 6px; 
    resize: vertical;
}

.author-social-section {
    padding: 20px; 
    background: #f8fafc; 
    border-radius: 8px; 
    border-left: 4px solid var(--primary);
}
.author-social-title {
    margin-bottom: 15px; 
    font-size: 1rem; 
    color: var(--dark);
}
.author-social-subtitle {
    font-size: 0.8rem; 
    font-weight: 400; 
    color: var(--gray);
}

.danger-zone-box {
    margin-top: 50px; 
    padding: 25px; 
    border: 1px solid #ef4444; 
    border-radius: 12px; 
    background-color: #fef2f2; 
    text-align: left;
}
.danger-zone-title {
    color: #b91c1c; 
    margin-bottom: 10px; 
    font-size: 1.3rem;
}
.danger-zone-text {
    color: #991b1b; 
    margin-bottom: 20px;
}
.btn-outline-danger {
    background-color: transparent; 
    color: #dc2626; 
    border: 2px solid #dc2626; 
    padding: 10px 20px; 
    border-radius: 6px; 
    font-weight: 700; 
    cursor: pointer; 
    transition: all 0.2s;
}
.btn-outline-danger:hover {
    background-color: #dc2626; 
    color: white;
}

.delete-modal-overlay {
    position: fixed; 
    top: 0; 
    left: 0; 
    width: 100%; 
    height: 100%; 
    background: rgba(0,0,0,0.5); 
    z-index: 9999; 
    justify-content: center; 
    align-items: center;
}
.delete-modal-content {
    background: white; 
    padding: 30px; 
    border-radius: 12px; 
    width: 90%; 
    max-width: 450px; 
    box-shadow: 0 10px 25px rgba(0,0,0,0.2); 
    text-align: left;
}
.delete-modal-title {
    color: #b91c1c; 
    margin-bottom: 15px; 
    font-size: 1.4rem;
}
.delete-modal-text {
    margin-bottom: 20px; 
    color: #4b5563; 
    font-size: 0.95rem; 
    line-height: 1.5;
}
.delete-modal-label {
    display: block; 
    font-weight: 700; 
    margin-bottom: 5px; 
    color: #374151;
}
.delete-modal-actions {
    display: flex; 
    justify-content: flex-end; 
    gap: 10px;
}
.btn-cancel {
    padding: 10px 15px; 
    background: #e5e7eb; 
    color: #374151; 
    border: none; 
    border-radius: 6px; 
    cursor: pointer; 
    font-weight: 700;
}
.btn-cancel:hover { background: #d1d5db; }
.btn-danger {
    padding: 10px 15px; 
    background: #dc2626; 
    color: white; 
    border: none; 
    border-radius: 6px; 
    cursor: pointer; 
    font-weight: 700;
}
.btn-danger:hover { background: #b91c1c; }

.overview-wrapper {
    display: flex; 
    flex-direction: column; 
    align-items: center; 
    text-align: center; 
    margin-bottom: 30px;
}
.profile-img-container {
    margin-bottom: 15px;
    position: relative;
}
.profile-avatar {
    width: 120px; 
    height: 120px; 
    object-fit: cover; 
    border: 4px solid var(--primary); 
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}
.profile-display-name {
    font-size: 2.2rem; 
    color: var(--dark); 
    margin-bottom: 5px;
}
.profile-email-badge {
    color: var(--gray); 
    font-size: 1.1rem; 
    background: var(--accent); 
    padding: 5px 15px; 
    border-radius: 20px; 
    display: inline-block;
}
.profile-social-links {
    margin-top: 15px; 
    display: flex; 
    gap: 15px; 
    justify-content: center;
}
.social-icon-tw {
    color: #1da1f2; 
    font-size: 1.5rem;
}
.social-icon-li {
    color: #0077b5; 
    font-size: 1.5rem;
}

.profile-bio-card {
    background: #f8fafc; 
    padding: 25px; 
    border-radius: 12px; 
    margin-bottom: 20px; 
    border-left: 5px solid var(--primary); 
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); 
    text-align: left;
}
.profile-bio-title {
    margin-bottom: 10px; 
    font-size: 1.2rem; 
    color: var(--dark);
}
.profile-bio-text {
    color: #475569; 
    font-size: 1.05rem; 
    line-height: 1.6;
}

.profile-member-date {
    background: #f8fafc; 
    padding: 15px 25px; 
    border-radius: 12px; 
    margin-bottom: 30px; 
    text-align: center; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}
.profile-member-text {
    font-size: 0.95rem; 
    color: var(--gray);
}

.profile-container-max {
    max-width: 1000px;
}
.sidebar-info-box {
    text-align: center;
    padding-bottom: 20px;
    border-bottom: 1px solid #ffffff;
    margin-bottom: 15px;
}
.sidebar-avatar-img {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid var(--primary);
    margin-bottom: 10px;
}
.sidebar-name-text {
    margin: 0;
    font-size: 1.1rem;
    color: var(--dark);
}
.sidebar-role-text {
    margin: 5px 0 0;
    font-size: 0.8rem;
    color: var(--gray);
    text-transform: uppercase;
    letter-spacing: 1px;
}
.profile-loading-state {
    text-align: center;
    padding: 40px;
}
.profile-loading-icon {
    font-size: 2rem;
    color: var(--primary);
}
.profile-loading-text {
    margin-top: 10px;
}
.profile-form-label {
    font-weight: 700;
}
.edit-profile-preview-wrapper {
    width: 100px;
    height: 100px;
    border-radius: 50%;
    overflow: hidden;
    margin-bottom: 15px;
    border: 2px dashed #cbd5e1;
}
.edit-profile-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.bio-counter-text {
    text-align: right;
    font-size: 0.8rem;
    color: #64748b;
    margin-top: 4px;
}
.profile-form-group {
    margin-bottom: 15px;
}
.profile-submit-btn {
    margin-top: 25px;
    width: auto;
    padding: 12px 30px;
    font-size: 1rem;
    border-radius: 30px;
}
.security-form-container {
    margin-bottom: 40px;
}
.security-helper-text {
    margin-bottom: 20px;
    color: #64748b;
    font-size: 0.95rem;
}
.password-input-wrapper {
    position: relative;
}
.password-toggle-btn {
    position: absolute;
    right: 10px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: #64748b;
    cursor: pointer;
}
.security-confirm-group {
    margin-bottom: 20px;
}
.delete-input-group {
    margin-bottom: 15px;
}
.delete-input-group-large {
    margin-bottom: 20px;
}
.required-asterisk {
    color: red;
}
.delete-sudo-helper {
    font-size: 0.85rem;
    color: #6b7280;
    margin-bottom: 8px;
}
.sudo-strong-text {
    color: #111;
}
.delete-error-msg {
    color: #dc2626;
    font-size: 0.9rem;
    margin-bottom: 15px;
}
.profile-bio-empty {
    font-style: italic;
    color: var(--gray);
}
.profile-avatar.avatar-writer {
    border-radius: 8px;
}
.profile-avatar.avatar-regular {
    border-radius: 50%;
}

