:root {
	--main-background: white;
	--main-fonts: Arial,Helvetica,Verdana,"Helvetica Neue",sans-serif;
    --main-line-height: 1.42857143;
    --border-radius: 8px;
    --separator-color: rgb(203, 208, 221);
    --icon-color: #497caf;
    --header-background: white;
    --header-height: 3rem;
    --header-color: #497caf;
    --header-button-color: #358abb;
    --header-button-color-hover: #497caf;
	--card-background: rgba(235, 235, 235, 0.7);
    --card-border: rgba(235, 235, 235, 0.7);
	--card-color: #276C93;
    --card-shadow: rgba(100, 100, 100, 0.1);
    --application-background: rgba(245, 247, 250, 0.9);
    --sidebar-link-active-box: rgb(68, 118, 169);
    --sidebar-link-active-color: rgba(73, 124, 175);;
    --sidebar-link-color: #497caf;
    --section-background: rgba(200, 200, 200, 0.4);
    --section-color: #497caf;
    --trasparent-color: rgba(0, 0, 0, 0);
    --font-size-small: 0.8rem;

	--login-background: rgba(125, 125, 125, 0.3);
	--login-form-background: rgba(250, 250, 250, 0.9);
	--login-field-back: rgba(255, 255, 255, 0.6);
	--login-field-border: 1px;
	--login-icon-color: orange;
	--login-placeholder: orange;
	--login-button-background: #6dabe4;
	--login-button-color: white;

    /*
    #497caf -> rgba(73, 124, 175, 0.9);
	#276C93 -> rgba(39, 108, 147, 0.8);
    --header-background: #1D506E;
	--card-background: rgba(29, 80, 110, 0.8);
    */
    --color-green: #23890B;
    --color-red: #CC1B00;
    --color-light-blue: #60C6FF;
    --color-orange: #D6700A;
    --color-blue: #0097EB;
}

img.background {
	position: absolute;
	left: 0px;
	top: 0px;
	z-index: -1;
	filter: blur(5px);
	display: block;
	max-width: 100%;
	max-height: 100%;
}

html {
	-ms-text-size-adjust: 100% ;
	-webkit-text-size-adjust: 100%
}

body {
	margin: 0;
	padding: 0;
	font-family: var(--main-fonts);
	line-height: var(--main-line-height);
    background-color: var(--main-background);
    overflow: hidden;
}

a.btn > i {
    font-size: 2rem;
}

/* Header */
div.header {
	height: var(--header-height);
	width: 100%;
    background-color: var(--header-background);
    border-bottom: 1px solid var(--separator-color);
	white-space: nowrap;
    display: flex;
    flex-flow: row;
    align-items: center;
	color: var(--header-color);
    font-size: 1.8rem;
    overflow: hidden;
}

div.header > div > a.btn {
    color: var(--header-button-color)
}

div.header > div > a.btn:hover {
    color: var(--header-button-color-hover)
}

div.title {
    text-align: left;
    flex-grow: 1;
    display: inline-table;
}

div.title > img {
    margin-left: 0.3rem;
    height: 1.8rem;
}

div.user {
    white-space: nowrap;
    display: flex;
    flex-flow: row;
    text-align: right;
    align-items: center;
}

div.user > i {
    cursor: pointer;
    margin-right: 0.3rem;
}

#user-name {
    font-size: 1.1rem;
    margin-right: 1rem;
}
/* Header END */

div.main {
    width: 100%;
    height: calc(100% - var(--header-height));
    overflow: hidden;
    -webkit-background-size: cover;
    -moz-background-size: cover;
    -o-background-size: cover;
    background-size: cover !important;
	background-position: right top !important;
}
div.main > div.container {
    height: 100%;
    overflow: hidden;
}

/* DASHBOARD */
#dashboard {
    height: calc(100vh - var(--header-height));
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column-reverse;
    overflow-y: auto;
    overflow-x: hidden;
}

div.dashboard-item {
	padding: 0.3rem;
    margin-left: 0.3rem;
    margin-right: 0.3rem;
}

div.dashboard-item > div > img {
    max-width: 180px;
	opacity: 0.9;
    margin-left: auto;
    margin-right: auto;
    margin-top: 2px;
    margin-bottom: 2px;
}

div.dashboard-item > div {
    background-color: var(--card-background);
	width: 12rem;
	height: 16rem;
	cursor: pointer;
	padding: 0.3rem;
	margin-bottom: 0.3rem;
	border-radius: 10px;
	box-shadow: 4px 5px 5px 5px var(--card-shadow);
    border: 1px solid var(--card-border);
}

div.dashboard-item > div > div {
	text-align: center;
}

div.dashboard-item > div > div > h5 {
	margin-bottom: 0;
    color: var(--card-color);
    font-size: 1.8rem;
}

