directly on the code.
<style> *{ /*in real development, don't be so lazy!*/margin:0;padding:0;List-style:None; }. out{width:200px;Height:200px;Background-color:#607D8B;Display:Flex;Align-items:Center;margin:0 Auto;position:relative; }. Inner{Border-left:1px solid #8BC34A;width:0;Height:282px;Transform:Rotate (45deg);-ms-transform:Rotate (45deg);-moz-transform:Rotate (45deg);-webkit-transform:Rotate (45deg);-o-transform:Rotate (45deg);Display:Inline-block;position:Absolute;Z-index:1;Top:-41px; Left:100px; }. txt{Display:Block;Line-height:30px;Z-index:999;width:150px;Height:150px;margin:Auto;position:relative;Background-color:#607D8B;font-size:30px;Color:#fff; } </style></Head><Body><Divclass= "Out"> <spanclass= "inner"></span> <spanclass= "txt">A piece of text, very late only then only then only then only then only then only then</span></Div></Body>
As follows:
Use CSS3 transform:rotate (xxdeg) to draw diagonal lines