header {
  text-align: center;
  padding: 6px;
  background-color: antiquewhite;
  margin-bottom: 10px;
}

header > h1 {
  font-family: monospace;
  font-size: 1.2rem;
  margin: 0;
}

.tab-title {
  font-size: 1.5rem;
  margin-top: 1rem;
}

.component-form .sidebar-title {
  font-size: 1.1rem;
  margin-top: 0.5rem;
}

.card-body h3, .bin-container h3 {
  font-size: 1.05rem;
}

.card-body .notes-header {
  margin-top: 0.2rem;
  margin-bottom: 0.5rem;
  font-size: 1rem;
}

.card-body .notes-list {
  font-size: 0.9rem;
}

h5.modal-title {
  margin-top: 0;
}

.btn.guide-button {
  position: absolute;
  right: 0.5rem;
  top: 0;
  line-height: 1.2rem;
}

.dropdown-menu-wide {
  width: calc(100% - 1rem);
  min-width: 200px;
}

.page-type-dropdown .form-group {
  margin-top: 0.5rem;
}

.page-type-dropdown .form-group, .page-type-dropdown .radio {
  margin-bottom: 0.25rem;
}

.component-type-dropdown {
  max-height: 20rem;
  overflow-y: auto;
}

.dropdown-menu .dropdown-item.active, .dropdown-menu .dropdown-item:active {
  font-weight: 500;
  background-color: #999999;
  color: #ffffff!important;
}

.settings-row {
  margin-bottom: 15px;
}

.settings-row .dropdown-menu {
  z-index: 1050;
}

.input-group-text .fas {
  line-height: 1.5;
}

.template-select {
  max-height: 30vh;
  overflow-y: auto;
}

.template-select .template-option {
  padding: 0 1em;
  cursor: pointer;
  display: flex;
}

.template-select .template-option:hover {
  background-color: #e9ecef;
}

.template-option .info {
  flex-grow: 0.75;
}

.template-option .title {
  font-weight: 700;
}

.template-option .author {
  font-style: italic;
  flex-grow: 0.25;
  text-align: end;
  align-self: center;
}

.template-option .delete {
  flex-grow: 0.05;
  text-align: end;
  align-self: center;
}

.template-option .delete i {
  padding: 0.2rem;
  margin: 0.2rem;
  border-radius: 0.2rem;
}

.template-option .delete:hover i {
  background-color: #cccccc;
}

.template-option .description {
  font-size: 0.9rem;
  text-overflow: ellipsis;
  width: 100%;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.component-accordion {
  height: calc(100vh - 500px);
  overflow-y: auto;
  margin: 1rem 0;
  padding: 0 5px;
}

.component-accordion.accordion>.card {
  border-radius: 0.5rem;
  margin-bottom: 0.2rem;
  overflow: unset;
}

.component-accordion.accordion>.card>.card-header {
  padding: 0.15rem 0.75rem;
  background-color: #6c757d;
  border-radius: 0.5rem;
}

.component-accordion.accordion>.card>.card-header .btn-link {
  color: #fff;
  padding-top: 0.1rem;
  padding-bottom: 0.1rem;
}

.component-accordion.accordion>.card>.card-header button:focus {
  border: 2px solid #fff;
  box-shadow: none;
}

.component-accordion.accordion>.card .card-body {
  padding: 0.75rem 1rem;
}

.component-accordion .card-body .form-group {
  margin-bottom: 0.4rem;
}

.component-accordion .card-body .form-group label {
  margin-bottom: 0.2rem;
}

.component-form :not(label) {
  font-size: 0.9rem;
}

.component-form label {
  font-size: 1rem;
}

.component-form fieldset {
  display: flex;
  justify-content: space-between;
}

.component-form>.component-settings .form-group,
.component-form>.tab-settings .form-group{
  width: 100%;
}

.component-form fieldset>.component-settings,
.component-form fieldset>.tab-settings{
  width: 48%;
}

.component-form .form-control {
  height: auto;
}

.tab-parameters {
  display: none;
}

.row ::-webkit-scrollbar {
  width: 10px;
  height: 10px;
  background-color: #CFCFCF;
  border-radius: 10px;
  border: 1px solid #BBB;
}

.row ::-webkit-scrollbar-thumb {
  border-radius: 10px;
  background-color: #F9F9F9;
  border: 1px solid #BBB;
}

.row ::-webkit-scrollbar-thumb:hover {
  background: #FFF;
 }

.tab-alert {
  margin-top: 1rem;
}

.help-icon {
  background-color: #999999;
  margin-left: 5px;
  padding: 1px 8px;
  border-radius: 50%;
  color: #FFFFFF;
  font-weight: 500;
}

.help-icon:hover {
  color: #FFFFFF;
  text-decoration: none;
}

.tooltip .tooltip-inner {
  max-width: 300px;
}

.component-settings :first-child {
  margin-top: 0;
}

.component-container {
  height: 100px;
}

.bin-container {
  height: 50px;
}

.component-container, .bin-container {
  box-shadow: 0 0 0 1px black;
  border-radius: 5px;
  margin-top: 1rem;
  overflow-y: hidden;
}

.component-container > * {
  margin-top: 0;
}

.component-container .output-element {
  min-height: 50px;
}

.icon-option .fa, .icon-option .fab {
  width: 20px;
  margin-right: 10px;
}

.bin-container .bin-header {
  position: absolute;
  margin-top: 0.2rem;
}

.bin-container .sortable-bin {
  height: 50px;
}

#settings-code_dropdown {
  max-height: 75vh;
}

