/* Variable declarations */
:root {
	/*en mobile es sobrescrito a 100%*/
	--menubar_width: 240px;

	/*en desktop es sobrescrito a 100dvh*/
	--menubar_height: 75px;

	--background-color: white;
/*	--background-color-variation: #f3f3f3;*/
	--background-color-variation: #e2e7ef;
	--border-color: #e5e5e5;

	--default-border-radius: 15px;
}
a{
	color: var(--color_accent);
	text-decoration: none;
}
a:hover{
	color: var(--color_accent_hover);

}

#app{
	position: relative;

	min-height: 100dvh;

	color: #2b323a;
}
.menubar{
	position: fixed!important;
	z-index: 2;
	background-color: var(--background-color);

	display: flex;
	gap: 7px;

	overflow-y: auto;
	font-size: 0.9em;
}
.menubar::-webkit-scrollbar{ width: 2px; }
.menubar::-webkit-scrollbar-thumb{ background-color: rgba(0,0,0,0.2)}

.menu-logo{
	margin: 20px 30px 0px 10px;
}
.menu-logo img{
	width: 100%;
}
.menu-group{
	display: flex;
	gap: 3px;

	padding: 10px;
	font-size: 0.9em;	
}
.menu-subtitle{
	position: relative;
	padding: 0px 20px;
	font-size: 88%;
	padding-bottom: 10px;

	user-select: none;
}
.menu-subtitle:before{
	content: '—';
	font-weight: bold;
	color: var(--color_accent);
	padding-right: 22px;
}
.menu-group a > span{
	position: relative;
	padding: 3px 15px;

/*	min-height: 36px;*/

	display: flex;
	flex-flow: row nowrap;
	align-items: center;
	gap: 20px;

	color: #1e1c1c;
	font-weight: bold;
	font-weight: 600;
	border-radius: 5px;
	user-select: none;
	overflow: hidden;

	background-color: rgba(0,0,0,0);
}

.menu-group a{
	position: relative;
	transition: 0.1s ease;
}
.menu-group a:not(.active):hover > span{
	background-color: rgba(0,0,0,0.06);
}

.menu-group a i{
	font-size: 1.3em;
}

.menu-group a.active{
/*	pointer-events: none;*/
	cursor: default;
}
.menu-group a.active > span{
	color: var(--color_accent);
	background: #f3f3f3;
}

.menu-group a.active:before{
	content: "";
	position: absolute;
	background: var(--color_accent);
	margin: auto;
	z-index: 2;
}

.content{
	position: relative;
	background-color: var(--background-color-variation);
	color: var(--black);

	min-height: 100dvh;

	display: flex;
	flex-flow: column nowrap;

	font-size: 0.9em;
}
#app:has( > .menubar ) > .content{
	padding-left: var(--menubar_width);
	padding-bottom: var(--menubar_height);
}

.detail{
	transition: 0.1s ease;
	opacity: 0.6;
	user-select: none;
}
.detail:hover{
	opacity: 1;
}

.tab-content:not(.active){
	display: none !important;
}

.card, .subcard{
	box-shadow: 0px 2px 2px rgba(0,0,0,0.015);
}
.card{
	background-color: white;
	padding: 20px;
	border-radius: var(--default-border-radius);
}
.subcard{
	background-color: #f1f1f1;
/*	padding: 10px;*/
	border-radius: calc(var(--default-border-radius) - 2px);
}

.bordered{
	border: solid 1px #0000000f;
}

table {
    caption-side: bottom;
    border-collapse: collapse;
}
.table {
    width: 100%;
    color: #697a8d;
    vertical-align: middle;
    border-radius: 3px;
    overflow: hidden;
    box-shadow: 0px 2px 3px rgba(0,0,0,0.07);
}
.table thead th {
	padding: 0.625rem 10px;
	border-bottom-width: 1px;
}
.table tbody td {
	padding: 5px 10px;
	border-bottom-width: 1px;
}
.table tbody tr:nth-child(odd) {
	background: #00000002;
}
.table tbody tr:nth-child(even) {
	background: #00000008;
}

.table tbody tr td:nth-child(even) {
	background: #00000005;
}
.table > tbody {
	vertical-align: inherit;
}
.table > thead {
	vertical-align: bottom;
}
.table > :not(:first-child) {
	border-top: 2px solid #d9dee3;
}
.table > thead {
    vertical-align: bottom;
    background-color: #eee;
}
.table th{
	color: #566a7f;
}

table tbody td:empty::after {
	content: '-';
}


.table th.sortable{
	user-select: none;
	cursor: pointer;
}
.table th.sortable:hover{
	color: var(--color_accent);
}
.table th.sortable.active{
	background-color: #e9e9e9;
}
.table th.sortable .sorticon{
	font-size: 80%;
}
.table th.sortable:not(.active) .sorticon{
	display: none;
}


.form-group{
	display: flex;
	flex-flow: row wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 1rem;
}
.form-group > label{
	width: 150px;
	color: var(--black);
	font-size: 90%;
}
.form-group > .fancyInput{
	font-size: 90%;
	flex: 1;
	width: 100%;
	min-width: 300px;
}
.form-group > .fancyInput::placeholder{
	opacity: 0.7;
}

