/**
 * The following styles get applied both on the front of your site
 * and in the editor.
 *
 * Replace them with your own styles or remove the file completely.
 */

table.wp-block-tableberg-table {
    border-top: var(--tableberg-table-border-top, 1px solid black);
    border-right: var(--tableberg-table-border-right, 1px solid black);
    border-bottom: var(--tableberg-table-border-bottom, 1px solid black);
    border-left: var(--tableberg-table-border-left, 1px solid black);
    border-collapse: collapse;
    width: 100%;
    &.has-table-width {
        max-width: var(--tableber-table-width) !important;
    }
    &[id*="block-"] {
        &.justify-table-left {
            margin-left: 0 !important;
            margin-right: auto !important;
        }
        &.justify-table-center {
            margin-left: auto !important;
            margin-right: auto !important;
        }
        &.justify-table-right {
            margin-left: auto !important;
            margin-right: 0 !important;
        }
    }
    &.justify-table-left {
        margin-left: 0 !important;
        margin-right: auto !important;
    }
    &.justify-table-center {
        margin-left: auto !important;
        margin-right: auto !important;
    }
    &.justify-table-right {
        margin-left: auto !important;
        margin-right: 0 !important;
    }
    .tableberg-row {
        &:not(.tableberg-header):not(.tableberg-footer) {
            &:nth-child(even) {
                background: var(--tableberg-even-row-bg-color);
            }
            &:nth-child(odd) {
                background: var(--tableberg-odd-row-bg-color);
            }
        }

        &.tableberg-footer {
            background: var(--tableberg-footer-bg-color);
        }

        &.tableberg-header {
            background: var(--tableberg-header-bg-color);
        }
    }
    &.has-inner-border {
        td.wp-block-tableberg-cell {
            border-top: var(--tableberg-inner-border-top, 1px solid #000000);
            border-right: var(
                --tableberg-inner-border-right,
                1px solid #000000
            );
            border-bottom: var(
                --tableberg-inner-border-bottom,
                1px solid #000000
            );
            border-left: var(--tableberg-inner-border-left, 1px solid #000000);
        }
    }
}
