:root, .dark{
    --checkbox-label-gap: 0.25em 0.1em;
    --section-header-text-size: 12pt;
    --block-background-fill: transparent;
}

div.form{
    border-width: 0 !important;
    box-shadow: none;
    background: transparent;
    overflow: visible;
    outline: none !important;
    gap: 0.5em;
}
#tool_botton{
    max-width: 2.2em;
    min-width: 2.2em !important;
    height: 2.4em;
    align-self: end;
    line-height: 1em;
    border-radius: 0.5em;
}
#accordion{
    border-width: 0 !important;
    box-shadow: none;
    background: transparent;
    overflow: visible;
    outline: none !important;
    gap: 0.5em;
}
#dropdown{
    border-width: 0 !important;
    box-shadow: none;
    background: transparent;
    overflow: visible;
    outline: none !important;
    gap: 0.5em;
}

.block.gradio-dropdown,
.block.gradio-slider,
.block.gradio-checkbox,
.block.gradio-textbox,
.block.gradio-radio,
.block.gradio-checkboxgroup,
.block.gradio-number,
.block.gradio-colorpicker
{
    border-width: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}
.gradio-dropdown{
    border-width: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}

.block.gradio-accordion
{
    border-width: 0 !important;
    box-shadow: none !important;
    outline: none !important;
}

.block.padded:not(.gradio-accordion) {
    padding: 0em !important;
}

.gradio-button.secondary-down{
    background: var(--button-secondary-background-fill);
    color: var(--button-secondary-text-color);
}
.gradio-button.secondary-down, .gradio-button.secondary-down:hover{
    box-shadow: 1px 1px 1px rgba(0,0,0,0.25) inset, 0px 0px 3px rgba(0,0,0,0.15) inset;
}
.gradio-button.secondary-down:hover{
    background: var(--button-secondary-background-fill-hover);
    color: var(--button-secondary-text-color-hover);
}

.checkboxes-row{
    margin-bottom: 0.5em;
    margin-left: 0em;
}
.checkboxes-row > div{
    flex: 0;
    white-space: nowrap;
    min-width: auto;
}

button.custom-button{
    border-radius: var(--button-large-radius);
    padding: var(--button-large-padding);
    font-weight: var(--button-large-text-weight);
    border: var(--button-border-width) solid var(--button-secondary-border-color);
    background: var(--button-secondary-background-fill);
    color: var(--button-secondary-text-color);
    font-size: var(--button-large-text-size);
    display: inline-flex;
    justify-content: center;
    align-items: center;
    transition: var(--button-transition);
    box-shadow: var(--button-shadow);
    text-align: center;
}

.gradio-button.tool{
    max-width: 1em;
    min-width: 1em !important;
    height: 1em;
    align-self: end;
    line-height: 1em;
    border-radius: 0.5em;
}

@media screen and (min-width: 2500px) {
    #txt2img_gallery, #img2img_gallery {
        min-height: 768px;
    }
}

#txt2img_gallery img, #img2img_gallery img, #extras_gallery img{
    object-fit: scale-down;
}