*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
}

body {
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
}

input,
button,
textarea,
select {
    font: inherit;
}

@keyframes show {

    0%{
        transform: translateY(-500px);
        opacity: 0;
    }

    100%{
        transform: translateY(0px);
        opacity: 1;
    }
    
}

:root {
    /* Primary */
    --blue: hsl(246, 80%, 60%);
    --work: hsl(15, 100%, 70%);
    --play: hsl(195, 74%, 62%);
    --study: hsl(348, 100%, 68%);
    --exercise: hsl(145, 58%, 55%);
    --social: hsl(264, 64%, 52%);
    --self: hsl(43, 84%, 65%);

    /* Neutral */
    --very-dark-blue: hsl(226, 43%, 10%);
    --dark-blue: hsl(235, 46%, 20%);
    --neutral-blue: hsl(235, 45%, 61%);
    --light-blue: hsl(236, 100%, 87%);
    --white: hsl(255, 100%, 100%);
}

html {
    height: 100%;
    background: var(--very-dark-blue);
}

body {
    height: 100%;
    font: normal 1.125rem/1 "Rubik";
}

main {
    height: 100%;
}

.cards {
    height: 100%;
    display: flex;
    flex-direction: column;
}

.cards__list {
    max-width: 1110px;
    width: calc(100% - 2 * 1rem);
    margin: auto;
    padding-block: 5rem;
    padding-inline: 0;
    display: grid;
    gap: 1.5rem;
}

.cards__list--item {
    list-style: none;
    border-radius: 1rem;
    position: relative;
    overflow: hidden;
}

.profile {
    background: var(--dark-blue);
    border-radius: 1rem;
    display: flex;
    flex-direction: column;
    animation: show 0.3s ease;
}

.profile__content {
    padding: 2.25rem 2rem;
    display: flex;
    align-items: center;
    column-gap: 1.25rem;
    border-radius: 1rem;
    background: var(--blue);
}

.profile__image {
    border: 3px solid var(--white);
    border-radius: 100%;
}

.report {
    font: normal 0.9375rem/1 "Rubik";
    color: var(--light-blue);
}

.username {
    margin-top: 0.25rem;
    font: 300 1.5rem / normal "Rubik";
    color: var(--white);
}

.buttons {
    padding: 1.5rem;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    justify-content: space-around;
    padding-block: 1.5rem;
}

.buttons__time {
    padding: 0;
    margin: 0;
    background: none;
    border: none;
    line-height: normal;
    color: var(--neutral-blue);
}

.icon {
    position: absolute;
    z-index: 1;
}

.background {
    position: absolute;
    width: 100%;
    height: 100%;
    border-bottom-right-radius: 2rem;
    border-bottom-left-radius: 2rem;
}

.work {
    background: var(--work);
}

.work__card {
    animation: show 0.6s ease;
}

.work__icon {
    right: 1rem;
    top: -0.625rem;
}

.play {
    background: var(--play);
}

.play__card {
    animation: show 0.7s ease;
}

.play__icon {
    right: 1.25rem;
    top: -0.3125rem;
}

.study {
    background: var(--study);
}

.study__card {
    animation: show 0.8s ease;
}

.study__icon {
    right: 1rem;
    top: -0.375rem;
}

.exercise {
    background: var(--exercise);
}

.exercise__card {
    animation: show 0.9s ease;
}

.exercise__icon {
    right: 1rem;
    top: 0;
}

.social {
    background: var(--social);
}

.social__card {
    animation: show 1s ease;
}

.social__icon {
    right: 0.75rem;
    top: -1rem;
}

.self {
    background: var(--self);
}

.self__card {
    animation: show 1.1s ease;
}

.self__icon {
    right: 1rem;
    top: -0.75rem;
}

.content {
    margin-top: 2.375rem;
    padding: 1.75rem 1.5rem;
    background: var(--dark-blue);
    border-top-right-radius: 1rem;
    border-top-left-radius: 1rem;
    position: relative;
    z-index: 2;
}

.content:hover,
.content:focus {
    background: #33397A;
}

.label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.375rem;
}

.label h2 {
    font: 500 1.125rem / normal "Rubik";
    color: var(--white);
}

.stats {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.stats h3 {
    font: 300 2rem / normal "Rubik";
    color: var(--white);
}

.stats p {
    font: normal 0.9375rem / normal "Rubik";
    color: var(--light-blue);
}

footer {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
}

.attribution {
    font-size: 11px;
    text-align: center;
}
.attribution a {
    color: hsl(228, 45%, 44%);
}

.active {
    color: var(--white);
}

.buttons__time:hover,
.buttons__time:focus {
    color: var(--white);
}

.ellipses {
    color: var(--light-blue);
}

.ellipses:hover,
.ellipses:focus {
    color: var(--white);
}

@media screen and (min-width: 640px) {
    .cards__list {
        grid-template-columns: repeat(2, 1fr);
    }

    .profile {
        grid-column: 1 / -1;
    }
}

@media screen and (min-width: 768px) {
    .cards__list {
        grid-template-columns: repeat(3, 1fr);
    }

    .content {
        margin-top: 2.8125rem;
        padding: 1.875rem;
    }

    .label {
        margin-bottom: 1.5rem;
    }

    .stats {
        flex-direction: column;
        align-items: flex-start;
        row-gap: 0.5rem;
    }

    .stats h3 {
        font-size: 3.5rem;
        font-weight: 300;
    }
}

@media screen and (min-width: 1024px) {
    .cards__list {
        grid-template-columns: repeat(4, 1fr);
    }

    .profile {
        grid-column: auto;
        grid-row: 1 / 3;
    }

    .profile__content {
        flex-direction: column;
        align-items: flex-start;
        row-gap: 2.5rem;
    }

    .profile__image {
        width: 5rem;
        height: 5rem;
    }

    .profile__user {
        margin-bottom: 2.5rem;
    }

    .username {
        font-size: 2.5rem;
    }

    .stats {
        flex-direction: column;
        align-items: flex-start;
    }

    .buttons {
        padding: 1.625rem 2rem;
        grid-template-columns: 1fr;
        justify-items: start;
        height: 100%;
    }
}
