aside.ribbon-banner { display: block; position: absolute; top: 50px; right: -120px; width: 400px; height: 50px; line-height: 50px; text-align: center; opacity: 0.7; transform: rotate(45deg); font-size: 24px; font-weight: 700; color: white; background-color: orange; border: 1px solid white; z-index: 500; } aside.ribbon-banner.student { display: block; position: absolute; top: 50px; right: -120px; width: 400px; height: 50px; line-height: 50px; text-align: center; opacity: 0.7; transform: rotate(45deg); font-size: 24px; font-weight: 700; color: white; background-color: #0ea53b; border: 1px solid white; z-index: 500; }