@media (max-width: 768px) {
    body, .main {
        overflow-x: hidden !important;
    }
    #dashboard {
        margin: 5px;
        flex-direction: column;
	    justify-content: start;
    }
    #dashboard > div {
        padding: 0px;
    }
    div.dashboard-item > div {
        width: 9rem;
        height: 12rem;
    }
    div.dashboard-item > div > img {
        max-width: 122px;
    }
    div.dashboard-item > div > div > h5 {
        font-size: 1.2rem;
    }
}
/* DASHBOARD END */

/* Application */
div.application {
    background-color: var(--application-background);
    height: 100%;
    display: flex;
    flex-flow: row;
    overflow-y: auto;
    overflow-x: hidden;
}

div.application > div:last-child {
    flex-grow: 1;
    padding-left: 2px;
}

.sidebar {
    margin-top: var(--header-height);
    width: 280px !important;
    height: 3rem;
    position: fixed;
    top: 0;
}
.sidebar > div.list-group {
    margin-top: 2px;
}

.sidebar > div.list-group > a > span {
    font-size: 1rem;
}

.sidebar > div.list-group > a {
    color: var(--sidebar-link-color);
}

.sidebar > div.list-group > a.active {
    color: var(--sidebar-link-active-color);
    background-color: var(--trasparent-color);
    border-color: var(--sidebar-link-active-box);
}

.sidebar-icon {
    margin-right: 0.4rem;
    vertical-align: middle !important;
}
.sidebar-right {
    margin-left: 280px;
}
@media (max-width: 768px) {
    div.main > div.container {
        padding-left: 2px;
        padding-right: 2px;
    }
    .sidebar {
        width: 5rem !important;
    }
    .sidebar-right {
        margin-left: 5rem !important;
    }
    .sidebar > div.list-group > a {
        padding-left: 0px;
        padding-right: 0px;
        text-align: center;
        width: 100%;
    }
    .sidebar > div > span,
    .sidebar > hr,
    .sidebar > div.list-group > a > span {
        display: none;
    }
	.sidebar-icon {
	    margin-right: 0rem;
	}
}
/* Application END*/

.section-title {
    position: relative;
}

.section-title > div {
    color: var(--section-color);
    background-color: var(--section-background);
    text-align: center;
    margin-top: 1rem;
    margin-bottom: 1rem;
}

.section-title > p {
    border: 2px solid var(--section-color);
    color: var(--section-color);
    background-color: white;
    border-radius: 1.5rem;
    padding: 0.2rem;
    position: absolute;
    top: -0.5rem;
    right: 1rem;
    width: 2.5rem;
    height: 2.5rem;
}

.section-title > p > span {
    position: relative;
    top: 0.25rem;
}

.section-box {
    background-color: white;
    border-radius: var(--border-radius);
    border: 1px solid var(--separator-color);
    margin: 2px;
    padding: 4px;
}

div.temperatures > div.col {
    text-align: center;
}

div.temperatures > div.col > p {
    margin-bottom: 0px;
}
div.temperatures > div.col > p:first-child {
    color:#276C93
}
div.temperatures > div.col > p:last-child {
    color: var(--separator-color);
    font-size: var(--font-size-small);
}
div.icon-list-left {
    display: flex;
    flex-flow: row;
    width: 100%;
    margin-bottom: 0.5rem;
}
div.icon-list-left > div:last-child {
    flex-grow: 1;
    margin-left: 6px;
}
div.icon-list-left > div:last-child > label {
    margin-bottom: 0px;
}

.input-label > label {
    font-size: 0.75rem;
    color: var(--section-color);
}

.form-check-input {
	font-size: 1.3rem;
	margin-left: -30px !important;
}
.form-check-label {
	margin-top: .25rem;
}

.slider-temperature {
    position: relative;
}

.slider-temperature > div:first-child {
    position: absolute;
    padding: 0.25rem;
    font-size: 0.75rem;
    width: auto !important;
    border-bottom: 1px solid var(--section-color);
    color: var(--section-color);
}  
.slider-temperature > div:last-child {
    display: flex;
    flex-direction: row;
    margin-top: 30px;
    color: var(--section-color);
}
.slider-temperature > div:last-child > div:nth-of-type(2) {
    margin-left: 4px;
    margin-right: 4px;
    flex-grow: 1;
    text-align: center;
}
.slider-temperature > div:last-child > div:nth-of-type(2) > label {
    color: var(--separator-color);
    font-size: var(--font-size-small);
}

.slider-temperature > div:last-child > div:nth-of-type(2) > input.off[type=range]::-webkit-slider-thumb {
    background-color: red;
}
.slider-temperature > div:last-child > div:nth-of-type(2) > input.off[type=range]::-moz-range-thumb {
    background-color: red;
}
.slider-temperature > div:last-child > div:nth-of-type(2) > input.on[type=range]::-webkit-slider-thumb {
    background-color: green;
}
.slider-temperature > div:last-child > div:nth-of-type(2) > input.on[type=range]::-moz-range-thumb {
    background-color: green;
}

.icon {
    width: 2.5rem;
    height: 2.5rem;
}

