/*
table {
	  border-collapse: collapse;
	  font-size: 1em;
  }

td, th {
	border: 1px solid #999;
	padding: 0.5rem;
	text-align: left;
	}

tr:nth-child(even){background-color: #f2f2f2}

th {
	background-color: #4CAF50;
	color: white;
    }
*/

@import url('https://fonts.googleapis.com/css2?family=Ubuntu:wght@300;400;500;700&display=swap');

*
{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Ubuntu', sans-serif;
}

:root
{
    --blue: #287bff;
    --white: #fff;
    --grey: #f5f5f5;
    --black1: #222;
    --black2: #999;
}

.topbar
{
    width: 100%;
    height: 60px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 10px;
}

.search
{
    position: relative;
    width: 400px;
    margin: 0 10px;
}

.search label
{
    position: relative;
    width: 100%;
}

.search label select
{
    width: 100%;
    height: 40px;
    border-radius: 40px;
    padding: 5px 20px;
    padding-left: 35px;
    font-size: 18px;
    outline: none;
    border: 1px solid var(--black2);
}

.search label ion-icon
{
    position: absolute;
    top: 0;
    left: 10px;
    font-size: 1.2em;
}

.settings ion-icon
{
    position: relative;
    padding: 10px 10px;
    background: var(--blue);
    text-decoration: none;
    color: var(--white);
    border-radius: 6px;
}

.heartbeat
{
    position: relative;
    padding: 5px 5px;
    background: var(--white);
    text-decoration: none;
    color: var(--white);
    border-radius: 6px;
}

.heartbeat ion-icon
{
    position: relative;
    padding: 10px 10px;
    background: var(--white);
    text-decoration: none;
    color: red;
    border-radius: 6px; 
    transition: 0.7s;
}

.heartbeat ion-icon.md.hydrated.active
{
    transition: 0.7s;
    color: black;
}

.cardHeader
{
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
}

.cardHeader h2
{
    font-weight: 600;
    color: var(--blue);
}


#create-user
{
    position: relative;
    padding: 5px 10px;
    background: var(--blue);
    text-decoration: none;
    color: var(--white);
    border-radius: 6px;
}

.main
{
	position: relative;
    display: grid;
    min-height: 400px;
    background: var(--white);
    padding: 20px;
    box-shadow: 0 7px 25px rgba(0,0,0,0.08);
    border-radius: 20px;
}

/* chart */

.graphBox
{
    position: relative;
    width: 100%;
    padding: 20px;
    /*display: grid;
     grid-template-columns: 1fr 1fr; 
    grid-gap: 30px;
    min-height: 200px;*/
}

.graphBox .box
{
    position: relative;
    background: #fff;
    padding: 20px;
    width: 100%;
    box-shadow: 0 7px 25px rgba(0,0,0,0.08);
    border-radius: 20px;
}

.main table,
.box table
{

    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

.main table thead td,
.box table thead td
{
    font-weight: 600;
}

.main table tr,
.box table tr
{
    color: var(--black1);
    border-bottom: 1px solid rgba(0,0,0,0.1);

}

.main table tr:last-child,
.box table tr:last-child
{
    border-bottom: none;
}

.main table tbody tr:hover,
.box table tbody tr:hover
{
    background: var(--blue);
    color: var(--white);
}

.dataTable
{
    width: auto;

}

.status.normal
{
    padding: 2px 4px;
    background: #8de02c;
    color: var(--white);
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}

.status.alarm
{
    padding: 2px 4px;
    background: #f00;
    color: var(--white);
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}

.status.warning
{
    padding: 2px 4px;
    background: #f9ca3f;
    color: var(--white);
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
}
/* test tooltop */

.htooltip span { /* Внешний вид нашего тултипа */
	background-color: rgba(0,0,0, 0.8);
	border-radius: 15px 15px 15px 0px;
	box-shadow: 1px 1px 10px rgba(0, 0, 0, 0.5);
	color: #fff;
	margin-left: 2px;
	margin-top: -75px;
	opacity: 0; /* Делаем его прозрачным */
	padding: 10px 10px 10px 40px;
	position: absolute;
	text-decoration: none;
	visibility: hidden; /* И прячем */
	width: 350px;
	z-index: 10;
}
		
.htooltip:hover span { /* По hover отображаем тултип */
	opacity: 1;
	visibility: visible;
}
		
.htooltip span img { /* Изображение для примера */
	border: 0 none;
	float: left;
	margin: -71px 0 0 -234px;
	opacity: 0;
	position: absolute;
	visibility: hidden;
	z-index: -1;
}
		
.htooltip:hover span img { /* Показываем изображение */
	opacity: 1;
	visibility: visible;
}

/* end test tooltip */



/*  Popup Dialog */

/* Важная часть */
.popup__bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    opacity: 0; /* // Скрываем фон и сам попап */
    pointer-events: none; /* // Запрещаем ему быть целью событий */
    transition: 0.5s all;
}

