/* Certificate. */

.consultation:has(+ .certificate) {
    background-color: transparent;
}

.consultation + .certificate {
    --top: min(20vw, 400px);
}

.certificate {
    --top: 0px;
    position: relative;
}

.certificate .container {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;

    height: 100dvh;
    max-height: calc(100% - max(var(--section-gap), var(--top, 0px) - var(--section-gap)));
    padding-bottom: calc(var(--section-gap) * 1.4);
    z-index: 2;
}

.certificate-bg {
    position: relative;
    display: flex;
    justify-content: center;

    margin-top: calc(var(--top, 0) * -1);
    z-index: -1;
}

.certificate-bg img {
    min-width: 720px;
}

.certificate-bg:before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;

    height: 500px;
    background-image: linear-gradient(to bottom, var(--color-background), transparent);
    z-index: 1;
}

.certificate-content {
    display: flex;
    flex-direction: column;
    grid-gap: var(--i4);
}

.certificate-content .richText {
    max-width: 448px
}

/* Certificate. */

@media only screen and (max-width: 767px) {
    .certificate-button {
        width: 100%;
        text-align: center;
    }

    .certificate-bg img {
        min-width: 100%;
        margin: 0;
    }
}