
@media screen and (min-width: 768px) {
	table.tablequery tbody td div.input-error i {
		bottom: 24px;
	}
	
	table.tablequery tbody td div.input-error i {
		right: 11px;
	}
	
	table.tablequery tbody td div.input-error select + i {
		pointer-events: auto;
		right: 60px;
		bottom: 2px;
	}
	
	table.tablequery tbody td div.input-error textarea + i {
		right: 25px;
		bottom: 12px;
	}
	
	table.tablequery tbody td div.input-error input {
		padding: 12px 25px 12px 12px;
	}
	
	table.tablequery tbody td div.input-error select {
		padding-right: 65px;
	}
}

table.tablequery tbody td div.input-error label.checkbox:before {
	border-color: #C73434;
}

table.tablequery thead i::after {
	margin-top: 6px !important;
}

table.tablequery td select {
	width: 100%;
	margin-right: 5px;
	min-width: 100px;
}

table.tablequery td input {
	margin-top: 3px !important;
	margin-bottom: 3px;
	height: 42px;
}

table.tablequery td textarea {
	overflow-y: hidden;
}

table.tablequery th {
	white-space: normal !important;
}

table.tablequery.required, table.tablequery th.required, table.tablequery td.required, table.tablequery td.required input, table.tablequery td.required textarea {
	color: inherit !important;
}

table.tablequery.required th.required::after {
	content: "*";
	margin-left: 1px;
}

table.fixedtable.required td.required:first-child::after {
	content: "*";
	margin-left: 1px;
}

table.tablequery a.disabled {
	pointer-events: none;
	background: #808080 none repeat scroll 0 0;
}

table.tablequery{
	min-width: 60%;
}

div.section-full:not(.preview):not(.receipt) table.tablequery tfoot td[data-summarise] span {
	margin-right: 10px;
	font-family: sans-serif;
}

div.section-full:not(.preview):not(.receipt) table.tablequery tbody td span.rowsum.text-align-right {
	margin-right: 15px;
	font-family: sans-serif;
}

div.section-full.preview table.tablequery tfoot td[data-summarise] span, div.section-full.receipt table.tablequery tfoot td[data-summarise] span{
	margin-right: 5px;
}

/* ========== MOBILE ========== */
@media screen and (max-width: 767px) {
	
   table.tablequery,  table.tablequery thead,  table.tablequery th,  table.tablequery tbody,  table.tablequery tr,  table.tablequery td {
    display: block;
  }
  
   table.tablequery thead th {
    position: absolute;
    top: -9999px;
    left: -9999px;
  }
  
   table.tablequery tbody, table.tablequery tfoot {
    width: 100%;
  }
  
  table.tablequery tbody tr td div {
    overflow: hidden;
  }
  
  table.tablequery tbody td select {
		margin-right: 0;
	}
	
	table.tablequery tbody td > div {
		width: 50% !important;
	}
	
	.preview table.tablequery td, .receipt table.tablequery td{
		text-align: center;
	}
	
	table.tablequery-heading {
		padding-bottom: 10px !important;
		padding-left: 0.5em !important;
		float: none !important;
	}
	
  /* Body rows */
  table.tablequery tbody tr {
    width: 100%;
    border: 1px solid #e7e7e7;
    margin-bottom: 16px;
    box-shadow: 0 -3px #424242;
    float: left;
    background: #f7f7f7;
  }
  table.tablequery tbody tr td {
    width: 96%;
    padding: 13px 2% !important;
    border: 0;
    font-weight: 400;
    float: right;
  }
  table.tablequery tbody tr td[data-title]:before {
    float: left;
    display: block;
    content: attr(data-title);
    width: 45%;
    font-weight: 600;
    text-align: left;
  }
	table.tablequery tbody tr td.mobilehelp[data-title]:before {
		width: calc(45% - 36px);
	}
	
	table.tablequery tbody div.mobilehelp {
		width: auto !important;
		margin-right: 10px;
		margin-top: 4px;
	}
  table.tablequery tbody div.mobilehelp .help {
		position: static;
	}
  
  /* Summary rows */
   table.tablequery tfoot {
    display: table;
  }
  table.tablequery tfoot tr {
    width: 100%;
    border: 1px solid #e7e7e7;
    margin-bottom: 16px;
    box-shadow: 0 -3px #424242;
    float: left;
    background: #f7f7f7;
  }
  table.tablequery tfoot tr[data-title]:before {
    display: block;
    content: attr(data-title);
    font-weight: 600;
    text-align: left;
    padding-top: 10px;
		padding-left: 0.5em;
  }
  table.tablequery tfoot tr td:not([data-summarise='true']) {
   	display: none;
  }
  table.tablequery tfoot tr td[data-summarise='true'] {
    width: 96%;
    padding: 13px 2% !important;
    border: 0;
    font-weight: 400;
    text-align: right;
    float: right;
  }
  
  table.tablequery tfoot tr td strong {
    display: none;
  }
  table.tablequery tfoot tr td span {
    float: none;
  }
  table.tablequery tfoot tr td[data-summarise='true'][data-title]:before {
    float: left;
    display: block;
    content: attr(data-title);
    width: 45%;
    font-weight: 600;
    text-align: left;
  }
  
	table.tablequery td div.input-error i {
		display: block;
		pointer-events: none;
		position: static;
		height: auto;
		width: auto;
		margin: auto;
	}
	
	table.tablequery td .input-error .error {
		display: flex;
		align-items: center;
	}
  
  table.tablequery td.input-error input {
		padding: 12px;
	}
	
	/* TODO remove input right padding when in small mode and validation error */
}

