/* generic html tags */
:root, .light, .dark {
  --font: "Source Sans Pro", 'ui-sans-serif', 'system-ui', "Roboto", sans-serif, 'NotoSans';
  --font-mono: 'IBM Plex Mono', 'ui-monospace', 'Consolas', monospace;
  --font-size: 14px;
  --highlight-color: #ff00f2;
  --inactive-color: #005485;
  --background-color: #000000;
  --primary-50: #f5daea;
  --primary-100: #ffc4f2;
  --primary-200: #fc9ff4;
  --primary-300: #fd74eb;
  --primary-400: #fb3cf1;
  --primary-500: #f916c0;
  --primary-600: #c50cea;
  --primary-700: #c20cb9;
  --primary-800: #9a1293;
  --primary-900: #7c1277;
  --primary-950: #6c1268;
}
.light, .dark {
  --input-padding: 4px;
  --radius-lg: 2px;
  --radius-sm: 1px;
  --spacing-md: 4px;
  --spacing-xxl: 12px;
  --line-sm: 1.3em;
  --line-md: 1.3em;
}

html { font-size: var(--font-size); }
body, button, input, select, textarea { font-family: var(--font);}
button { max-width: 400px; }
img { background-color: var(--background-color); }
input[type=checkbox] { background-color: transparent !important; }
input[type=range] { height: var(--line-sm) !important; appearance: none !important; margin-top: 0 !important; min-width: 160px !important;
  background-color: var(--background-color) !important; width: 100% !important; background: transparent !important; }
