#content.has-results {
    #splash {
        height: 150px;
        width: calc(351px / 2);
        transition: width 500ms ease-in-out, height 500ms ease-in-out;
    }

    &>:first-child {
        flex: 0;
        transition: flex 500ms ease-in-out;
    }
}

#splash {
    transition: width 500ms ease-in-out, height 500ms ease-in-out;
}

form#search {
    width: 50%;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 1em;
    margin-block: 1em;
    margin: 0 auto;

    :is(input, button) {
        font-size: larger;
    }

    input[type="submit"] {
        grid-column: 2;
    }
}

#search-box {
    grid-column: 1;
}

@keyframes FadeInResults {
    0% {
        opacity: 0;
        translate: 5em 0;
    }

    100% {
        opacity: 1;
        translate: 0em 0;
    }
}

@keyframes FadeOutResults {
    0% {
        opacity: 1;
        translate: 0em 0;
    }

    100% {
        opacity: 0;
        translate: -3em 0;
    }
}

#results {
    padding: 0 1em;

    >i {
        text-align: center;
        width: 100%;
        display: block;
    }

    .preview {
        border: 1px solid grey;
        border-radius: 0.5em;
        padding: 0.5em 1em;
    }

    ul {
        list-style-type: none;
        padding-inline-start: 0;
    }

    li {
        @for $i from 1 through 25 {
            &:nth-child(#{$i}) {
                animation-delay: #{($i - 1) * 50}ms !important;
            }
        }

        display: grid;
        grid-template-columns: 18px 1fr;
        gap: 0.25em;

        img {
            grid-column: 1;
            margin-top: 2px;
        }

        a {
            grid-column: 2;
            font-size: larger;
            color: inherit;
            text-decoration: none;
            line-height: 1.0;

            >em {
                font-size: small;
                color: #555;
                font-style: normal;
            }

            &:hover>em {
                text-decoration: underline;
            }
        }

        div {
            grid-column: 2;
            // grid-row: 2;
        }

        details, .description {
            grid-column: 2;
            // grid-row: 3;
        }

        blockquote.description {
            font-size: smaller;
            margin-block: 0 0;
            margin-inline: 0;
            padding-inline: 1em;
        }
    }

    &.htmx-swapping li {
        animation: FadeOutResults 250ms cubic-bezier(1, 0, 1, 1);
        animation-fill-mode: both;
    }

    &:not(.htmx-swapping) li {
        animation: FadeInResults 750ms cubic-bezier(0, 0, 0, 1);
        animation-fill-mode: both;
    }

    li+li {
        margin-top: 1em;
    }

    .scores {
        b.pill {
            font-weight: 400;
        }
        .score {
            font-family: sans-serif;
            font-variant: small-caps;
            font-size: smaller;
        }
    }

    .snip {
        color: grey;
        font-style: italic;
        text-align: center;
        width: fit-content;
        margin: 0 auto;
        font-size: smaller;
    
        &:before {
            content: '';
            width: 100%;
            position: absolute;
            left: 0;
            right: 0;
            bottom: 1.1em;
            z-index: -2;
            border-bottom: 1px dashed color-mix(in srgb, grey 75%, transparent);
        }
    
        &:after {
            content: '';
            width: 2.5em;
            position: absolute;
            left: calc(50% - 1.25em);
            bottom: 1.1em;
            z-index: -1;
            border-bottom: 1px solid white;
        }
    }

    .snipped {
        box-shadow: inset 0 -20px 20px -20px rgba(0, 0, 0, 0.5);
        position: relative;
    }

    .preview {
        background-color: rgb(244, 236, 216);
        color: rgb(91, 70, 54);
        font-family: Georgia, "Times New Roman", serif;
        line-height: 1.5em;
    
        mark {
            background-color: rgba(0, 97, 224, 0.3);
        }
    
        img {
            max-width: 50%;
            display: block;
            margin: 0.25em 1em;
            margin-right: 0;
            float: right;
            box-shadow: 0 0 0.5em rgba(0, 0, 0, 0.5);
        }
    }
}
