Wearable inertial measurement units (IMUs) provide a practical and objective approach for gait assessment in clinical populations. Although several handcrafted gait features have been proposed, these features may not fully capture the multidimensional signal characteristics associated with different pathological gait patterns. This study proposes a digital biomarker called Embedding-Distance Gait Biomarker (EDGB) based on supervised contrastive representation learning of wearable IMU signals. A compact multi-input convolutional neural network is developed to encode raw acceleration, angular velocity, and their temporal derivatives into a 32-dimensional latent representation. Class-specific prototypes are computed from the training embeddings of healthy, neurological, and orthopedic participants. The proposed EDGB is then derived from the distances between each trial embedding and the learned group prototypes. The proposed architecture is evaluated on the publicly available Voisard clinical gait dataset using a subject-level split, with 20% of participants held out for testing to prevent leakage across repeated trials. On unseen test subjects, the proposed biomarker distinguished healthy from neurological, healthy from orthopedic, and neurological from orthopedic gait patterns with AUCs of 90.59%, 88.47%, and 99.50%, respectively. The biomarker also demonstrated a large group effect, with clinical category explaining 71% of its variance. Reliability analysis showed significant consistency across repeated trials, with an ICC (2,1) of 0.82, indicating that most variability reflected between-subject differences rather than within-subject trial-to-trial fluctuations.