.show#settings-code_dropdown {
  display: flex;
  flex-direction: column;
}

.save-code-options {
  margin-top: 0.5rem;
}

.save-code-options .form-inline>label {
  margin-right: 0.5rem;
}

.save-code-options .shiny-options-group {
  display: flex;
}

.save-code-options input[type="radio"] {
  margin-right: 0.25rem;
}

.code-ui-form {
  margin: 0 0.5rem 0.5rem 0.5rem;
}

.code-ui-form .toast.show, .code-ui-form .toast.showing, .code-ui-form .toast.fade {
  position: absolute;
  top: -2rem;
}

.code-ui-form #save_toast {
  right: 55%;
}

.code-output {
  overflow-y: auto;
  min-height: 20vh;
  margin-bottom: -0.5rem;
}

.page-canvas-shell {
  margin-top: 1rem;
  height: calc(100vh - 140px);
  box-shadow: 0 0 0 1px black;
  border-radius: 1px;
}

.page-canvas-shell.preview {
  height: 100vh;
  width: 100vw;
  position: fixed;
  top: 0;
  left: 0;
  margin-top: 0;
  background-color: #FFFFFF;
  z-index: 1000;
}

.page-canvas-header {
  background-color: #666666;
}

.page-canvas-title {
  position: absolute;
  right: calc(50% - 64px);
  color: white;
  top: 1rem;
}

.page-canvas-shell.preview .page-canvas-title {
  top: 0;
}

.page-preview-button {
  display: none;
  position: absolute;
  right: 0;
  top: 1.5rem;
  z-index: 9000;
}

.page-canvas-shell.preview .page-preview-button {
  display: inline;
}

.canvas-modal {
  position: absolute;
  top: 15%;
  bottom: 10%;
  right: 20%;
  left: 20%;
  border: #333 2px solid;
  border-radius: 1rem;
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  height: fit-content;
  background: #FCFCFC;
  box-shadow: #555 2px 2px 1rem 0.5rem;
}

.canvas-modal-title {
  margin-top: 0.5rem;
  margin-bottom: 0;
}

.canvas-page-choices {
  padding: 0.25rem;
}

.canvas-page-choice {
  width: 40%;
  margin: 1rem;
  height: 8rem;
  border-radius: 1rem;
}

.canvas-page-choice .canvas-choice-header {
  margin-top: 0.5rem;
  font-size: 1.4rem
}

.canvas-page-choice .canvas-choice-content {
  font-size: 0.9rem;
}

.dimmed-canvas-page {
  height: 100%;
  background: #CCCCCC;
}

.page-canvas {
  height: calc(100% - 24px);
}

.designer-page-template {
  height: 100%;
  overflow-y: auto;
}

.navbar-page-tabs {
  height: calc(100% - 80px);
}

.navbar-page-tabs .tab-content, .navbar-page-tabs .tab-pane {
  height: 100%;
}

.designer-element {
  z-index: 1;
  cursor: pointer;
}

.designer-element:not(blockquote, .card-body, .tab-pane) {
  border: 1px dashed black;
}

blockquote.designer-element {
  border-top: 1px dashed;
  border-right: 1px dashed;
  border-bottom: 1px dashed;
  border-top-color: black !important;
  border-right-color: black !important;
  border-bottom-color: black !important;
}

.designer-element:not(pre, .shiny-input-panel, .row-designer, .col-sm, .btn) {
  background-color: white;
}

