:root {
    --purple: #7E57C2;
    --cyan: #0dcaf0;
    --yellow: #ffc107;
    --green: #4CAF50;
    --gray: #BDBDBD;
    --st-draft: #6c757d;
    --st-waiting: #0d6efd;
    --st-confirmed: #0dcaf0;
    --st-executing: #ffc107;
    --st-executed: #198754;
    --st-partiallyexecuted: #dc3545;
    --ty-ordinary: #3577f1;
    --ty-extraordinary: #f7b84b;
    --ty-workshop: #6f42c1;
}

.st-draft {
    --st-color: var(--st-draft);
}

.st-waiting {
    --st-color: var(--st-waiting);
}

.st-confirmed {
    --st-color: var(--st-confirmed);
}

.st-executing {
    --st-color: var(--st-executing);
}

.st-executed {
    --st-color: var(--st-executed);
}

.st-partiallyexecuted {
    --st-color: var(--st-partiallyexecuted);
}

.ty-ordinary {
    --ty-color: var(--ty-ordinary);
}

.ty-extraordinary {
    --ty-color: var(--ty-extraordinary);
}

.ty-workshop {
    --ty-color: var(--ty-workshop);
}

.bg-status{
    background-color: var(--st-color);
}

.text-status {
    color: var(--st-color);
}

.text-type {
    color: var(--ty-color);
}

/* #region Logo */

#anchor-logo {
    color: rgb(171, 185, 232); /*Colore di default non selezionato*/
}

    #anchor-logo:has(:hover) {
        color: rgb(255, 255, 255);
    }

/* #endregion Logo */


/* #region Loader */
#loader-container {
    position: fixed; /* Posiziona il loader sopra tutto il contenuto */
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none; /* Usa flex per centrare il loader */
    justify-content: center;
    align-items: center;
    background-color: rgba(33, 37, 41, 0.35); /* Fondo semi-trasparente */
    z-index: 9999; /* Assicurati che il loader stia sopra gli altri contenuti */
}

#loader {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    display: inline-block;
    position: relative;
    border: 3px solid;
    border-color: #2D6BCF #2D6BCF transparent;
    box-sizing: border-box;
    animation: rotation 1s linear infinite;
}

    #loader::after {
        content: '';
        box-sizing: border-box;
        position: absolute;
        left: 0;
        right: 0;
        top: 0;
        bottom: 0;
        margin: auto;
        border: 3px solid;
        border-color: transparent #FF3D00 #FF3D00;
        width: 24px;
        height: 24px;
        border-radius: 50%;
        animation: rotationBack 0.5s linear infinite;
        transform-origin: center center;
    }

@keyframes rotation {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

@keyframes rotationBack {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(-360deg);
    }
}

    

/* #endregion Loader */

#logo-image {
    object-fit: cover;
    object-position: center;
    width: 80px;
    height: 80px;
}

.logoImageDiv {
    position: relative;
    width: 80px;
    height: 80px;
    overflow: hidden;
}

    .logoImageDiv:hover .changeImage {
        display: flex;
        cursor: pointer;
    }

.changeImage {
    display: none;
    position: absolute;
    top: 0px;
    bottom: 0px;
    left: 0px;
    right: 0px;
    background-color: rgba(0,0,0,0.5);
    color: #FFF;
    /*transition: all .5s linear;*/
}

html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 16px;
    }

    .responsive-span {
        display: none;
    }
}

@media screen and (max-height: 650px) {
    .customFBoxImg {
        max-height: 50vh !important;
    }
}

.customFBoxImg {
    max-height: 70vh;
    width: 100%;
}

html {
  position: relative;
  min-height: 100%;
}

body {
  margin-bottom: 60px;
}

.flex-fill-equals {
    flex: 1 1 0px !important;
}

/*Full calendar*/
.fc-button {
    background-color: #0275d8 !important;
    border-color: #0275d8 !important;
    color: white;
}

/*Activity View Page Status*/
.activityBgViewColor.activityStatus.Waiting {
    background-color: var(--purple);
}

.activityBgViewColor.activityStatus.Confirmed {
    background-color: var(--cyan);
}

.activityBgViewColor.activityStatus.Executing {
    background-color: var(--yellow);
}

.activityBgViewColor.activityStatus.Executed {
    background-color: var(--green);
}

.activityBgViewColor.activityStatus.Cancelled {
    background-color: var(--gray);
}


/*Activity Status*/
.activityStatus.Waiting {
    color: var(--purple);
}

.activityStatus.Confirmed {
    color: var(--cyan);
}

.activityStatus.Executing {
    color: var(--yellow);
}

.activityStatus.Executed {
    color: var(--green);
}

.activityStatus.Cancelled {
    color: var(--gray);
}

/*Activity Task Status*/

.ActivityTaskStatus.To_Execute {
    color: var(--cyan);
}

.activityTaskStatus.Doing {
    color: var(--yellow);
}

.activityTaskStatus.Done {
    color: var(--green);
}

