.calculator {
	position: relative;
	margin: 0 auto;
	padding: 0;
	background-color: #f3f3f3;
	border-radius: 0;
	box-shadow: 5px 5px 15px 3px #bdbdbd;
	font-family: inherit;
}

.calc-row {
  text-align: center;
  direction: ltr;
  display: flex;
  width: 100%;
}
.calc-row.screen-row {
    display: flex;
    flex-direction: column;
}
.calc-row div.logscreen{
	display: table;
    width: 100%;
    background-color: #f3f3f3;
    text-align: right;
    font-size: 16px;
    line-height: 16px;
    margin-left: 0;
    padding-right: 0.5em;
    margin: 0;
    color: #b1b1b1;
	height:52px;
}
.calc-row div.screen {
  display: table;
  width: 100%;
  background-color: #f3f3f3;
  text-align: right;
  font-size: 2em;
  min-height: 1.2em;
  margin-left: 0;
  padding-right: 0.5em;
  border: 2px solid #888;
  color: #333;
  margin: 0;
  height: 104px;
}

.calc-row div {
  text-align: center;
  border: 0;
  background-color: #fff;
  padding: 18px 0;
  border-radius: 0;
  float: left;
  width: calc(25% - 2px);
  color: #000;
  margin: 1px;
  text-transform: inherit;
  font-family: arial;
  font-weight: 600;
  font-size: 17px;
}

.calc-row.screen-row {
    margin: 0 0 10px 0;
}
.calc-title {
    padding-right: 8px;
    font-weight: 600;
}
.calc-row div:hover {
    cursor: pointer;
    background: #ccc;
    color: #000;
}

.calc-row div.disabled:hover {
    cursor: default;
    background: #fff;
    color: #000;
}
.calc-row.screen-row div:hover {
    background: unset;
    cursor: default;
}


#calcModal {
  position: relative;
}

.calc-modal-dialog {
  position: fixed;
  width: 100%;
  margin: 0;
  padding: 10px;
}
.calc-modal .modal-body {
    padding: 0;
}

.calc-modal  .modal-header {
    background: #f9f9f9;
    padding: 4px 11px;
}

.calc-modal  h4.modal-title {
    margin-bottom: 0;
	text-align: right;
	color: #6c757d;
}
div.modal.calc-modal {
    width: 400px;
    max-width: 100%;
}
.modal.calc-modal {
	border-radius: 0;
}
.modal.calc-modal button.close {
    padding-top: 6px;
    font-size: 1.75em;
    color: #ca4040;
    opacity: 1;
}
button#calc-btn {
	background: #e5ecf2;
    padding: 0px 0px 0px 6px;
    height: 40px;
    border: 1px solid#b7cada;
    border-radius: 4px;
    color: #4d4d4d;
}

button#calc-btn i.far.fa-calculator {
	font-size: 22px;
    line-height: 39px;
    margin-right: 4px;
}

button#calc-btn span {
    vertical-align: top;
    line-height: 40px;
    font-size: 14px;
	font-weight: 500;
}
.moduletable.calc-module {
    text-align: left;
}
.calc-modal .modal-header.ui-draggable-handle {
    cursor: move;
}
@media only screen and (max-width: 979px){
	div.modal.calc-modal,
	div.modal.fade.in.calc-modal{
		width: 400px !important;
		max-width: 90%;
		height: auto !important;
		left: 0 !important;
		margin: 0 auto !important;
		bottom: 100px;
		top: auto !important;
	}
	.calc-row div{
		padding: 15px 0;
	}
	.calc-row div.screen {		
		padding: 0 0.5em;
		margin: 0;
		height: 70px;
		
	}
	.calc-row div.logscreen {
		padding: 6px 0.5em;
		height: 30px;
	}
	.modal.calc-modal button.close {
		margin: 3px 0px 0 -10px;
	}
	div#rpp-calculator {position: relative;}

	div#rpp-calculator .moduletable.calc-module {
		position: absolute;
		left: 0;
		padding-top: 12px;
		z-index: 9;
	}
	button#calc-btn {
		background: #ffffff;
		height: 40px;
		border: 1px solid #6c757d;
		border-radius: 4px;
		color: #6c757d;
		padding: 0 10px;
	}
	button#calc-btn i.far.fa-calculator {
		font-size: 16px;
		margin-right: 4px;
	}
	button#calc-btn span {
		vertical-align: top;
		line-height: 40px;
		font-size: 12px;
		font-weight: 500;
	}
}