html,body{
    margin:0;
    padding:0;
    font-family: Arial, sans-serif;
    background-color: #212121;
}

.hero {
    background-color: crimson;
    color: aliceblue;
    text-align: center;
    padding: 50px 20px;
    position: relative; /* added so :before positions correctly */
}

.hero h1{
    margin: 0;
    font-size: 3rem;
}

.hero h2{
    margin: 1.7rem;
    font-size: 2rem;
    font-weight: normal;
    margin: 0;
}

.filter-nav {
    display: flex;
    justify-content: center;
    margin: 20px 0;
}

.filter-nav a {
    text-decoration: none;
    color: crimson;
    border: 2px solid crimson;
    padding: 10px 20px;
    margin: 0 10px;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.filter-nav .active{
    background-color:rgb(122, 2, 42);
    color:#fff;
}

.filter-nav .active:hover{
    background-color:rgb(122, 2, 42);
    cursor: default;
}
.filter-nav a:hover {
    background-color: rgb(238, 83, 83);
    color: white;
}

.animals{
    max-width: 700px;
    margin: 0 auto;
}
.animal-card {
   display: grid;
   grid-template-columns: 100%;
   background-color: #333;
   border-radius: 20px;
   overflow: hidden;
   margin-bottom:30px;
}

.animal-card-photo{
    order: 1;
    grid-row: 1;
    overflow: hidden;
}
.animal-card-photo img {
    width: 100%;
    border-radius: 10px;
    display: block;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease-in-out;
}

.animal-card:hover img {
    transform: rotate(20deg) scale(1.4);
}
.animal-card-text{
    padding: 20px 25px;
    color: aliceblue;
}

.animal-card-text h3 {
    margin: 0;
    padding: 0;
    font-weight: normal;
    font-size: 1.8rem;
}

.animal-card-text small{
    font-size: 0.9rem;
    color: #ccc;
}

.animal-card-text p{
    margin: .8rem 0 0 0;
    line-height: 1.5;
}

.primary-btn {
    display: inline-block;
    text-decoration: none;
    background-color: crimson;
    color: white;
    padding: 10px 15px;
    border-radius: 5px;
    margin-top: 15px;
    transition: background-color 0.3s;
}

.primary-btn:hover {
    background-color: rgb(238, 83, 83);
}

@media screen and (min-width:768px){
    .animal-card {
        grid-template-columns: 200px 1fr;
}

    .hero h1{
        font-size:6rem
    }

}