/**
 * 01. Base
 */
.ectcsf{
  position: relative;

  label{
    padding: 0;
    margin: 0;
    display: inline-block;
  }
}

.ectcsf-ab-icon{
  top: 2px;
}

#screen-meta-links + .ectcsf-options{
  margin-top: 40px;
}

.ectcsf-options{
  margin-top: 20px;
  margin-right: 20px;
}

/**
 * 01. 01. Header
 */
.ectcsf-header{
  position: relative;
}

.ectcsf-header-inner{
  padding: 25px;
  transition: box-shadow .3s ease;

  h1{
    float: left;
    font-size: 1.5em;
    line-height: 26px;
    font-weight: 400;
    margin: 0;

    small{
      font-size: 11px;
      font-weight: 500;
    }
  }
}

/**
 * 01. 02. Sticky
 */
.ectcsf-sticky{

  .ectcsf-header-inner{
    position: fixed;
    z-index: 99;
    top: 32px;
    box-shadow: 0 5px 10px rgba(0,0,0,0.1);
  }
}

/**
 * 01. 03. Header Buttons
 */
.ectcsf-buttons{
  float: right;

  .button{
    margin: 0 2px;
    line-height: 26px;

    &:focus{
      outline: none !important;
      box-shadow: none !important;
    }
  }

  .ectcsf-save{
    min-width: 72px;
  }
}

.ectcsf-header-left{
  float: left;
}

.ectcsf-header-right{
  float: right;
}

/**
 * 01. 04. Navigation
 */
.ectcsf-nav{
  display: block;
  position: relative;
  z-index: 10;
  float: left;

  ul{
    clear: left;
    margin: 0;
    list-style-type: none;

    li{
      margin-bottom: 0;

      a{
        font-size: 13px;
        position: relative;
        display: block;
        padding: 14px 12px;
        text-decoration: none;
        transition-property: color, background;
        transition-duration: 0.2s;
        transition-timing-function: ease;

        &:focus{
          outline: none;
          box-shadow: none;
        }
      }

      .ectcsf-arrow:after{
        content: "\f054";
        display: inline-block;
        font-family: "Font Awesome 5 Pro", "Font Awesome 5 Free", "FontAwesome";
        font-weight: 900;
        font-size: 9px;
        line-height: 1;
        position: absolute;
        right: 10px;
        top: 50%;
        margin-top: -4px;
      }

      &.ectcsf-tab-expanded{

        .ectcsf-arrow:after{
          transform: rotate(90deg);
        }

        ul{
          display: block;
        }
      }
    }

    ul{
      display: none;
      position: relative;

      li{

        a{
          font-size: 12px;
          padding: 12px 14px 12px 24px;
        }
      }
    }
  }

  .ectcsf-tab-icon{
    width: 20px;
    margin-right: 5px;
    font-size: 13px;
    text-align: center;
  }

  .ectcsf-label-error{
    margin-left: 4px;
    vertical-align: top;
  }
}

.ectcsf-nav-normal{
  width: 225px;

  + .ectcsf-content{
    margin-left: 225px;
  }
}

.ectcsf-nav-inline{
  width: 100%;

  ul{

    li{
      display: inline-block;
      vertical-align: top;
    }
  }
}

.ectcsf-nav-background{
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 9;
  width: 225px;
}

/**
 * 01. 05. Wrapper
 */
.ectcsf-wrapper{
  position: relative;
}

/**
 * 01. 06. Content
 */
.ectcsf-content{
  position: relative;
  background-color: #fff;
}

/**
 * 01. 07. Section
 */
.ectcsf-sections{
  float: left;
  width: 100%;
}

.ectcsf-section-title{
  display: none;
  padding: 20px 30px;
  background-color: #f5f5f5;
  border-top: 1px solid #eee;
  border-bottom: 1px solid #eee;

  h3{
    margin: 0;
    padding: 0 ;
    font-size: 13px;
    font-weight: bold;
    text-transform: uppercase;
  }

  .ectcsf-section-icon{
    margin-right: 5px;
  }
}