.activityTaskStatus.Canceled {
    color: var(--gray);
}

.sidebar-dropdown:has(.sidebar-item.active) {
    display:block !important;
}


/*.modal.show:nth-of-type(odd) {
    z-index: 1062 !important;
}

.modal-backdrop:nth-of-type(even) {
    z-index: 1061 !important;
}*/





/*Utilizzata per troncare il testo quando serve*/
.lds-ellipsis {
    display: inline-block;
    position: relative;
    width: 80px;
    height: 30px;
}

.lds-ellipsis div {
    position: absolute;
    top: 10px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #888888;
   /* background: var(--primary);*/
    animation-timing-function: cubic-bezier(0, 1, 1, 0);
}

.lds-ellipsis div:nth-child(1) {
    left: 8px;
    animation: lds-ellipsis1 0.6s infinite;
}

.lds-ellipsis div:nth-child(2) {
    left: 8px;
    animation: lds-ellipsis2 0.6s infinite;
}

.lds-ellipsis div:nth-child(3) {
    left: 32px;
    animation: lds-ellipsis2 0.6s infinite;
}

.lds-ellipsis div:nth-child(4) {
    left: 56px;
    animation: lds-ellipsis3 0.6s infinite;
}

@keyframes lds-ellipsis1 {
    0% {
        transform: scale(0);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes lds-ellipsis3 {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(0);
    }
}

@keyframes lds-ellipsis2 {
    0% {
        transform: translate(0, 0);
    }

    100% {
        transform: translate(24px, �0);
    }
}

/*Gestione hover delle card delle persone di contatto e dei macchinari*/

@media screen and (max-height: 650px) {
    .peopleOpt {
        display: inline-block !important;
    }

    .elementOpt {
        display: inline-block !important;
    }
}

/*#region Tabelle*/
.d-flex_centered {
    display: flex;
    justify-content: center;
    align-items: center;
}
/*#endregion Tabelle*/

/*#region Forms*/

.form-label {
    margin-bottom: 4px !important;
    line-height: 1 !important;
    padding-left: 2px;
}

    .form-label.no-mb {
        margin-bottom: 0 !important;
    }

.validation-message {
    --bs-text-opacity: 1;
    --bs-danger-rgb: 217, 83, 79;
    color: rgba(var(--bs-danger-rgb), var(--bs-text-opacity)) !important;
}

/*#endregion Forms*/

/* #region Modals */

.modal-title{
    font-size: 16px !important;
}

/* #endregion Modals*/

/* #region Table */

.table {
    table-layout: fixed;
}

/* #endregion Table */


.user-link {
    flex: 1 1 0%; /* fondamentale: prende lo spazio disponibile e pu� restringersi */
    min-width: 0; /* fondamentale con flex */
    overflow: hidden; /* evita che il contenuto �sfondi� */
}

.sidebar-user-name {
    flex: 1 1 auto;
    min-width: 0; /* fondamentale */
    display: block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis; /* � */
}

.sidebar-user-panel {
    background: var(--vz-primary);
    position: sticky;
    bottom: 0;
    z-index: 1020;
    padding: 1rem;
    border-top: 1px solid var(--vz-secondary-border-subtle);
    width: 100%;
}

    .sidebar-user-panel a {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: center;
        -ms-flex-align: center;
        align-items: center;
        color: var(--vz-vertical-menu-item-color);
        font-size: .7375rem;
        font-family: hkgrotesk,sans-serif;
    }

    html[data-sidebar-size="sm"] .sidebar-user-panel .sidebar-user-name,
    html[data-sidebar-size="sm"] .sidebar-user-panel .sidebar-logout {
        display: none !important;
    }

html[data-sidebar-size="sm"] .sidebar-user-panel .sidebar-user-link {
    justify-content: center;
}

/* #region FilterMultiSelect */

.fms-wrap {
    display: inline-block;
}

.fms {
    position: relative;
    display: inline-block;
}

.fms-disabled {
    opacity: .65;
    pointer-events: none;
}

.fms-btn {
    min-width: 140px;
    display: inline-flex;
    align-items: center;
    gap: .5rem;
}

.fms-menu {
    position: absolute;
    top: calc(100% + .25rem);
    left: 0;
    min-width: 220px;
    z-index: 1050;
}

.fms-options {
    max-height: 260px;
    overflow: auto;
}

.fms-clear {
    cursor: pointer;
    opacity: .75;
}

.fms-clear:hover {
    opacity: 1;
}

/* Opzioni — completamente custom, senza dropdown-item */
.fms-option {
    display: flex;
    align-items: center;
    gap: .625rem;
    width: 100%;
    padding: .45rem .875rem;
    background: transparent;
    border: none;
    text-align: left;
    font-size: inherit;
    color: inherit;
    cursor: pointer;
    transition: background-color 120ms ease;
}

.fms-option:hover:not(:disabled),
.fms-option:focus:not(:disabled) {
    background-color: rgba(0, 0, 0, .055);
    outline: none;
}

.fms-option.fms-selected {
    background-color: rgba(13, 110, 253, .1);
}

.fms-option.fms-selected:hover:not(:disabled),
.fms-option.fms-selected:focus:not(:disabled) {
    background-color: rgba(13, 110, 253, .16);
    outline: none;
}

.fms-option:disabled {
    opacity: .4;
    cursor: not-allowed;
}

.fms-check {
    width: 1em;
    flex-shrink: 0;
    font-size: .9em;
}

.fms-label {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.fms-divider {
    margin: .25rem .5rem;
    border-color: rgba(0, 0, 0, .1);
    opacity: 1;
}

/* #endregion FilterMultiSelect */

/* #region Dashboard shortcut cards */

.card-shortcut {
    transition: box-shadow 0.15s ease, transform 0.15s ease;
}

.card-shortcut:hover {
    box-shadow: 0 .5rem 1rem rgba(0,0,0,.12) !important;
    transform: translateY(-2px);
}

/* #endregion Dashboard shortcut cards */

.btn-ai {
  --vz-btn-color: #fff;
  --vz-btn-border-color: transparent;
  --vz-btn-focus-shadow-rgb: 124, 58, 237;
  --vz-btn-disabled-color: #fff;
  --vz-btn-disabled-border-color: transparent;

  color: #fff;
  border-color: transparent;
  background-image: linear-gradient(135deg, #7c3aed 0%, #2563eb 55%, #06b6d4 100%);
  background-color: transparent;
  transition:
    color .15s ease-in-out,
    background-color .15s ease-in-out,
    border-color .15s ease-in-out,
    box-shadow .15s ease-in-out,
    filter .15s ease-in-out;
}

.btn-ai:hover,
.btn-ai:focus,
.btn-ai:focus-visible {
  color: #fff;
  border-color: transparent;
  filter: brightness(1.06);
}

.btn-ai:active {
  color: #fff !important;
  border-color: transparent !important;
  filter: brightness(.94);
}

.btn-ai:disabled,
.btn-ai.disabled {
  color: rgba(255, 255, 255, 0.9);
  border-color: transparent;
  opacity: .65;
  filter: none;
}

.btn-outline-ai {
  --vz-btn-color: #7c3aed;
  --vz-btn-bg: transparent;
  --vz-btn-border-color: transparent;
  --vz-btn-focus-shadow-rgb: 124, 58, 237;
  --vz-btn-disabled-color: #7c3aed;
  --vz-btn-disabled-bg: transparent;
  --vz-btn-disabled-border-color: transparent;

  color: #7c3aed;
  border: 1px solid transparent;
  background-image: linear-gradient(135deg, #7c3aed 0%, #2563eb 55%, #06b6d4 100%);
  background-origin: border-box;
  background-clip: border-box;
  box-shadow: inset 0 0 0 9999px var(--vz-body-bg, #fff);
  transition:
    color .15s ease-in-out,
    background-color .15s ease-in-out,
    border-color .15s ease-in-out,
    box-shadow .15s ease-in-out,
    filter .15s ease-in-out;
}

.btn-outline-ai:hover,
.btn-outline-ai:focus,
.btn-outline-ai:focus-visible {
  color: #fff;
  border-color: transparent;
  box-shadow: inset 0 0 0 0 rgba(255, 255, 255, 0);
  filter: brightness(1.03);
}

.btn-outline-ai:active {
  color: #fff !important;
  border-color: transparent !important;
  box-shadow: inset 0 0 0 0 rgba(255, 255, 255, 0) !important;
  filter: brightness(.94);
}

.btn-outline-ai:disabled,
.btn-outline-ai.disabled {
  color: #7c3aed;
  box-shadow: inset 0 0 0 9999px var(--vz-body-bg, #fff);
  opacity: .65;
  filter: none;
}

.btn-animation {
  transition:
    color .15s ease-in-out,
    background-color .15s ease-in-out,
    border-color .15s ease-in-out,
    box-shadow .15s ease-in-out,
    filter .15s ease-in-out,
    transform .15s ease-in-out;
}

.btn-animation:hover,
.btn-animation:focus,
.btn-animation:focus-visible {
  transform: translateY(-1px);
}

.btn-animation.btn-ai:hover,
.btn-animation.btn-ai:focus,
.btn-animation.btn-ai:focus-visible {
  box-shadow:
    0 10px 28px rgba(37, 99, 235, 0.22),
    0 0 16px rgba(124, 58, 237, 0.16);
}

.btn-animation.btn-outline-ai:hover,
.btn-animation.btn-outline-ai:focus,
.btn-animation.btn-outline-ai:focus-visible {
  box-shadow:
    inset 0 0 0 0 rgba(255, 255, 255, 0),
    0 10px 24px rgba(37, 99, 235, 0.18),
    0 0 14px rgba(124, 58, 237, 0.14);
}

.btn-animation:active {
  transform: translateY(0);
}