label:has(+[required]) {
	position: relative;
}
label:has(+[required]):after {
	content: ' *';
	color: #ff0068;
}


.pagination{
	display: flex;
	flex-flow: row nowrap;
	align-items: stretch;
	width: fit-content;
	border: solid 1px #e9e9e9;
	border-radius: 15px;
	background-color: white;
	overflow: hidden;
}
.pagination > div{
	cursor: pointer;
	user-select: none;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 5px;
	padding: 10px;
	min-width: 15px;
	transition: 0.05s ease;
}
.pagination > div:hover, .pagination > div:focus{
	background-color: #d9d9d9;
}
.pagination > div > span{
	font-size: 0.8em;
}
.pagination > .active{
	background-color: var(--color_accent);
	color: white;
	text-shadow: 0px 2px 3px rgba(0,0,0,0.3);
}
.pagination .noPointer, .pagination > .active{
	pointer-events: none;
}



.loader{
	position: relative;
	overflow: hidden;
}
.loader:before{
	content: '';
	position: absolute;
	left: 0;
	top: -50%;

	width: 100%;
	height: 300px;

	background: rgb(0,0,0);
	background: linear-gradient(0deg, rgba(0, 0, 0, 0) 0%, rgb(243 243 243) 50%, rgba(0, 0, 0, 0) 100%);

	animation: loading 1s infinite; /* Duración y repetición de la animación */
}
.loader.horizontal:before{
	top: 0;
	left: -50%;
	width: 300px;
	height: 100%;

	background: linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, rgb(243 243 243) 50%, rgba(0, 0, 0, 0) 100%);
	animation: loadingHorizontal 1s infinite; /* Duración y repetición de la animación */
}
.loader.d1:before{
	animation-delay: 0.02s;
}
.loader.d2:before{
	animation-delay: 0.06s;
}
.loader.d3:before{
	animation-delay: 0.1s;
}
.loader.d5:before{
	animation-delay: 0.12s;
}
@keyframes loading {
	0% {
		top: -50%;
	}
	100% {
		top: 100%;
	}
}

@keyframes loadingHorizontal {
	0% {
		left: -50%;
	}
	100% {
		left: 100%;
	}
}


@media (min-width: 1201px) {
	:root {--menubar_height: 0px;}
	.menubar{
		width: var(--menubar_width);
		max-width: var(--menubar_width);
		height: 100dvh;

		box-shadow: 0px 2px 10px rgba(0,0,0,0.05);
	}
	.menubar, .menu-group{
		flex-flow: column nowrap;
	}

	.menu-group a.active > span{
		width: calc(100% + 10px);
	}

	.menu-group a.active:before{
			right: -10px;
			width: 0.25rem;
			height: 2.5rem;
			border-radius: 0.375rem 0 0 0.375rem;
		top: 0;
		bottom: 0;
	}
}

@media (max-width: 1200px) {
	:root { --menubar_width: 0px;}
	.menubar{
		height: var(--menubar_height);
		width: 100%;

		border-top: solid 1px var(--border-color);
		bottom: 0;
	}
	.menubar, .menu-group{
		flex-flow: row nowrap;
		align-items: stretch;
	}

	.menu-group a > span{
		padding: 10px;
		height: 100%;
	}
	.menu-group a > span > span, .menu-subtitle{
		display: none;
	}

	.menu-group a.active:before{
			top: -10px;
			height: 0.25rem;
			width: 2.5rem;
			border-radius: 0 0 0.375rem 0.375rem;
		right: 0;
		left: 0;
	}
}

.swal2-popup, .swal2-styled{
	border-radius: 15px !important;
}


.fancybox__backdrop{
	--fancybox-bg: rgba(24, 24, 27, 0.68);
}
.popup{
	cursor: unset !important;
	border-radius: 15px !important;
	width: 700px;
	min-height: 200px;
	max-width: calc(100% - 20px);
}

td .bigbtn, td span{
	width: max-content;
}
td{
/*	min-width: 100px;*/
}

.vue-app{
	position: relative;
}

#curtain{
	position: fixed;
	left: var(--menubar_width);
	top: 0;
	width: calc( 100% - var(--menubar_width));
	height: calc( 100% - var(--menubar_height) );
	pointer-events: all;
	background-color: var(--background-color-variation);
	z-index: 999;
	border-bottom: solid 2px var(--border-color);
	overflow: hidden;



	display: flex;
	flex-flow: row nowrap;
	justify-content: center;

	transition: 0.2s ease;
}
#curtain img{
	width: 100px;
	object-fit: contain;
}

:not(.loading) > #curtain{
	pointer-events: none;
	border-bottom: solid 2px transparent;
	opacity: 0;
}

.infotable{
	border: solid 1px var(--border-color);
	width: 800px;
	max-width: 100%;
}
.infotable th, .infotable td{
	text-align: left;
	padding: 10px;
	vertical-align: baseline;
}
.infotable tbody td {
	padding: 5px 10px;
	border-bottom-width: 1px;
}
.infotable tbody tr:nth-child(odd) {
	background: #00000002;
}
.infotable tbody tr:nth-child(even) {
	background: #00000008;
}

.infotable tbody tr td:nth-child(even) {
	background: #00000005;
}