:root {
    --red: hsl(14, 86%, 42%);
    --green: hsl(159, 69%, 38%);

    --rose50: hsl(20, 50%, 98%);
    --rose100: hsl(13, 31%, 94%);
    --rose300: hsl(14, 25%, 72%);
    --rose400: hsl(7, 20%, 60%);
    --rose500: hsl(12, 20%, 44%);
    --rose900: hsl(14, 65%, 9%);

}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    min-height: 100vh;
    font-family: 'Red Hat Text', sans-serif;
    background-color: var(--rose50);
}

.container {
    max-width: 1200px;
    width: 100%;
    height: 80%;
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 2rem 0;
}

.container .dessert-title {
    font-size: 1.75rem;
    color: var(--rose900);
    margin-bottom: 0.5rem;
}

.desserts {
    display: grid;
    grid-template-columns: repeat(3, 200px);
    gap: 0.5rem;
    width: 75%;
}

.dessert-card {
    display: flex;
    flex-direction: column;
}

.dessert-card.border img {
    border: 1px solid var(--red);
}   

.dessert-card .dessert-image {
    border-radius: 4px;
}

.dessert-card .cart-btn {
    width: 60%;
    height: 30px;
    position: relative;
    left: 20%;
    bottom: 5%;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background-color: white;
    border: 1px solid var(--rose400);
    color: var(--rose900);
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    font-family: 'Red Hat Text', sans-serif;
}

.dessert-card .cart-btn-control {
    width: 60%;
    height: 30px;
    position: relative;
    left: 20%;
    bottom: 5%;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: space-around;
    background-color: var(--red);
    border: none;
    color: white;
    font-weight: 500;
    border-radius: 50px;
    cursor: pointer;
    font-family: 'Red Hat Text', sans-serif;
}

.cart-btn-control > div {
    width: 15%;
    height: 60%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid white;
    border-radius: 50%;
}

.dessert-card .cart-btn img {
    width: 15%;
}

.dessert-card p {
    font-size: 0.65rem;
    color: var(--rose300);
    margin-bottom: 0.125rem;
}

.dessert-card h2 {
    font-size: 0.7rem;
    color: var(--rose900);
    margin-bottom: 0.125rem;
}

.dessert-card h4 {
    font-size: 0.65rem;
    color: var(--red);
}

.cart {
    display: flex;
    flex-direction: column;
    background-color: white;
    height: 20%;
    width: 25%;
    padding: 1.25rem;
    border-radius: 5px;
}

.cart .cart-information-h1 {
    font-size: 1.25rem;
    color: var(--red);
}

.cart img {
    width: 50%;
    padding: 1rem;
    align-self: center;
}

.cart .cart-information-p {
    font-size: 0.75rem;
    align-self: center;
    color: var(--rose500);
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.item-description {
    display: flex;
    flex-direction: column;
    align-items: start;
    gap: 0.25rem;
    margin: 0.5rem 0;
}

.cart-item h5 {
    font-size: 0.65rem;
    font-weight: 600;
}

.item-price {
    display: flex;
    gap: 0.5rem;
}

.item-price h6 {
    font-size: 0.65rem;
    font-weight: 500;
}

.item-price h6:nth-of-type(1) {
    color: var(--red);
}

.item-price h6:nth-of-type(2) {
    color: var(--rose300);
}

.cart-item button {
    width: 12.5px;
    height: 12.5px;
    background-color: transparent;
    border: 1.5px solid var(--rose300);
    border-radius: 50%;
    cursor: pointer;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cart-item button img {
    width: 75%;
    height: 75%;
    padding: 0;
}

.cart-confirm {
    margin-top: 0.75rem;
    display: flex;
    flex-direction: column;
}

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

.cart-price p {
    font-size: 0.55rem;
    color: var(--rose900);
}

.cart-price h1 {
    font-size: 1rem;
}

.carbon-neutral {
    width: 100%;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--rose50);
    gap: 0.25rem;
    margin: 0.75rem 0;
}

.carbon-neutral p {
    font-size: 0.6rem;
    color: var(--rose900);
}

.carbon-neutral img {
    width: 5%;
    padding: 0;
}

.cart-confirm button {
    width: 100%;
    height: 30px;
    border: none;
    border-radius: 50px;
    font-size: 0.65rem;
    background-color: var(--red);
    color: white;
    font-family: 'Red Hat Text';
    cursor: pointer;
}

.order-confirm {
    visibility: hidden;
    display: flex;
    flex-direction: column;
    position: fixed;
    width: 35%;
    height: 75%;
    background-color: white;
    padding: 1.5rem;
    border-radius: 10px;
    top: 10%;
}

.order-confirm.show {
    visibility: visible;
}

.order-confirm > img:first-of-type {
    width: 30px;
}

.order-confirm > h1:first-of-type {
    font-size: 1.75rem;
    color: var(--rose900);
}

.order-confirm > p:nth-of-type(1) {
    font-size: 0.75rem;
    color: var(--rose400);
}

.order-confirm .new-order {
    width: 100%;
    height: 30px;
    border: none;
    border-radius: 50px;
    background-color: var(--red);
    font-size: 0.75rem;
    color: white;
    margin-top: 1rem;
    cursor: pointer;
    flex-shrink: 0;
}

.order-list {
    width: 100%;
    margin-top: 0.75rem;
    background-color: var(--rose50);
    padding: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    overflow-y: auto;
    flex: 1;
}

.order-description {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.order-description img {
    width: 40px;
}

.order-description p {
    font-size: 0.7rem;
}

.order-information {
    gap: 0.5rem;
    display: flex;
}

.order-details {
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 0.25rem;
}

.order-details p {
    font-size: 0.65rem;
}

.order-details > p:nth-of-type(1) {
    font-weight: 600;
}

.order-details > div {
    display: flex;
    gap: 0.5rem;
}

.order-details > div p:nth-of-type(1) {
    color: var(--red);
    font-weight: 600;
}

.order-details > div p:nth-of-type(2) {
    color: var(--rose400);
}

.order-total {
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-top: 1px solid var(--rose100);
    padding-top: 0.5rem;
}

.order-total p {
    font-size: 0.65rem;
    color: var(--rose900);
}

.order-total h1 {
    font-size: 1.25rem;
}

@media (max-width: 768px) {
    .desserts {
        display: grid;
        grid-template-columns: repeat(2, 200px);
        gap: 0.5rem;
        width: 70%;
    }

    .cart {
        width: 30%;
    }
}

@media (max-width: 500px) {
    .container {
        flex-direction: column;
    }

    .container > div  {
        width: 100%;
        display: flex;
        flex-direction: column;
    }

    .desserts {
        display: grid;
        grid-template-columns: repeat(1, 80%);
        grid-auto-rows: 250px;
        width: 100%;
        justify-content: center;
    }

    .dessert-title {
        width: 80%;
        display: flex;
        align-self: center;
    }

    .dessert-image {
        height: 60%;
        border-radius: 8px !important;
        object-fit: cover;
    }

    .dessert-card .cart-btn, .dessert-card .cart-btn-control {
        width: 40%;
        height: 30px;
        left: 30%;
        font-size: 0.65rem;
        gap: 0.25rem;
    }

    .dessert-card .cart-btn img {
        width: 15px;
    }

    .cart-btn-control > div {
        width: 12px;
        height: 12px;
        border-radius: 50%;
    }

    .cart-btn-control > div img {
        width: 80%;
    }

    .cart {
        width: 80%;
        align-self: center;
    }

    .order-confirm {
        width: 100%;
        height: 100%;
        top: 5%;
    }
}