.popup__bg.active { 
    z-index: 10000000;
    opacity: 1; /* Показываем фон и попап */
    pointer-events: all; /* Возвращаем события */
    transition: 0.5s all;
}

.popup {
    position: absolute;
    top: 50%;
    left: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    gap: 20px;

    transform: translate(-50%, -50%) scale(0); /* // Центрируем и масштабируем в 0 само окно */
    background: #1d2b3a;
    width: 400px;
    padding: 25px;
    transition: 0.5s all;
}

.popup.active { /* // При добавлении класса 'active' */
    border-radius: 5px;
    z-index: 10000000;
    transform: translate(-50%, -50%) scale(1); /* // Так же центрируем и плавно увеличиваем */
    transition: 0.5s all;
}
/* Конец важной части */
/* Далее код для стилизации формы */
.close-popup {
    position: absolute;
    top: 10px;
    right: 10px;
    font-size: 2em;
    color: #1d2b3a;
    background: #00dfc4;
    border-radius: 50%;
    cursor: pointer;
}

.inputBox,
.selectBox
{
    position: relative;
    width: 250px;
}

.inputBox input,
.selectBox select
 {
    width: 100%;
    padding: 10px;
    font-size: 18px;
    border: 1px solid rgba(255, 255, 255, 0.25);
    border-radius: 5px;
    outline: none;
    background: #1d2b3a;
    color:#fff;
    transition: 0.5s;
}

.inputBox span,
.selectBox span
{
    position: absolute;
    left: 0;
    padding: 11px;
    pointer-events: none;
    color:rgba(255, 255, 255, 0.25);
    transition: 0.5s;
}


.inputBox input:valid ~ span,
.inputBox input:focus ~ span,
.selectBox select:valid ~ span,
.selectBox select:focus ~ span
{
    color: #00dfc4;
    transform: translateX(10px) translateY(-8px);
    font-size: 0.85em;
    padding: 0 11px;
    background: #00dfc4;
    border-left: 1px solid #00dfc4;
    border-right:  1px solid #00dfc4;
    color: #1d2b3a;
    border-radius: 2px;
}

.inputBox input:valid,
.inputBox input:focus,
.selectBox select:valid,
.selectBox select:focus
{
    border: 1px solid #00dfc4;
}

.popup .button {
    width: 100%;
    height: 45px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #1d2b3a;
    font-size: 18px;
    border: 2px solid #1d2b3a;
    background: #00dfc4;
    cursor: pointer;
    text-transform: uppercase;
    transition: 0.5s all;
}

/* .popup .button:hover {
    background: #fff;
    color:#2982ff;
    transition: 0.5s all; 

}*/

 /*    head label {display: block;}
    input.text { margin-bottom:12px; width:95%; padding: .4em; }
    fieldset { padding:0; border:0; margin-top:25px; }
    h1 { font-size: 1.2em; margin: .6em 0; }
    div#users-contain { width: 350px; margin: 20px 0; }
    div#users-contain table { margin: 1em 0; border-collapse: collapse; width: 100%; }
    div#users-contain table td, div#users-contain table th { border: 1px solid #eee; padding: .6em 10px; text-align: left; }
    .ui-dialog .ui-state-error { padding: .3em; }
    .validateTips { border: 1px solid transparent; padding: 0.3em; } */


/*button { border-radius: 50%; } */

body {
	font-family: Arial, Helvetica, sans-serif;
	}

.ui-draggable, .ui-droppable {
	background-position: top;
	}

.header {
	    position: absolute;
	    top: 0%;
	    left: 0%;
	}

/* responsive design */

@media (max-width: 460px)
{
    .graphBox
    {
        grid-template-columns: 1fr;
        left: 0;
        width: 100%;
        padding: 1px;
    }

    .popup 
    {
        width: 100%;
    }
        
    .main, .box
    {
       width: 100%;
       left: 0;
       font-size: 0.9em;
    }

    .box table tr,
    .box table tr #cost .status.payed,
    .box table tr #cost .status.pending,
    .box table tr #cost .status.unpayed
    {
        font-size: 0.9em;
        padding: 1px 2px;
    }

    .dataTable
    {
        overflow-x: auto;
    }
}

@media (max-width: 680px)
{
    .graphBox
    {
        grid-template-columns: 1fr;
        left: 0;
        width: 100%;
        padding: 1px;
    }

    .popup 
    {
        width: 100%;
    }
        
    .main, .box
    {
       width: 100%;
       left: 0;
       font-size: 0.9em;
    }

    .box table tr,
    .box table tr #cost .status.payed,
    .box table tr #cost .status.pending,
    .box table tr #cost .status.unpayed
    {
        font-size: 0.9em;
        padding: 1px 2px;
    }

    .dataTable
    {
        overflow-x: auto;
    }
}
