/* DEFAULTS */

ul,
ol {
    padding-inline-start: 40px;
}


/* Entire style of landing page except for global elements */

.hero-image {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.hero-image img {
    width: auto;
    max-width: 100%;
    max-height: 400px;
    border-radius: var(--border-radius);
    float: right;
}

.hero-text>* {
    margin-bottom: calc(var(--spacing) / 2);
}

@media (max-width: 768px) {
    .hero-image {
        display: none;
    }
}


/* solution container */

.solution-container h2 {
    text-align: center;
    margin-bottom: var(--spacing);
}

.feature {
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: var(--horizontal-spacing);
}

.feature img {
    height: 75px;
    width: auto;
}

.solution-container h3 {
    text-align: center;
    margin: var(--spacing) 0;
}

.box-key-features {
    width: fit-content;
    margin: 0 auto;
    display: flex;
    flex-direction: row;
    gap: calc(var(--spacing) / 2);
}

.box-key-features img {
    height: 150px;
    width: auto;
}

@media (max-width: 768px) {
    .box-key-features {
        flex-direction: row;
    }
    .box-key-features img {
        height: 125px;
        width: min-content;
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .box-key-features {
        flex-direction: column;
    }
}


/* About container */

.about-container h2 {
    margin-bottom: calc(var(--spacing) / 2);
}

.about-container .item-details {
    display: flex;
    flex-direction: row;
    gap: var(--spacing);
    width: 90%;
    margin: 0 auto;
}

@media (max-width: 768px) {
    .about-container .item-details {
        flex-direction: column;
        align-items: center;
    }
    .about-container .item-details .item-image img {
        width: 75%;
        display: block;
        margin: 0 auto;
    }
}


/* gallery */

.gallery img {
    width: 100%;
    height: auto;
    border-radius: var(--border-radius);
}

/* On phones the shared grid-layout-4 collapses to a single column, which makes
 * the four product photos a very long stack. Keep the gallery as a 2x2 grid. */
@media (max-width: 480px) {
    .gallery.grid-layout-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}


/* Steps to become great in chrochet */

.steps {
    margin-top: var(--spacing);
    list-style-type: none;
    padding: 0;
}

.step {
    margin-bottom: calc(var(--spacing) / 2);
}

.step p {
    padding-left: 20px;
}

#how-to .image-container {
    height: fit-content;
}

#how-to .image-container img {
    width: auto;
    height: 100%;
    max-height: 500px;
    border-radius: var(--border-radius);
    display: block;
    margin: 0 auto;
}

@media (max-width: 768px) {
    #how-to .image-container {
        display: none;
    }
}


/* Contents of the box */

#contents-of-box .image-container {
    height: fit-content;
}

#contents-of-box .image-container img {
    width: auto;
    max-width: 100%;
    max-height: 500px;
    height: auto; /* the img now has width/height attributes (CLS); keep the ratio when max-width shrinks it */
    border-radius: var(--border-radius);
    display: block;
    margin: 0 auto;
}


/* Reviews section */

.reviews-description h2 {
    margin-bottom: calc(var(--spacing) / 2);
}

.reviews-description ul {
    margin-bottom: var(--spacing);
}

.review {
    margin-bottom: calc(var(--spacing) / 2);
}


/* Call to action */

.cta {
    text-align: center;
}

.cta p {
    margin: calc(var(--spacing) / 2) 0;
}

