/**
 * @file
 * States element styles.
 *
 * @see /webform/test_element_states
 */

.webform-states-table td {
  white-space: nowrap;
}

tr.webform-states-table--state {
  border-top: 2px solid #a6a6a6;
}

tr.webform-states-table--state:first-child {
  border-top: inherit;
}

tr.webform-states-table--state td select {
  width: inherit;
  max-width: inherit;
}

.webform-states-table--state td.webform-states-table--state select,
.webform-states-table--condition select,
.webform-states-table--condition input[type="text"] {
  width: 100%;
  max-width: 100%;
}

.webform-states-table--condition input[type="text"] {
  margin-top: 4px;
}

.webform-states-table .image-button {
  margin: 0;
}

.webform-states-table th.webform-states-table--operations,
.webform-states-table td.webform-states-table--operations {
  padding: 0 2px;
  vertical-align: middle;
}

.webform-states-table td.webform-states-table--operations input[type="image"] {
  box-sizing: border-box;
  width: 20px;
  min-width: initial;
  max-width: initial;
  padding: 2px;
  opacity: 0.4;
  border: 2px solid #333;
  border-radius: 50%;
}

.webform-states-table td.webform-states-table--operations input[type="image"] + input[type="image"] {
  margin-left: 2px;
}

.webform-states-table td.webform-states-table--operations input[type="image"]:hover,
.webform-states-table td.webform-states-table--operations input[type="image"]:focus,
.webform-states-table td.webform-states-table--operations input[type="image"]:active {
  opacity: 1;
  background: none;
}

/**
 * Suppress table drag warnings.
 */
.webform-states-table .tabledrag-changed-warning,
.webform-states-table .tabledrag-changed {
  display: none !important; /* Must use !important because .tabledrag-changed 'display' is set via JavaScript */
}

/**
 * Limit results in jQuery UI Autocomplete
 *
 * https://stackoverflow.com/questions/7617373/limit-results-in-jquery-ui-autocomplete
 */
.ui-autocomplete {
  overflow-x: hidden;
  overflow-y: auto;
  max-height: 200px;
}
