Edit This Code:
<!DOCTYPE html>
<html>
<head>
<style>
div {
    margin: 20px;
    padding: 10px;
    width: 300px;
    height: 100px;
    border: 1px solid black;
    outline: 1px solid red;
    /* Move the outline 15px away from the border */
    outline-offset: 15px;
}

</style>
</head>
<body>

<p><b>Note:</b> Internet Explorer does not support the outline-offset property.</p>

<div>This div has an outline 15px outside the border edge.</div>

</body>
</html>


Result:
Try it Yourself - © w3schools.com
Privacy Policy