.custom_checkbox {
    display: inline-flex;
    align-items: center;
    cursor: pointer;
    user-select: none;
    font-size: 14px;
    margin: 0;
    --checkbox-bg: var(--color-bg-primary);              /* 체크된 아이콘 색상 */
    --checkbox-border: var(--color-input-border);             /* 기본 테두리 색 */
    --checkbox-unchecked-bg: transparent;       /* 체크 안 된 상태 배경 */
    --checkbox-unchecked-border: var(--color-input-border);
}

.custom_checkbox input[type="checkbox"] {
    display: none;
}

.circle_checkmark,
.square_checkmark {
    position: relative;
    display: inline-block;
    width: 19px;
    height: 19px;
    background-color: var(--checkbox-unchecked-bg);
    border: 1px solid var(--checkbox-border);
    overflow: hidden;
}

.circle_checkmark {
    border-radius: 50%;
}
.square_checkmark {
    border-radius: 4px;
}

.custom_checkbox input[type="checkbox"]:checked + .circle_checkmark,
.custom_checkbox input[type="checkbox"]:checked + .square_checkmark {
    border: none;
}

.custom_checkbox input[type="checkbox"]:checked + .circle_checkmark::after,
.custom_checkbox input[type="checkbox"]:checked + .square_checkmark::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    transform: translate(-50%, -50%);
    background-color: var(--checkbox-bg);
    mask-repeat: no-repeat;
    mask-position: center;
    mask-size: contain;
    -webkit-mask-repeat: no-repeat;
    -webkit-mask-position: center;
    -webkit-mask-size: contain;
}

.custom_checkbox input[type="checkbox"]:disabled + .circle_checkmark,
.custom_checkbox input[type="checkbox"]:disabled + .square_checkmark {
    background-color: var(--color-bg-disabled);
    border-color: var(--color-border-disabled);
}

.custom_checkbox input[type="checkbox"]:checked:disabled + .circle_checkmark::after,
.custom_checkbox input[type="checkbox"]:checked:disabled + .square_checkmark::after {
    background-color: var(--color-icon-disabled);
}

.custom_checkbox input[type="checkbox"]:checked + .circle_checkmark::after {
    mask-image: url('../../img/svg/ic_cmm_check_circle_filled.svg');
    -webkit-mask-image: url('../../img/svg/ic_cmm_check_circle_filled.svg');
}

.custom_checkbox input[type="checkbox"]:checked + .square_checkmark::after {
    mask-image: url('../../img/svg/ic_cmm_check_square_filled.svg');
    -webkit-mask-image: url('../../img/svg/ic_cmm_check_square_filled.svg');
}

.circle_checkmark.small,
.square_checkmark.small {
    width: 16px;
    height: 16px;
}
.circle_checkmark.medium,
.square_checkmark.medium {
    width: 20px;
    height: 20px;
}
.circle_checkmark.large,
.square_checkmark.large {
    width: 24px;
    height: 24px;
}

.checkbox_text {
    font-family: Pretendard, sans-serif;
    font-size: 0.875rem;
    font-weight: 400;
    line-height: 140%;
    letter-spacing: -0.2px;
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    word-break: break-all;
    max-width: 90%;
    min-width: 0;
    margin-left: 8px;
}

.checkbox-group {
    display: flex;
    flex-wrap: wrap;
}

.checkbox-group.vertical {
    flex-direction: row;
}

.checkbox-group.horizontal {
    flex-direction: column;
}