.designer-page-template .shiny-input-panel {
  min-height: 80px;
}

.designer-page-template .row-designer {
  min-height: 50px;
  background: aliceblue;
  position: relative;
}

.component-container .row-designer:after, .designer-page-template .row-designer:after {
  content: "Row";
}

.designer-page-template .row-designer:after {
  position: absolute;
  z-index: 0;
  left: 5px;
}

.designer-page-template .col-sm {
  min-height: 50px;
  background: bisque;
}

.component-container .col-sm:after, .designer-page-template .col-sm:after {
  content: "Column";
}

.designer-page-template .col-sm:after {
  position: absolute;
  z-index: -1;
  top: 0;
  left: 5px;
}

.component-container .shiny-input-panel:after, .designer-page-template .shiny-input-panel:after {
  content: "Input Panel";
}

.designer-page-template .shiny-input-panel {
  position: relative;
}

.designer-page-template .shiny-input-panel:after {
  position: absolute;
  top: 5px;
  left: 5px;
  z-index: -1;
}

.designer-page-template.hidden-after-label .designer-element:after {
  display: none;
}

.designer-page-template.hidden-colour .designer-element:not(pre, .shiny-input-panel, .btn) {
  background-color: inherit;
}

.designer-page-template.hidden-borders .designer-element {
  border: 0;
}

.designer-element.plot-output-element, .designer-element.image-output-element {
  text-align: center;
}

.designer-page-template .designer-element.plot-output-element,
.designer-page-template .designer-element.image-output-element {
  background-color: snow;
}

.designer-element.plot-output-element, .designer-element.image-output-element,
.plot-output-element>img, .image-output-element>img {
  max-height: 100%;
  max-width: 100%;
}

span.plot-output-element, span.image-output-element {
  display: inline-block;
}

.component-container .plot-output-element, .component-container .image-output-element {
  height: 50px;
}

.designer-element.shiny-input-panel .designer-element.form-group {
  background-color: #f6f6f6;
}

.designer-page-template .designer-element>p {
  position: absolute;
}

.designer-page-template .tabset-designer-component .tab-content>.tab-pane,
.designer-page-template .card-body {
  min-height: 200px;
}

#canvas-menu {
  position: fixed;
  z-index: 10000;
  width: 12rem;
  background: #444;
  border-radius: 10px;
  transform: scale(0);
  transform-origin: top left;
}

#canvas-menu.visible {
  transform: scale(1);
  transition: transform 200ms cubic-bezier(0.13, 0.63, 0.29, 0.87);
}

#canvas-menu .item {
  padding: 6px 12px;
  font-size: 15px;
  color: #EEE;
  cursor: pointer;
  border-radius: inherit;
  font-size: 0.9rem;
}

#canvas-menu .item i {
  width: 1.5rem;
  padding-right: 0.5rem;
}

#canvas-menu .item:hover {
  background: #343434;
}

/* bs4Dash specific conditions */
body, h1, h2, h3, h4, h5, h6, div, span, p, label {
  font-family: -apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,"Noto Sans","Liberation Sans",sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol","Noto Color Emoji";
}

body #canvas-page.wrapper * {
  font-family: "Source Sans Pro",-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif,"Apple Color Emoji","Segoe UI Emoji","Segoe UI Symbol" !important;
}

body #canvas-page.wrapper .fa, body #canvas-page.wrapper .fas,
body #canvas-page.wrapper .far {
  font-family: "Font Awesome 5 Free" !important;
}

body #canvas-page.wrapper .fab {
  font-family: "Font Awesome 5 Brands" !important;
}

#canvas-page .main-header {
  margin-bottom: 0 !important;
}

#canvas-page.wrapper .content-wrapper {
  min-height: calc(100% - 3.55rem) !important;
  height: calc(100% - 3.55rem) !important;
  overflow-y: auto !important;
}

#canvas-page .content-wrapper>.content,
#canvas-page .content-wrapper>.content>.tab-content,
#canvas-page .content-wrapper>.content>.tab-content>.tab-pane {
  height: 100% !important;
}

#tab_settings label, #component_settings label, #sidebar-accordion .card label,
#settings-options_dropdown label, #canvas-page:not(.wrapper) label, #settings-page_type label {
  font-weight: 400 !important;
}

.layout-fixed #canvas-page .main-sidebar {
  position: absolute !important;
  height: 100% !important;
}

#canvas-page .content-wrapper .designer-element:not(pre, .shiny-input-panel, .row-designer, .col-sm, .btn) {
  background-color: inherit !important;
}
