/* ==========================================================================
   Block: Simple Top Of Table (acf/top-of)
   ========================================================================== */

.top-of-table {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px 16px;
    justify-items: center;
    width: 100%;
    box-sizing: border-box;
}

/* Center lone last item when odd count on mobile */
.top-of-table__cell:last-child:nth-child(odd) {
    grid-column: 1 / -1;
    justify-self: center;
}

/* Desktop: single row, centred */
@media (min-width: 768px) {
    .top-of-table {
        display: flex;
        flex-wrap: nowrap;
        justify-content: center;
        gap: 100px;
    }

    .top-of-table__cell:last-child:nth-child(odd) {
        /* Reset mobile grid override */
        grid-column: unset;
        justify-self: unset;
    }

    .top-of-table--style-2.top-of-table {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
        gap: 24px 16px;
        justify-items: start;
        width: 100%;
        box-sizing: border-box;
        height: 100%;
    }

    .top-of-table--style-2 .top-of-table__cell:last-child:nth-child(odd) {
        grid-column: 1 / -1;
        justify-self: center;
    }
}

/* ---------- Cell ---------- */

.top-of-table__cell {
    text-align: center;
    min-width: 0;
    width: 100%;
}


.top-of-table__cell {
    position: relative;
}

.top-of-table__cell:not(:last-child)::after {
    content: url('data:image/svg+xml,<svg width="1" height="55" viewBox="0 0 1 55" fill="none" xmlns="http://www.w3.org/2000/svg"><path opacity="0.65" d="M0.5 0L0.5 55" stroke="url(%23paint0_linear_8751_1044)"/><defs><linearGradient id="paint0_linear_8751_1044" x1="1" y1="0" x2="1" y2="55" gradientUnits="userSpaceOnUse"><stop stop-color="%23191919" stop-opacity="0"/><stop offset="0.5" stop-color="%23191919" stop-opacity="0.5"/><stop offset="1" stop-color="%23191919" stop-opacity="0"/></linearGradient></defs></svg>');
    position: absolute;
    top: 0;
    bottom: 0;
    right: -12px;
    bottom: 0;
    width: 1px;
}

.top-of-table__cell:nth-child(even)::after {
    display: none;
}



.top-of-table--style-2 .top-of-table__cell:nth-child(even) {
    /* border-left: 1px solid;
    border-image: linear-gradient(180deg, rgba(25, 25, 25, 0.4) 0%, rgba(25, 25, 25, 0) 100%) 1;
    padding-left: 30px; */
}

@media (min-width: 768px) {
    .top-of-table__cell {
        width: auto;
    }

    .top-of-table__cell:nth-child(even)::after {
        display: block;
    }

    .top-of-table__cell:not(:last-child)::after {
        right: -50px;
    }

    .top-of-table--style-2 .top-of-table__cell {
        /* border-left: 1px solid;
        border-image: linear-gradient(180deg, rgba(25, 25, 25, 0.4) 0%, rgba(25, 25, 25, 0) 100%) 1;
        padding-left: 30px; */
    }
}

.top-of-table--style-2 .top-of-table__cell::after {
    display: none;
}

/* ---------- Numbers row ---------- */

.top-of-table__numbers {
    display: flex;
    align-items: baseline;
    justify-content: center;
    white-space: nowrap;

    color: #191919;
    /* letter-spacing: -.04em; */
}

.top-of-table__separator {
    display: inline-block;
    margin: 0 2px;
    font-weight: 400;
}

.top-of-table__number--left {
    font-size: var(--wp--preset--font-size--x-60);
    
    font-weight: 400;
    line-height: 90%;
    letter-spacing: -4%;

    margin-right: .2em;
}

.top-of-table__separator,
.top-of-table__number--right {
    font-size: var(--wp--preset--font-size--x-32);
    
    font-weight: 400;
    line-height: 90%;
    letter-spacing: -4%;
}

.top-of-table--style-2 .top-of-table__number--left {
    font-weight: 400;
    font-size: var(--wp--preset--font-size--x-60);
    line-height: 90%;
    /* letter-spacing: -4%; */
}

.top-of-table--style-2 .top-of-table__separator,
.top-of-table--style-2 .top-of-table__number--right {
    font-weight: 400;
    font-size: clamp(18px, 13.64px + 1.36vw, 30px);
    line-height: 90%;
    /* letter-spacing: -4%; */
    opacity: 1;
}

.top-of-table--style-2 .top-of-table__text {
    font-weight: 500;
    font-size: var(--wp--preset--font-size--x-24);
    line-height: 120%;

}

@media (min-width: 768px) {
    .top-of-table--style-2 .top-of-table__numbers {
        justify-content: start;
    }
}

/* ---------- Text row ---------- */

.top-of-table__text {
    font-weight: 500;

    margin-top: 8px;
    font-size: 14px;
}

@media (min-width: 768px) {
    .top-of-table__text {
        font-size: 18px;
    }
}

/* ---------- Editor placeholder ---------- */

.top-of-table__placeholder {
    padding: 24px;
    text-align: center;
    font-style: italic;
    opacity: 0.6;
}