.container {
    background-color: #333;
    position: relative;
    width: 100%;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    background-position: center;
    background-size: cover;
}
 
.text {
    position:  absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    text-align: center;
    color: white;
}

.ratio16x9 {
    padding-top: 56.25%; /* 16:9 Aspect Ratio */
}

.ratio4x3 {
    padding-top: 75%; /* 4:3 Aspect Ratio */
}

.ratio3x2 {
    padding-top: 66.66%; /* 3:2 Aspect Ratio */
}

.ratio8x5 {
    padding-top: 62.5%; /* 8:5 Aspect Ratio */
}

.ratio2x1 {
    padding-top: 50%; /* 4:3 Aspect Ratio */    
}

.rounded {
    border-radius: 4px;
}