/**
 * 01. 08. Footer
 */
.ectcsf-footer{
  padding: 20px;
  font-size: 11px;
}

/**
 * 01. 09. Copyright
 */
.ectcsf-copyright{
  float: left;
  margin-top: 5px;
}

/**
 * 01. 10. Show All Settings
 */
.ectcsf-search-all,
.ectcsf-show-all{
  .ectcsf-nav-background,
  .ectcsf-nav{
    display: none;
  }

  .ectcsf-content{
    margin-left: 0;
  }

  .ectcsf-section-title,
  .ectcsf-section{
    display: block !important;
  }
}

.ectcsf-search-all{
  .ectcsf-section-title{
    display: none !important;
  }
}

//
// Expand
//
.ectcsf-expand-all{
  float: left;
  padding: 0 8px;
  margin-right: 4px;
  z-index: 1;
  font-size: 13px;
  line-height: 30px;
  cursor: pointer;
  user-select: none;
  border-radius: 2px;
  transition: all .2s;

  span{
    font-size: 11px;
    vertical-align: middle;
  }
}

/**
 * 01. 11. Search Input
 */
.ectcsf-search{
  float: left;

  input{
    margin: 0 2px 0 0;
    border: none;
    font-size: 12px;
    line-height: 30px;
    min-height: 30px;
    text-align: inherit;
    padding: 0 10px;
    border-radius: 2px;
    box-shadow: none;

    &:focus{
      box-shadow: none;
    }
  }
}

.ectcsf-saving{

  .ectcsf-buttons,
  .ectcsf-content{
    cursor: default;
    pointer-events: none;
    opacity: 0.5;
  }
}

/**
 * 01. 12. Metabox
 */
.ectcsf-metabox{
  margin: -6px -12px -12px -12px;

  .ectcsf-field{
    padding: 20px;
  }

  .ectcsf-section-title{
    padding: 20px;
  }
}

.block-editor-page{

  .ectcsf-metabox{
    margin: -6px -14px -14px -14px;
  }
}

.block-editor-editor-skeleton__content{

  .ectcsf-metabox{
    border-left: 1px solid #e2e4e7;
    border-right: 1px solid #e2e4e7;
  }
}

.ectcsf-sections-reset{
  float: left;
  width: 100%;
  text-align: right;
  border-top: 1px solid #eee;

  .ectcsf-button-cancel,
  input{
    display: none;
  }

  label{
    padding: 10px;
  }

  span{
    -webkit-user-select: none;
    user-select: none;
  }


  input:checked ~ .ectcsf-button-reset{
    display: none;
  }

  input:checked ~ .ectcsf-button-cancel{
    display: inline-block;
  }

}

#side-sortables{

  .ectcsf-section-title{
    padding: 12px;
  }

  .ectcsf-field{
    padding: 10px 15px;

    .ectcsf-title{
      float: none;
      width: 100%;
      margin-bottom: 6px;
    }

    .ectcsf-fieldset{
      float: none;
      width: 100%;
    }
  }

  .ectcsf-field-text input{
    width: 100%;
  }

  .ectcsf-notice{
    padding: 10px 15px;
  }
}

/**
 * 01. 13. Comment Metabox
 */
.ectcsf-comment-metabox{
  margin: -6px -12px -12px -12px;

  .ectcsf-field{
    padding: 20px;
  }

  .ectcsf-section-title{
    padding: 20px;
  }
}


/**
 * 01. 14. Help Tooltip
 */
.ectcsf-tooltip{
  position: absolute;
  z-index: 5000001;
  font-size: 12px;
  line-height: 1.4;
  text-align: center;
  text-decoration: none;
  padding: 6px 12px;
  max-width: 200px;
  color: #fff;
  background-color: #000;
  background-color: rgba(black, 0.85);
  border-radius: 4px;
}
