//Block Styles
@import 'variables';
@import 'functions';

.is-style-widget-title {
    position: relative;
    margin-top: 0;
    margin-bottom: .625rem;
    padding-bottom: 0.5rem;
    font-size: 1.5rem;

    &:before {
        content: "";
        position: absolute;
        bottom: 0;
        height: 4px;
        width: 40px;
        background-color: var(--accent);
    }
    &:after {

        content: "";
        position: absolute;
        bottom: 0;
        height: 4px;
        left: 40px;
        width: 40px;
        background-color: #ddd;
    }
}

.is-style-section-title {
    position: relative;
    padding-bottom: 0.5rem;
    margin-bottom: 0.75rem;

    &:after {
        content: "";
        position: absolute;
        bottom: 0;
        left: 0;
        height: 1px;
        width: 100%;
        background-color: rgba(0,0,0,0.1);
    }
}

.is-style-prop-table {

    th,
    td {
        padding: 0.25em 0.625rem;
        border: 0;
    }

    table {

        thead {
            background-color: var(--accent);
            color: var(--footer-text);
        }

        tbody {

            tr {

                &:nth-child(2n+1) {
                    background-color: #f5f5f5;
                }

                td {
                    border: 0;

                    &:first-child {
                        font-weight: 700;
                    }
                }
            }
        }

        tfoot {

            td {
                padding: 0.5rem 0.6em;
            }
        }
    }
}

.is-style-two-col-list {
    grid-template-columns: 1fr 1fr;
}

.is-style-three-col-list {
    grid-template-columns: 1fr 1fr 1fr;
}

.is-style-two-col-list,
.is-style-three-col-list {
    display: grid;
    column-gap: 1.25rem;
    list-style: none;
    padding: 0;
    margin: 0;

    li {
        display: flex;
        align-items: flex-start;
        margin-bottom: 0.625rem;

        &:before {
            content: url("data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIyMCIgaGVpZ2h0PSIyMCIgdmlld0JveD0iMCAwIDIwIDIwIj48dGl0bGU+QXNzZXQgMTwvdGl0bGU+PHBhdGggZD0iTTEwLDBBMTAsMTAsMCwxLDAsMjAsMTAsMTAsMTAsMCwwLDAsMTAsMFptMCwxOGE4LDgsMCwxLDEsOC04QTgsOCwwLDAsMSwxMCwxOFpNMTQuNTksNS41OCw4LDEyLjE3LDUuNDEsOS41OSw0LDExbDQsNCw4LThaIiBmaWxsPSIjMGNiYzJkIi8+PC9zdmc+");
            margin-right: 0.5rem;
            display: flex;
            align-items: center;
            justify-content: center;
            margin-top: 0.125rem;
        }
    }
}

//Reach Out - Contact Form styling
.is-style-reach-out {

    input
    :not([type="radio"])
    :not([type="checkbox"])
    :not([type="submit"]),
    textarea {
        padding: 0.5rem;
    }
}

// Sticky Column
.is-style-sticky {
    position: sticky;
    position: -webkit-sticky;
    height: fit-content;
    top: 1rem;

    body.admin-bar & {
        top: 3.875rem;

        @media (min-width: 48.875rem) {
            top: 3rem;
        }
    }
}
