@font-face {
	font-family: 'Tahoma';
	src: url('/fonts/tahoma.ttf');
}

:root{
  --cst-bg-body: #FAFAFA;
  --cst-dark: #3C3E43;
	--cst-blue: #005D98;
	--cst-light-blue: #F4F5F7;
	--cst-red: #ff0000;
	--cst-gray: #9FA1A6;
	--cst-green: #56C168;

	--cst-box-shadow: 0 4px 48px rgba(0, 0, 0, 0.04);
	--cst-box-shadow-sm: 0 2px 48px rgba(0, 0, 0, 0.04);
}

*{
  box-sizing: border-box;
  margin: 0;
  font-family: 'Tahoma';
	font-size: 14px;
  font-weight: 400;
  letter-spacing: 1px;
  color: var(--cst-dark);
}

body{
  margin: 0;
  background-color: var(--cst-bg-body);
}

small, .small{
	font-size: 12px;
}

a{
	text-decoration: none;
	color: var(--cst-dark);
}

.header{
  padding: 40px 0 20px;
}

.title{
  font-size: 16px;
}

.wrapper{
  padding: 50px;
  background-color: #ffffff;
  border-radius: 12px;:
}

.shadow{
  box-shadow: var(--cst-box-shadow);
}

.menu-hamburger{
  position: relative;
  width: 40px;
  height: 40px;
  background-color: #ffffff;
  border-radius: 12px;
  box-shadow: var(--cst-box-shadow-sm);
  cursor: pointer;
  z-index: 3;
}

.menu-line{
  position: absolute;
  left: 9px;
  right: 9px;
  height: 2px;
  background-color:var(--cst-dark);
  transition: .3s;
}

.menu-line:first-child{
  top: 12px;
}

.menu-line:last-child{
  bottom: 12px;
}

.menu-line:nth-child(2),
.menu-line:nth-child(3){
  top: calc(50% - 1px);
}

.menu-hamburger.open{
	background-color: var(--cst-light-blue);
}

.menu-hamburger.open .menu-line:first-child{
  top: calc(50% - 1px);
  opacity: 0;
  transition: .3s;
}

.menu-hamburger.open .menu-line:last-child{
  bottom: calc(50% - 1px);
  opacity: 0;
  transition: .3s;
}

.menu-hamburger.open .menu-line:nth-child(2){
  transform: rotate(45deg);
  transition: .3s;
}

.menu-hamburger.open .menu-line:nth-child(3){
  transform: rotate(-45deg);
  transition: .3s;
}

.menu{
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
	transform: translateX(-400px);
  padding: 90px 17px;
  width: min(90vw, 340px);
  background-color: #ffffff;
  z-index: 2;
	transition: .10s;
}

.menu.open{
	transform: translateX(0);
	transition: .5s;
}

.menu a{
	text-decoration: none;
	transition: .5s;
}

.menu a:hover{
	text-decoration: none;
	color: var(--cst-blue);
	transition: .5s;
}

.menu ul{
	padding-left: 0;
	list-style: none;
	margin-top: 12px;
}

.menu ul li{
	display: block;
	padding: 12px 0;
}

.menu ul li + li{
	border-top: 1px solid var(--cst-light-blue);
}

.btn-output{
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	display: flex;
	align-items: center;
	gap: 6px;
	text-decoration: none;
	padding: 20px 12px;
	letter-spacing: 1.6px;
	border-top: 1px solid var(--cst-light-blue);
	transition: .5s;
}

.btn-output::before{
	content: '';
	display: block;
	width: 27px;
	height: 27px;
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 21 21' xmlns='http://www.w3.org/2000/svg' fill='%23000000'%3E%3Cg id='SVGRepo_bgCarrier' stroke-width='0'%3E%3C/g%3E%3Cg id='SVGRepo_tracerCarrier' stroke-linecap='round' stroke-linejoin='round'%3E%3C/g%3E%3Cg id='SVGRepo_iconCarrier'%3E%3Cg fill='none' fill-rule='evenodd' stroke='%233C3E43' stroke-linecap='round' stroke-linejoin='round' transform='matrix(-1 0 0 1 18 3)'%3E%3Cpath d='m10.595 10.5 2.905-3-2.905-3'%3E%3C/path%3E%3Cpath d='m13.5 7.5h-9'%3E%3C/path%3E%3Cpath d='m10.5.5-8 .00224609c-1.1043501.00087167-1.9994384.89621131-2 2.00056153v9.99438478c.0005616 1.1043502.8956499 1.9996898 2 2.0005615l8 .0022461'%3E%3C/path%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	transition: .5s;
}

