/*
 Theme Name:   GeneratePress Child
 Theme URI:    https://generatepress.com
 Description:  Default GeneratePress child theme
 Author:       Tom Usborne
 Author URI:   https://tomusborne.com
 Template:     generatepress
 Version:      0.1
*/
/* Target the rankmath table of content */

.wp-block-rank-math-toc-block {
    position: relative;
    background-color: #fff !important;
    box-shadow: 0 10px 12px rgb(0 0 0 / 0.16) !important;
    font-size: 18px;
}
.wp-block-rank-math-toc-block h2 {
    font-size: 1.5em;
    background: var(--surface-10);
    border-bottom: 4px dotted var(--surface-0);
    margin: 0;
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 15px;
    justify-content: space-between;
    font-weight: 600;
    padding: 10px;
}
.wp-block-rank-math-toc-block h2:after {
    content: "+";
    display: inline-block;
    font-weight: 700;
    font-size: 16px;
    color: #000;
    margin-right: 8px;
    line-height: 1;
}
.wp-block-rank-math-toc-block nav {
    background: var(--surface-0);
    padding: 0 10px;
    max-height: 300px;
    overflow: visible;
    overflow-y: auto;
    transition: max-height 0.3s ease;
}
.wp-block-rank-math-toc-block input:checked + h2 ~ nav {
    max-height: 300px;
    overflow-y: visible;
}
.wp-block-rank-math-toc-block > nav {
    padding: 0 10px;
}
