* {
    box-sizing: border-box;
}

body {
    font-family: sans-serif;
    background: #eee;
    padding: 30px;
}

button {
    background: tomato;
    color: #fff;
    border: 0;
    border-radius: 5px;
    padding: 10px 20px;
    margin: 0 auto;
    display: block;
}

#app {
    max-width: 800px;
    margin: 20px auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.element-with-ball {
    background: #fff;
    height: 200px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    min-height: 80px;
    border-radius: 4px;
    position: relative;
    grid-column: span 3;
}

.element-with-ball .ball {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: tomato;
    position: absolute;
    left: 100px;
    top: 100px;
}

.element-with-ball .rect {
    position: absolute;
    left: 50%;
    top: 0;
    height: 100%;
    margin-left: -25px;
    --c1: rgba(0,0,0,0.1);
    --c2: rgba(0,0,0,0.3);
    background: linear-gradient(
            45deg,
            var(--c1) 0%, var(--c1) 25%,
            var(--c2) 25%, var(--c2) 50%,
            var(--c1) 50%, var(--c1) 75%,
            var(--c2) 75%, var(--c2) 100%
    );
    background-size: 6px 6px;
    width: 50px;
    border: 1px solid #222;
    border-top: 0;
    border-bottom: 0;
}

.element {
    background: #fff;
    height: 100px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    min-height: 80px;
    border-radius: 4px;
    position: relative;
    padding: 20px;
}

.red {
    background: red;
}

.off {
    background: #fff;
}