/* General Styles
=========================================== */

input {
  box-shadow: none !important;
}

input[type="color"] {
  width: 100%;
  height: 30px;
  padding: .25rem;
}

input[type="color"]::-webkit-color-swatch-wrapper {
  padding: 0;
}

input[type="color"]::-webkit-color-swatch {
  border: none;
  border-radius: .25rem;
}

button {
  cursor: pointer;
}

/* Layout
=========================================== */

#playhouse-container {
  height: calc(100vh - 44px);
}

.container-fh {
  min-height: calc(100vh - 56px);
}

#playhouse-iframe {
  height: 100%;
  width: 100%;
  border: 0;
}

#original-editor-container, #editor-container, #code-editor {
  position: relative;
}

/* Resizers
=========================================== */

.resizer {
  padding: .15rem 0;
  cursor: ew-resize;
  position: sticky;
  top: 0;
  max-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  color: inherit !important;
  opacity: 1;
  transition: opacity .5s ease;
}

.resizer:hover {
  opacity: .75;
}

.resizer-vertical {
  cursor: col-resize;
  width: 6px; /* Slightly increased width for better mouse targeting */
  user-select: none; /* Prevent text selection while resizing */
  touch-action: none; /* Prevent touch scrolling during resize */
  transition: background-color 0.2s ease;
}

.resizer-horizontal,
.resizer-horizontal-2 {
  cursor: ns-resize;
}


/* Editors
=========================================== */

#code-editor {
  position: sticky;
  top: 0;
  display: flex;
  flex-direction: column;
  height: 100%;
  overflow: hidden;
  max-height: calc(100vh - 56px) !important;
}

#code-editor.active {
  width: 100% !important;
}


#editor-container {
  height: 25vh;
  flex: 0 0 auto;
}

#original-editor-container {
  height: 50vh;
}

#main-editor-container {
  flex: 0 0 auto;
}

.ace_editor {
  width: 100% !important;
  height: 100%;
}

/* Options
=========================================== */

.options {
  overflow: hidden;
}

#option-container {
  width: 100% !important;
  overflow-y: auto;
  flex: 1 1 auto;
  padding-bottom: 250px !important;    

  --input-font-size: .9rem;
  --input-margin-bottom: 0;

}

#option-container label {
  text-transform: capitalize;
  font-size: .9rem;
}

#template-options > hr:first-child {
  display: none !important;
}

/* Fancy Background
=========================================== */

#fancy {
  background-image: url(../assets/background.jpg);
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}

/* Media Queries
=========================================== */

@media screen and (max-width: 767px) {
  #code-editor {
    width: 0;
  }
}

@media screen and (min-width: 768px) {
  #code-editor {
    width: 25%;
    max-width: calc(100% - 1rem);
    z-index: 1000;
  }
}

/* Other
=========================================== */

.overflow-hidden {
  overflow: hidden !important;
}

.scroll-spacer {
  padding-bottom: 50vh !important;
}

* {
  scrollbar-color: var(--scrollbar-color) transparent;
  scrollbar-width: thin;
}

.loop-group {
  position: relative;
}

.btn.btn-danger.remove-loop-group {
  position: absolute;
  top: -4px;
  right: -8px;
  height: 25px;
  width: 25px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 100% !important;
  font-size: 12px !important;
  padding: .25rem !important;
}



/* Loader
=========================================== */
#loader {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 1;
  background-color: var(--body-background-color);
  background-image: var(--body-background-image);
  background-blend-mode: color-burn;
  transition: opacity .5s ease;
}

#loader.loaded {
  opacity: 0;
  pointer-events: none;
}