/* The ID is needed to override the default style from openhierarchy.css (via specificity) */
#FlowBrowser.contentitem table.tablequery td .native-check-box {
	opacity: unset;
	position: unset;
	width: unset;
}
#FlowInstanceAdminModule.contentitem table.tablequery td .native-check-box {
	display: inline-block;
}

table.tablequery .input-error .error > i {
	margin: 0;
	margin-right: 5px;
}

table.tablequery .input-error i::after {
	font-size: unset;
}

table.tablequery .input-error i {
	display: inline-block;
	position: unset;
	height: 0px;
}

table.tablequery .list-search-delete {
	display: inline !important;
	margin: 0 0 0 -25px !important;
	pointer-events: all !important;
	cursor: pointer;
}

table.tablequery td > div.input-error .list-search-delete {
	right: 30px;
	bottom: 17px;
}

table.tablequery td input.list-search.value-selected {
	pointer-events: none;
	padding-right: 30px;
}

table.tablequery td > div.input-error input.list-search.value-selected {
	padding-right: 45px;
}

table.tablequery .visibility-hidden {
	visibility: hidden;
}

ul.ui-autocomplete .last-choice {
    cursor: not-allowed;
    color: gray;
    pointer-events: none; /* Prevents clicking */
}

ul.ui-autocomplete {
	border-radius: 0 0 5px 5px;
	border-style: none solid solid;
	border-width: 0 1px 1px;
	border-color: #E6E6E6;
	cursor: default;
	float: left;
	font-size: 1.1em;
	list-style: none outside none;
	margin: 0;
	padding: 2px;
	position: absolute;
	z-index: 100;
	padding: 0;
	font-size: 0.9em;
	max-height: 250px;
	overflow-y: auto;
	overflow-x: hidden;
	background-color: #FFFFFF;
}

ul.ui-autocomplete li.ui-menu-item {
	clear: left;
	float: left;
	margin: 0;
	padding: 0;
	width: 100%;
}

ul.ui-autocomplete li.ui-menu-item div {
	display: block;
	line-height: 1.5;
	text-decoration: none;
	border-bottom: 1px solid #E6E6E6;
	padding: 7px 15px;
	cursor: pointer;
}

ul.ui-autocomplete li.ui-menu-item div:hover, ul.ui-autocomplete li.ui-menu-item div.ui-state-active {
	color: #477cce;
	background: #f7f7f7;
	border-top: none;
	border-left: none;
	border-right: none;
	border-bottom: 1px solid #E6E6E6;
}

ul.ui-autocomplete li.ui-menu-item div.ui-corner-all {
	border-radius: 0;
}

.ui-helper-hidden-accessible {
	display: none;
}

.ui-autocomplete-loading {
	background: url("../pics/loading-icon.gif") no-repeat scroll right center #F3F8FF;
}

.ui-autocomplete-input {
	margin-top: 5px;
}