.slider{ background: url("../images/maxresdefault.jpg"); height: 100vh; background-size:cover; background-position: center; } .card-img-top{ width:100%; height:25vw; object-fit:cover; } a:hover{ color: black; }