.icon-radiator {
    background-color: var(--icon-color); /* defines the background color of the image */
    mask: url(../images/radiator.svg) no-repeat center / contain;
    -webkit-mask: url(../images/radiator.svg) no-repeat center / contain;
}
.icon-air {
    background-color: var(--icon-color); /* defines the background color of the image */
    mask: url(../images/air.svg) no-repeat center / contain;
    -webkit-mask: url(../images/air.svg) no-repeat center / contain;
}
.color-red {
    color: var(--color-red);
}
.color-green {
    color: var(--color-green);
}
.color-blue {
    color: var(--color-blue);
}
.color-orange {
    color: var(--color-orange);
}
.color-light-blue {
    color: var(--color-light-blue);
}

.row-header {
    text-align: center;
    background-color: var(--section-background);
    margin-left: 0;
    margin-right: 0;
    margin-top: 0.2rem;
    margin-bottom: 0.2rem;
    border-radius: 5px;
    color: var(--section-color);
}

.col-header {
	margin: 0.3rem;
}

@media (max-width: 768px) {
    .slider-temperature > div:first-child {
        font-size: 0.9rem;
    }
    input[type=range]::-webkit-slider-thumb {
        height: 24px;
        width: 24px;
        border-radius: 12px;

    }
    input[type=range]::-webkit-slider-runnable-track {
        height: 16px;
    }
    input[type=range]::-moz-range-thumb {
        height: 36px;
        width: 36px;
        border-radius: 12px;
    }
    .slider-temperature > div:last-child {
        margin-top: 30px;
    }
  
}

.domotic-location {
	color: var(--section-color);
    background-color: val(--section-background);
	text-align: center;
	font-size: 1rem;
	padding-top: 0.3rem;
	padding-bottom: 0.3rem;
	margin-top: 0.3rem;
	margin-bottom: 0.3rem;
}

.domotic-thermometer-title {
	position: relative;
}

.domotic-thermometer-title > div {
	color: var(--section-color);
    background-color: val(--section-background);
    text-align: center;
    margin-top: 1.5rem;
    margin-bottom: 1.5rem;
}

.domotic-thermometer-title > p {
	border: 2px solid var(--section-color);
    color: var(--section-color);
    background-color: white;
    border-radius: 1.5rem;
    padding: 0.2rem;
    position: absolute;
    top: -0.5rem;
    right: 1rem;
    width: 2.5rem;
    height: 2.5rem;
}
.domotic-thermometer-title > p > span {
    position: relative;
    top: 0.25rem;
}

.domotic-thermometer-title> div.float-end {
	color: green;
	margin: 0.3rem;
	text-align: center;
}
.domotic-thermometer-title> div.float-end > label {
	font-size:0.7rem;
	color: #ababab;
	margin-top: -0.3rem;
}

.domotic-box {
    background-color: white;
    border-radius: 5px;
    border: 1px solid rgb(203, 208, 221);
    margin: 2px;
    padding: 4px;
}

.domotic-window {
	text-align: center;
}

.domotic-window > div {
	font-size: var(--font-size-small);
	color: var(--icon-color);
}

.domotic-window > div > button {
	background-color: var(--card-background);
	color: var(--icon-color) !important;
}

.domotic-window-open {
	font-weight: bold;
	color: red !important;
}

.domotic-window > div > button > i{
	font-size: xx-large;
}

.domotic-device {
	margin-top: 0.5rem;
	margin-bottom: 0.5rem;
}

.domotic-switch {
	max-width: 24px;
}

.domotic-div {
	padding-bottom: 1rem;
}

.login {
	position: absolute;
	top: 0;
	bottom: 0;
	left: 0;
	right: 0;
	margin-top: auto;
	margin-bottom: auto;
	margin-left: auto;
	margin-right: auto;
	max-width: 600px;
	max-height: 400px;
    border-radius: 20px;
    box-shadow: 10px 10px 10px 10px rgb(0, 0, 0, 0.1);
    background-color: var(--login-background);
}

.login > div {
	height: 100%;
}

.login > div > div:first-child {
    border-radius: 15px 0 0 15px;
	align-content: center;
}

.login > div > div:last-child {
	display: block;
    border-radius: 0 15px 15px 0;
    background-color: #7ba2c7;
}

.login > div > div:last-child > img {
	opacity: 1;
	width: 100%;
}

#login-form {
	position: absolute;
	top: 0;
	bottom: 0;
	margin-top: auto;
	margin-bottom: auto;
	margin-left: 15px;
	max-height: 170px;
}

.login-control {
    height: 50px;
	margin-bottom: 10px;
    font-weight: 600;
	text-align: center;
}

#login-form > button {
    background-color: var(--login-button-background);
    color: var(--login-button-color);
    border: medium none;
    font-size: 20px;
    font-weight: 600;
    height: 50px;
    border-radius: 5px;
    width: 100%;
	min-width: 250px;
	
}