.btn-output:hover{
	color: var(--cst-red) !important;
	transition: .5s;
}

.btn-output:hover::before{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 21 21' xmlns='http://www.w3.org/2000/svg' fill='%23000000'%3E%3Cg id='SVGRepo_bgCarrier' stroke-width='0'%3E%3C/g%3E%3Cg id='SVGRepo_tracerCarrier' stroke-linecap='round' stroke-linejoin='round'%3E%3C/g%3E%3Cg id='SVGRepo_iconCarrier'%3E%3Cg fill='none' fill-rule='evenodd' stroke='%23ff0000' stroke-linecap='round' stroke-linejoin='round' transform='matrix(-1 0 0 1 18 3)'%3E%3Cpath d='m10.595 10.5 2.905-3-2.905-3'%3E%3C/path%3E%3Cpath d='m13.5 7.5h-9'%3E%3C/path%3E%3Cpath d='m10.5.5-8 .00224609c-1.1043501.00087167-1.9994384.89621131-2 2.00056153v9.99438478c.0005616 1.1043502.8956499 1.9996898 2 2.0005615l8 .0022461'%3E%3C/path%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
	transition: .5s;
}

.btn-view{
	position: relative;
	width: 20px;
	height: 20px;
	background-image: url("data:image/svg+xml,%3Csvg width='4' height='20' viewBox='0 0 4 20' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='2' cy='10' r='1' stroke='%233C3E43' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3Ccircle cx='2' cy='2' r='1' stroke='%233C3E43' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3Ccircle cx='2' cy='18' r='1' stroke='%233C3E43' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
	background-repeat: no-repeat;
	background-position: right;
}

.menu-view{
	display: none;
	position: absolute;
	top: calc(100% + 5px);
	right: 0;
	border-radius: 12px;
	background-color: #ffffff;
	padding: 12px;
	box-shadow: var(--cst-box-shadow-sm);
	z-index: 3;
}

.btn-view:hover .menu-view{
	display: block;
}

.btn-view:hover .menu-view::before{
	content: '';
	position: absolute;
	top: -7px;
	left: 0;
	right: 0;
	height: 13px;
	z-index: 2;
}

.menu-view ul{
	list-style: none;
	padding-left: 0;
}

.menu-view a{
	text-decoration: none;
}

.menu-view li{
 display: block;
 padding: 10px;
}

.menu-view li + li{
 border-top: 1px solid var(--cst-light-blue);
}

.menu-view li:first-child{
	padding-top: 0;
}

.menu-view li:last-child{
	padding-bottom: 0;
}

.text-gray{
	color: var(--cst-gray);
}

.room-map{
	width: 100%;
}

.box{
	position: relative;
	padding: 14px;
	border-radius: 14px;
	background-color: #ffffff;
	box-shadow: var(--cst-box-shadow-sm);
}

.device:has(.stretched-link):hover{
	box-shadow: 0 2px 15px rgba(0, 0, 0, 0.14);
}

.device__type{
	padding: 9px;
	background-color: var(--cst-light-blue);
	border-radius: 14px;
}

.device__type img{
	width: 34px;
	height: 34px;
	-moz-object-fit: contain;
	-o-object-fit: contain;
	object-fit: contain;
}

.device__values{
	display: flex;
	align-items: center;
	height: 100%;
}

.device__value{
	display: flex;
	align-items: center;
	font-size: 22px;
	color: var(--cst-blue);
}

.device__value + .device__value::before{
	content: '/';
	color: var(--cst-dark);
  font-size: 20px;
  margin-top: -3px;
  margin-right: 5px;
  margin-left: 5px;
}

.val-temperature::after{
	content: '°';
}

.val-humidity::after{
	content: '%';
}

.device__values.power-disconnect .device__value,
.device__values.power-disconnect .device__value + .device__value::before{
	color: var(--cst-gray);
}

.device__status{
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 12px;
	color: var(--cst-gray);
	margin-top: 7px;
}

.device__status::before{
	content: '';
	width: 8px;
	height: 8px;
	border-radius: 50%;
	background-color: var(--cst-green);
}

.device__status.power-disconnect::before{
	background-color: var(--cst-red);
}

.device__status::after{
	content: 'Онлайн';
}

.device__status.power-disconnect::after{
	content: 'Нет сигнала';
}

.device__switch{
	width: 26px;
	height: 100%;
	background-position: center;
	background-repeat: no-repeat;
}

.device__switch.power-on{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0071' cy='14' r='13' fill='%2356C168' stroke='%2356C168' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0071 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
}

.device__switch.power-disconnect{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0071' cy='14' r='13' fill='%23DBDDE2' stroke='%23DBDDE2' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0071 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
}

.device__switch.power-off{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0068' cy='14' r='13' fill='%233C3E43' stroke='%233C3E43' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0068 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
}

input.device__switch{
	position: relative;
	opacity: 0;
	z-index: 1;
	cursor: pointer;
}

input.device__switch + label{
position: absolute;
top: 0;
bottom: 0;
left: 0;
right: 0;
cursor: pointer;
}

input.device__switch + label::before{
	content: '';
	display: block;
	width: 26px;
	height: 100%;
	background-position: center;
	background-repeat: no-repeat;
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0068' cy='14' r='13' fill='%233C3E43' stroke='%233C3E43' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0068 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
	z-index: 0;
}

input.device__switch:checked + label::before{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0071' cy='14' r='13' fill='%2356C168' stroke='%2356C168' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0071 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
}

input.device__switch[value="disconnect"]{
	pointer-events: none;
}

input.device__switch[value="disconnect"] +  label::before{
	background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 28 28' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Ccircle cx='14.0071' cy='14' r='13' fill='%23DBDDE2' stroke='%23DBDDE2' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M11.7404 7.64374C9.09894 8.5776 7.20703 11.0959 7.20703 14.0569C7.20703 17.8128 10.2512 20.8569 14.007 20.8569C17.7629 20.8569 20.807 17.8128 20.807 14.0569C20.807 11.0959 18.9151 8.5776 16.2737 7.64374' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3Cpath d='M14.0071 4.60001V13' stroke='white' stroke-width='1.8' stroke-linejoin='round'/%3E%3C/svg%3E%0A");
}

.command{
	padding: 14px 8px;
	cursor: pointer;
	transition: .3s;
}

.command:hover{
	box-shadow: 0 2px 15px rgba(0, 0, 0, 0.14);
	transition: .3s;
}

[data-status='active'].command{
	background-color: var(--cst-green);
	transition: .3s;
}

.command_icon{
	display: flex;
	align-items: center;
  justify-content: center;
	width: 52px;
	height: 52px;
	margin: auto;
	background-color: #ffffff;
	border-radius: 14px;
	transition: .3s;
}

.command_icon img{
	width: 26px;
	height: 26px;
	filter: brightness(0) opacity(0.5);
	transition: .3s;
}

[data-status='active'].command .command_icon img{
	filter: none;
	transition: .3s;
}

.command_name{
	margin-top: 14px;
	font-size: 12px;
	text-align: center;
	color: var(--cst-dark);
	transition: .3s;
}

[data-status='active'].command .command_name{
	color: #ffffff;
	transition: .3s;
}

button{
	border: none;
	outline: none;
	background-color: transparent;
	cursor: pointer;
}

.btn{
	display: inline-block;
	padding: 14px;
	border: none;
	border-radius: 14px;
	background-color: var(--cst-blue);
	font-size: 12px;
	text-align: center;
	color: #fff;
	cursor: pointer;
	transition: .3s;
}

.btn:hover{
	filter: brightness(.95);
	transition: .3s;
}

.chart,
.map-room{
	position: relative;
	height: calc(100vh - 200px);
	overflow: hidden;
}

.map-room{
	width: 100%;
	height: calc(100vh - 250px);
}

.sensor{
	--line-width: 4px;
	--line-color: #EDEEEF;
	--line-color-active: #005D98;
	--line-sm-hight: 80px;
	--line-lg-hight: 120px;

	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 40px;
}

.sensor span{
	display: block;
	position: relative;
	width: var(--line-width);
	height: var(--line-sm-hight);
	background-color: var(--line-color);
}

.sensor span:nth-child(5n){
	height: var(--line-lg-hight);
}

.sensor span.active{
	background-color: var(--line-color-active);
}

.sensor span[data-value]::after{
	content: "";
	position: absolute;
	bottom: -30px;
	left: calc(-50% + 10px);
	transform: translateX(-50%);
	font-size: 24px;
	color: var(--line-color);
}

.sensor span.active::after{
	color: var(--line-color-active);
}

.sensor[data-type="temperature"] span[data-value]::after{
	content: attr(data-value) "°";
}

.sensor[data-type="humidity"] span[data-value]::after{
	content: attr(data-value) "%";
}

.svg-floor{
	fill: #F7F7F7;
}

.svg-floor[data-opacity='0']{
	opacity: 0;
}

.svg-floor[data-opacity='0.1']{
	opacity: .1;
}

.svg-floor[data-opacity='0.2']{
	opacity: .2;
}

.svg-floor[data-opacity='0.3'] {
	opacity: 0;
	animation: fadeIn3 1s forwards infinite;
}

@keyframes fadeIn3 {
	0% {
		opacity: 0.2;
	}
	100% {
		opacity: 0.3;
	}
}

.svg-floor[data-opacity='0.4'] {
	opacity: 0;
	animation: fadeIn4 1s forwards infinite;
}

@keyframes fadeIn4 {
	0% {
		opacity: 0.3;
	}
	100% {
		opacity: 0.4;
	}
}

.svg-floor[data-opacity='0.5'] {
	opacity: 0;
	animation: fadeIn5 1s forwards infinite;
}

@keyframes fadeIn5 {
	0% {
		opacity: 0.4;
	}
	100% {
		opacity: 0.5;
	}
}


.svg-floor[data-opacity='0.6'] {
	opacity: 0;
	animation: fadeIn6 1s forwards infinite;
}

@keyframes fadeIn6 {
	0% {
		opacity: 0.5;
	}
	100% {
		opacity: 0.6;
	}
}

.svg-floor[data-opacity='0.7'] {
	opacity: 0;
	animation: fadeIn6 1s forwards infinite;
}

@keyframes fadeIn7 {
	0% {
		opacity: 0.6;
	}
	100% {
		opacity: 0.7;
	}
}

.svg-floor[data-opacity='0.8'] {
	opacity: 0;
	animation: fadeIn8 1s forwards infinite;
}

@keyframes fadeIn8 {
	0% {
		opacity: 0.7;
	}
	100% {
		opacity: 0.8;
	}
}

.svg-floor[data-opacity='0.9'] {
	opacity: 0;
	animation: fadeIn9 1s forwards infinite;
}

@keyframes fadeIn9 {
	0% {
		opacity: 0.8;
	}
	100% {
		opacity: 0.9;
	}
}

.svg-floor[data-opacity='1']{
	opacity: 1;
}

.svg-device-temperature{
	fill: var(--cst-blue);
	font-weight: bold;
	font-size: 6px;
  letter-spacing: 0.3px;
}

.svg-device-temperature::after{
	content: '°';
}

.svg-device-status.power-on{
	fill: var(--cst-green);
	stroke: var(--cst-green)
}

.svg-device-status.power-disconnect{
	fill: var(--cst-red);
	stroke: var(--cst-red);
}

.svg-sensor .svg-device-status,
.svg-sensor .svg-device-status + path,
.svg-sensor .svg-device-status + path + path{
	display: none;
}

.svg-sensor .svg-device-status.power-disconnect,
.svg-sensor .svg-device-status.power-disconnect + path,
.svg-sensor .svg-device-status.power-disconnect + path + path{
	display: block;
}

.svg-ventilation.heating .svg-device-temperature,
.svg-ventilation.heating > path[fill="#005D98"]{
	fill: var(--cst-red);
}

.svg-ventilation.heating.power-off > path[fill="#005D98"]{
	fill: #005D98;
}

.svg-device.power-off > rect[fill="white"]{
	stroke: var(--cst-dark);
	stroke-width: 0.5px;
}

.svg-device.power-disconnect > rect[fill="white"]{
	stroke: #F9B9B9;
	stroke-width: 0.5px;
}

.svg-device.power-disconnect > path[fill="#005D98"]{
	fill: #F9B9B9;
}

.svg-device.power-disconnect text,
.svg-device.power-off text{
	display: none;
}

svg a:hover{

}
