.signature-pad {
  width: 100%;
  height: 100%;
}
  
.is-field-type-signature .wrapper {
  position: relative;
}
  
.signature-pad-wrapper{
  height:auto;
  width:100%;
}

.signature-pad-wrapper .action-buttons{
  display: flex;
  gap: 5px;
  flex-wrap: wrap;
  position: absolute;
  right: 10px;
  bottom: 10px;
}
.signature-pad-wrapper .action-buttons .action-button{
  cursor: pointer;
}

.signature-pad-wrapper .button-wrapper .action-buttons a{
  padding: 10px 20px;
  text-decoration: none !important;
  background-color: var(--sffe-button-bg-color);
  border: 1px solid #ccc;
  color: var(--sffe-button-color);
  border-radius: 3px;
  cursor: pointer;
}

.signature-pad-wrapper .button-wrapper .action-buttons a.coolform-signature-clear:hover,
.signature-pad-wrapper .button-wrapper .action-buttons a.coolform-signature-redo:hover,
.signature-pad-wrapper .button-wrapper .action-buttons a.coolform-signature-undo:hover{
  background-color: var(--sffe-button-color);
  color: var(--sffe-button-bg-color);
  border-color: #fff;
  box-shadow: 0 0 5px #333;
}

.signature-pad-wrapper .color-buttons{
  display: flex;
  gap: 5px;
  align-items: center;
  position: absolute;
  left: 10px;
  bottom: 10px;
}

.is-field-type-signature .signature-pad-wrapper .color-buttons input[type="color"].signature-color-picker {
  appearance: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  border: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  cursor: pointer;
  padding: 0;
  background-color: transparent;
  position: relative;
  box-shadow: 0 0 0 2px #ccc;
  transition: all 0.2s ease;
  overflow: hidden;
}

.is-field-type-signature .signature-pad-wrapper .color-buttons input[type="color"].signature-color-picker::-webkit-color-swatch-wrapper {
  padding: 0;
}
.is-field-type-signature .signature-pad-wrapper .color-buttonsinput[type="color"].signature-color-picker::-webkit-color-swatch {
  border: none;
  border-radius: 50%;
}

/* Firefox */
.is-field-type-signature .signature-pad-wrapper .color-buttons input[type="color"].signature-color-picker::-moz-color-swatch {
  border: none;
  border-radius: 50%;
}

/* Focus/hover states */
.is-field-type-signature .signature-pad-wrapper .color-buttons input[type="color"].signature-color-picker:hover,
.is-field-type-signature .signature-pad-wrapper .color-buttons input[type="color"].signature-color-picker:focus {
  box-shadow: 0 0 0 2px #4caf50;
  transform: scale(1.05);
}

.wrapper .signature-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  display: flex;
  align-content: center;
  justify-content: center;
  align-items: center;
  max-width: 80%;
  margin: 0 auto;
  pointer-events: none;
  color: white;
  padding: 15px;
  z-index: 1;
  transition: 40ms ease-in-out;
  transition-property: opacity
}

.wrapper[data-draw="true"] .signature-placeholder {
  opacity: 0;
}

.wrapper .signature-placeholder svg {
  width: 100%;
  max-width: 100%
}

.coolform-signature-undo,
.coolform-signature-redo {
    opacity: 0.2;
    pointer-events: none;
    transition: opacity 0.3s ease;
}

.coolform-signature-undo.active,
.coolform-signature-redo.active {
    opacity: 1;
    pointer-events: all;
}
/* Signature canvas inherits Elementor global form field styles */
.is-field-type-signature .signature-pad {
  border-style: solid;
  border-width: var(--e-form-field-border-width, 1px);
  border-color: var(--e-form-field-border-color, #ccc);
  background-color: var(--e-form-field-background-color, #fff);
  box-sizing: border-box;
  width: 100%;
  display: block;
}

.is-field-type-signature.has-shape-round .signature-pad{
  border-radius: 32px;
}
.is-field-type-signature.has-shape-rounded .signature-pad{
  border-radius: 12px;
}
.is-field-type-signature.has-shape-sharp .signature-pad{
  border-radius: 0px;
}
.is-field-type-signature.has-shape-default .signature-pad{
  border-radius: 8px;
}