input[type=range]::-webkit-slider-runnable-track { width: 100% !important; height: var(--line-sm) !important; cursor: pointer !important; box-shadow: 2px 2px 3px #111111 !important;
  background: var(--input-background-fill) !important; border-radius: var(--radius-lg) !important; border: 0px solid #222222 !important; }
input[type=range]::-moz-range-track { width: 100% !important; height: var(--line-sm) !important; cursor: pointer !important; box-shadow: 2px 2px 3px #111111 !important; background:
  var(--input-background-fill) !important; border-radius: var(--radius-lg) !important; border: 0px solid #222222 !important; }
input[type=range]::-webkit-slider-thumb { box-shadow: 2px 2px 3px #111111 !important; border: 0px solid #000000 !important; height: var(--line-sm) !important; width: var(--line-sm) !important;
  border-radius: var(--radius-lg) !important; background: var(--highlight-color) !important; cursor: pointer !important; appearance: none !important; margin-top: 0px !important; }
input[type=range]::-moz-range-thumb { box-shadow: 2px 2px 3px #111111 !important; border: 0px solid #000000 !important; height: var(--line-sm) !important; width: var(--line-sm) !important;
  border-radius: var(--radius-lg) !important; background: var(--highlight-color) !important; cursor: pointer !important; appearance: none !important; margin-top: 0px !important; }
:root { scrollbar-color: var(--highlight-color) #3a343a; }
::-webkit-scrollbar { width: 12px; height: 12px; }
::-webkit-scrollbar-track { background: #3a343a; }
::-webkit-scrollbar-thumb { background-color: var(--highlight-color); border-radius: var(--radius-lg); border-width: 0; box-shadow: 2px 2px 3px #111111; }
div.form { border-width: 0; box-shadow: none; background: transparent; overflow: visible; margin-bottom: 6px; }
div.compact { gap: 1em; }

/* gradio style classes */
fieldset .gr-block.gr-box, label.block span { padding: 0; margin-top: -4px; }
.border-2 { border-width: 0; }
.border-b-2 { border-bottom-width: 2px; border-color: var(--highlight-color) !important; padding-bottom: 2px; margin-bottom: 8px; }
.bg-white { color: rgb(255, 255, 255); background-color: var(--inactive-color); }
.gr-box { border-radius: var(--radius-sm) !important; background-color: #111111 !important; box-shadow: 2px 2px 3px #111111; border-width: 0; padding: 4px; margin: 12px 0px 12px 0px }
.gr-button { font-weight: normal; box-shadow: 2px 2px 3px #111111; font-size: 0.8rem; min-width: 32px; min-height: 32px; padding: 3px; margin: 3px; }
.gr-check-radio { background-color: var(--inactive-color); border-width: 0; border-radius: var(--radius-lg); box-shadow: 2px 2px 3px #111111; }
.gr-check-radio:checked { background-color: var(--highlight-color); }
.gr-compact { background-color: var(--background-color); }
.gr-form { border-width: 0; }
.gr-input { background-color: #333333 !important; padding: 4px; margin: 4px; }
.gr-input-label { color: rgb(255, 255, 255); border-width: 0; background: transparent; padding: 2px !important; }
.gr-panel { background-color: var(--background-color); }
.eta-bar { display: none !important }
svg.feather.feather-image, .feather .feather-image { display: none }
.gap-2 { padding-top: 8px; }
.gr-box > div > div > input.gr-text-input { right: 0; width: 4em; padding: 0; top: -12px; border: none; max-height: 20px; }
.output-html { line-height: 1.2rem; overflow-x: hidden; }
.output-html > div { margin-bottom: 8px; }
.overflow-hidden .flex .flex-col .relative col .gap-4 { min-width: var(--left-column); max-width: var(--left-column); } /* this is a problematic one */
.p-2 { padding: 0; }
.px-4 { padding-lefT: 1rem; padding-right: 1rem; }
.py-6 { padding-bottom: 0; }
.tabs { background-color: var(--background-color); }
.block.token-counter span { background-color: #222 !important; box-shadow: 2px 2px 2px #111; border: none !important; font-size: 0.8rem; }
.tab-nav { zoom: 110%; margin-bottom: 10px; border-bottom: 2px solid var(--highlight-color) !important; padding-bottom: 2px; }
.label-wrap { margin: 16px 0px 8px 0px; }
.gradio-button.tool { border: none; background: none; box-shadow: none; }
#tab_extensions table td, #tab_extensions table th { border: none; padding: 0.5em; }
#tab_extensions table { width: 96vw }
#tab_extensions table thead { background-color: var(--neutral-700); }

/* automatic style classes */
.progressDiv { border-radius: var(--radius-sm) !important; position: fixed; top: 44px; right: 26px; max-width: 262px; height: 48px; z-index: 99; box-shadow: var(--button-shadow); }
.progressDiv .progress { border-radius: var(--radius-lg) !important; background: var(--highlight-color); line-height: 3rem; height: 48px; }
.gallery-item { box-shadow: none !important; }
.performance { color: #888; }
.extra-networks { border-left: 2px solid var(--highlight-color) !important; padding-left: 4px; }
.image-buttons { gap: 10px !important}

/* gradio elements overrides */
#div.gradio-container { overflow-x: hidden; }
#img2img_label_copy_to_img2img { font-weight: normal; }
#img2img_settings { min-width: calc(2 * var(--left-column)); max-width: calc(2 * var(--left-column)); background-color: #111111; padding-top: 16px; }
#interrogate, #deepbooru { margin: 0 0px 10px 0px; max-width: 80px; max-height: 80px; font-weight: normal; font-size: 0.95em; }
#quicksettings .gr-button-tool { font-size: 1.6rem; box-shadow: none; margin-left: -20px; margin-top: -2px; height: 2.4em; }
#footer, #style_pos_col, #style_neg_col, #roll_col, #extras_upscaler_2, #extras_upscaler_2_visibility, #txt2img_seed_resize_from_w, #txt2img_seed_resize_from_h { display: none; }
#save-animation { border-radius: var(--radius-sm) !important; margin-bottom: 16px; background-color: #111111; }
#script_list { padding: 4px; margin-top: 16px; margin-bottom: 8px; }
#settings > div.flex-wrap { width: 15em; }
#tab_extensions table { background-color: #222222; }
#txt2img_cfg_scale { min-width: 200px; }
#txt2img_checkboxes, #img2img_checkboxes { background-color: transparent; }
#txt2img_checkboxes, #img2img_checkboxes { margin-bottom: 0.2em; }
#extras_upscale { margin-top: 10px }
#txt2img_progress_row > div { min-width: var(--left-column); max-width: var(--left-column); }
#txt2img_settings { min-width: var(--left-column); max-width: var(--left-column); background-color: #111111; padding-top: 16px; }
#pnginfo_html2_info { margin-top: -18px; background-color: var(--input-background-fill); padding: var(--input-padding) }
.gradio-button.tool { filter: hue-rotate(120deg) saturate(0.5); }
#txt2img_styles_row, #img2img_styles_row { margin-top: -6px; z-index: 200; }

/* based on gradio built-in dark theme */
:root, .light, .dark {
  --body-background-fill: var(--background-color);
  --body-text-color: var(--neutral-100);
  --color-accent-soft: var(--neutral-700);
  --background-fill-primary: #222222;
  --background-fill-secondary: none;
  --border-color-accent: var(--background-color);
  --border-color-primary: var(--background-color);
  --link-text-color-active: var(--secondary-500);
  --link-text-color: var(--secondary-500);
  --link-text-color-hover: var(--secondary-400);
  --link-text-color-visited: var(--secondary-600);
  --body-text-color-subdued: var(--neutral-400);
  --shadow-spread: 1px;
  --block-background-fill: None;
  --block-border-color: var(--border-color-primary);
  --block_border_width: None;
  --block-info-text-color: var(--body-text-color-subdued);
  --block-label-background-fill: var(--background-fill-secondary);
  --block-label-border-color: var(--border-color-primary);
  --block_label_border_width: None;
  --block-label-text-color: var(--neutral-200);
  --block_shadow: None;
  --block_title_background_fill: None;
  --block_title_border_color: None;
  --block_title_border_width: None;
  --block-title-text-color: white;
  --panel-background-fill: var(--background-fill-secondary);
  --panel-border-color: var(--border-color-primary);
  --panel_border_width: None;
  --checkbox-background-color: var(--neutral-800);
  --checkbox-background-color-focus: var(--checkbox-background-color);
  --checkbox-background-color-hover: var(--checkbox-background-color);
  --checkbox-background-color-selected: var(--secondary-600);
  --checkbox-border-color: var(--neutral-700);
  --checkbox-border-color-focus: var(--secondary-500);
  --checkbox-border-color-hover: var(--neutral-600);
  --checkbox-border-color-selected: var(--secondary-600);
  --checkbox-border-width: var(--input-border-width);
  --checkbox-label-background-fill: None;
  --checkbox-label-background-fill-hover: None;
  --checkbox-label-background-fill-selected: var(--checkbox-label-background-fill);
  --checkbox-label-border-color: var(--border-color-primary);
  --checkbox-label-border-color-hover: var(--checkbox-label-border-color);
  --checkbox-label-border-width: var(--input-border-width);
  --checkbox-label-text-color: var(--body-text-color);
  --checkbox-label-text-color-selected: var(--checkbox-label-text-color);
  --error-background-fill: var(--background-fill-primary);
  --error-border-color: var(--border-color-primary);
  --error_border_width: None;
  --error-text-color: #ef4444;
  --input-background-fill: var(--neutral-800);
  --input-background-fill-focus: var(--secondary-600);
  --input-background-fill-hover: var(--input-background-fill);
  --input-border-color: var(--border-color-primary);
  --input-border-color-focus: var(--neutral-700);
  --input-border-color-hover: var(--input-border-color);
  --input_border_width: None;
  --input-placeholder-color: var(--neutral-500);
  --input-shadow: 2px 2px 2px 2px #111111;
  --input-shadow-focus: 2px 2px 2px 2px #111111;
  --loader_color: None;
  --slider_color: None;
  --stat-background-fill: linear-gradient(to right, var(--primary-400), var(--primary-600));
  --table-border-color: var(--neutral-700);
  --table-even-background-fill: #222222;
  --table-odd-background-fill: #333333;
  --table-row-focus: var(--color-accent-soft);
  --button-border-width: var(--input-border-width);
  --button-cancel-background-fill: linear-gradient(to bottom right, #dc2626, #b91c1c);
  --button-cancel-background-fill-hover: linear-gradient(to bottom right, #dc2626, #dc2626);
  --button-cancel-border-color: #dc2626;
  --button-cancel-border-color-hover: var(--button-cancel-border-color);
  --button-cancel-text-color: white;
  --button-cancel-text-color-hover: var(--button-cancel-text-color);
  --button-primary-background-fill: linear-gradient(to bottom right, var(--primary-500), var(--primary-800));
  --button-primary-background-fill-hover: linear-gradient(to bottom right, var(--primary-500), var(--primary-300));
  --button-primary-border-color: var(--primary-500);
  --button-primary-border-color-hover: var(--button-primary-border-color);
  --button-primary-text-color: white;
  --button-primary-text-color-hover: var(--button-primary-text-color);
  --button-secondary-background-fill: linear-gradient(to bottom right, var(--neutral-600), var(--neutral-800));
  --button-secondary-background-fill-hover: linear-gradient(to bottom right, var(--neutral-600), var(--neutral-400));
  --button-secondary-border-color: var(--neutral-600);
  --button-secondary-border-color-hover: var(--button-secondary-border-color);
  --button-secondary-text-color: white;
  --button-secondary-text-color-hover: var(--button-secondary-text-color);
  --secondary-50: #eff6ff;
  --secondary-100: #dbeafe;
  --secondary-200: #bfdbfe;
  --secondary-300: #93c5fd;
  --secondary-400: #60a5fa;
  --secondary-500: #3b82f6;
  --secondary-600: #2563eb;
  --secondary-700: #1d4ed8;
  --secondary-800: #1e40af;
  --secondary-900: #1e3a8a;
  --secondary-950: #1d3660;
  --neutral-50: #e7d1ee;
  --neutral-100: #dbbfe0;
  --neutral-200: #c3acce;
  --neutral-300: #a892ad;
  --neutral-400: #8d7896;
  --neutral-500: #6c6074;
  --neutral-600: #606060;
  --neutral-700: #433b46;
  --neutral-800: #322c35;
  --neutral-900: #1b1127;
  --neutral-950: #140b19;
  --radius-xxs: 0;
  --radius-xs: 0;
  --radius-md: 0;
  --radius-xl: 0;
  --radius-xxl: 0;
  --body-text-size: var(--text-md);
  --body-text-weight: 400;
  --embed-radius: var(--radius-lg);
  --color-accent: var(--primary-500);
  --shadow-drop: 0;
  --shadow-drop-lg: 0 1px 3px 0 rgb(0 0 0 / 0.1), 0 1px 2px -1px rgb(0 0 0 / 0.1);
  --shadow-inset: rgba(0,0,0,0.05) 0px 2px 4px 0px inset;
  --block-border-width: 1px;
  --block-info-text-size: var(--text-sm);
  --block-info-text-weight: 400;
  --block-label-border-width: 1px;
  --block-label-margin: 0;
  --block-label-padding: var(--spacing-sm) var(--spacing-lg);
  --block-label-radius: calc(var(--radius-lg) - 1px) 0 calc(var(--radius-lg) - 1px) 0;
  --block-label-right-radius: 0 calc(var(--radius-lg) - 1px) 0 calc(var(--radius-lg) - 1px);
  --block-label-text-size: var(--text-sm);
  --block-label-text-weight: 400;
  --block-padding: var(--spacing-xl) calc(var(--spacing-xl) + 2px);
  --block-radius: var(--radius-lg);
  --block-shadow: var(--shadow-drop);
  --block-title-background-fill: none;
  --block-title-border-color: none;
  --block-title-border-width: 0px;
  --block-title-padding: 0;
  --block-title-radius: none;
  --block-title-text-size: var(--text-md);
  --block-title-text-weight: 400;
  --container-radius: var(--radius-lg);
  --form-gap-width: 1px;
  --layout-gap: var(--spacing-xxl);
  --panel-border-width: 0;
  --section-header-text-size: var(--text-md);
  --section-header-text-weight: 400;
  --checkbox-border-radius: var(--radius-sm);
  --checkbox-label-gap: 2px;
  --checkbox-label-padding: var(--spacing-md);
  --checkbox-label-shadow: var(--shadow-drop);
  --checkbox-label-text-size: var(--text-md);
  --checkbox-label-text-weight: 400;
  --checkbox-check: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3cpath d='M12.207 4.793a1 1 0 010 1.414l-5 5a1 1 0 01-1.414 0l-2-2a1 1 0 011.414-1.414L6.5 9.086l4.293-4.293a1 1 0 011.414 0z'/%3e%3c/svg%3e");
  --radio-circle: url("data:image/svg+xml,%3csvg viewBox='0 0 16 16' fill='white' xmlns='http://www.w3.org/2000/svg'%3e%3ccircle cx='8' cy='8' r='3'/%3e%3c/svg%3e");
  --checkbox-shadow: var(--input-shadow);
  --error-border-width: 1px;
  --input-border-width: 0;
  --input-radius: var(--radius-lg);
  --input-text-size: var(--text-md);
  --input-text-weight: 400;
  --loader-color: var(--color-accent);
  --prose-text-size: var(--text-md);
  --prose-text-weight: 400;
  --prose-header-text-weight: 600;
  --slider-color: ;
  --table-radius: var(--radius-lg);
  --button-large-padding: 2px 6px;
  --button-large-radius: var(--radius-lg);
  --button-large-text-size: var(--text-lg);
  --button-large-text-weight: 400;
  --button-shadow: 4px 4px 4px 0px #39353a;
  --button-shadow-active: 1px 1px 4px 0px #564c58;
  --button-shadow-hover: 1px 1px 4px 0px #564c58;
  --button-small-padding: var(--spacing-sm) calc(2 * var(--spacing-sm));
  --button-small-radius: var(--radius-lg);
  --button-small-text-size: var(--text-md);
  --button-small-text-weight: 400;
  --button-transition: none;
  --size-9: 64px;
  --size-14: 64px;
}
/*Midnight-Barbie, By Nyxxia*/
