﻿/* Variables */
:root {
    --not-verified-color: #dc3545;
}

/* Syncfusion SfUploader: How to customize a custom drop area? */
/* https://www.syncfusion.com/forums/180524/how-to-customize-a-custom-drop-area */
body .e-upload-drag-hover {
    /*border-color: orangered;*/
    cursor: pointer;
    box-shadow: 0 0 15px 0 rgba(0, 0, 0, 0.3);
    background-color:aliceblue;
}

.editButton {
    margin-top:-8px;
}

.hscroll {
    overflow-x: auto;
    max-width: 100%;
    white-space: normal; /* allow wrapping */
    overflow-wrap: anywhere; /* break very long strings */
}

/* AI Generated */
.ai-gen {
    position: relative;
    padding: 1rem 1.2rem 1rem 3rem;
    margin: 0.75rem 0;
    border: 1px solid rgba(102, 102, 255, 0.40);
    border-radius: 10px;
    /* Animated gradient – higher contrast, same palette */
    background: linear-gradient( 135deg, rgba(102, 102, 255, 0.18), rgba(253, 102, 255, 0.12), rgba(102, 153, 255, 0.18) );
    background-size: 240% 240%;
    animation: aiGradientShift 8s ease-in-out infinite;
    font-size: 0.95rem;
    line-height: 1.5;
}

/* Keyframes */
@keyframes aiGradientShift {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}

    /* Bootstrap Icon */
    .ai-gen::before {
        content: "\F675"; /* bi-magic */
        font-family: "bootstrap-icons";
        position: absolute;
        top: 1.05rem;
        left: 1rem;
        font-size: 1.25rem;
        line-height: 1;
    }

    /* Optional AI label badge */
    .ai-gen::after {
        content: "AI";
        position: absolute;
        top: -0.45rem;
        right: 0.75rem;
        font-size: 0.65rem;
        letter-spacing: 0.05em;
        padding: 0.15rem 0.45rem;
        background-color: #ffffff;
        color: #5a5aff;
        border: 1px solid rgba(102, 102, 255, 0.35);
        border-radius: 6px;
    }

    /* Title styling */
    .ai-gen h3 {
        margin: 0 0 0.4rem 0;
        font-size: 1rem;
        font-weight: 600;
    }

.e-quick-popup-wrapper .e-event-delete, .e-quick-popup-wrapper .e-event-popup .e-delete-icon,
.custom-event-editor .e-event-delete, .e-quick-popup-wrapper .e-event-popup .e-delete-icon,
.e-event-delete {
    display: none !important;
}

.input-validation-error,
textarea.invalid {
    border: 1px solid #dc3545 !important;
    background-image: none !important;
}
textarea.invalid {
    border-color: #dc3545; /* Bootstrap danger red */
}

textarea.valid {
    border-color: #198754; /* Bootstrap success green */
}

/* Don't make fonts bigger on mobile */
.e-grid.e-bigger .e-rowcell,
.e-bigger .e-btn {
    line-height: 22px !important;
    font-size: 14px !important;
}

.e-link {
    padding: 0 !important;
    border: 0 !important;
}
.priority .status {
    align-content:start !important;
}
/*.sfDropDown {
    height: 56px;
    padding-top: 1.625rem;
    padding-bottom: .625rem;
    transform: scale(1) translateY(-.5rem) translateX(.15rem);
    font-size: 17px !important;
}
.sfDropDownLabel {
    color: rgba(var(--bs-body-color-rgb), .65);
    transform: scale(.85) translateY(-1rem) translateX(.15rem);
}*/
.sfSingleLineInputHeight {
    min-height: 38px;
    padding-top: 2px;
}
.sfMultiSelect,
.sfDropDownList {
    min-height: 56px;
    /*padding: 1.625rem -0.2rem 200rem 0.2rem !important;*/
    padding: 1.5rem 0 0 0.2rem;
}

.sfMultiSelectLabel,
.sfDropDownListLabel {
    color: rgba(var(--bs-body-color-rgb), .65);
    transform: scale(.85) translateY(-.5rem) translateX(.15rem);
}

.btnFileLink {
    font-size: 1rem !important;
    padding: 0 !important;
    margin: -4px 0 0 3px !important;
}

/* ----- */
.priority, .status {
    border-radius: 8px;
    padding: 0px 11px 2px;
    text-align: center;
    width: fit-content;
    margin: auto;
    font-size: 12px;
}

@media only screen and (max-width: 768px) {
    .priority, .status {
        background.color:red;
        text-align: left!important;
    }
}

.priority-ticket-details, 
.status-ticket-details {
    border-radius: 10px;
    padding: 8px 16px !important;
    /*margin-left:4px;*/
    font-size: var(--bs-body-font-size);
}
/* ----- */
.priorityBassa {
    /*background-color: #0d6efd; */ /* Blue */
    border: 1px solid #0d6efd;
    color: black;
}
.priorityNormale {
    /* background-color: #198754;*/ /* Green */
    border: 1px solid #198754;
    color: #198754;
}
.priorityAlta {
    background-color: #fd7e14; /* Orange */
    color: white;
}
.priorityUrgente {
    background-color: #dc3545; /* Red */
    color: white;
}
/* ----- */
.statusNuova { 
    background-color: #0d6efd; /* Blue */
    color: white;
}
.statusAssegnata {
    background-color: #ffca00; /* Yellow (was purple) */
    color: black;
}
/* Diagonal 2-color stripes */
.statusAssegnataNotConfirmed {
    background: repeating-linear-gradient( 45deg, #ffca00 0, #ffca00 12px, #ccc 12px, #ccc 24px );
    color: black;
}

.statusValutata {
    background-color: #fd7e14; /* Orange */
    color: white;
}
.statusPreventivo {
    background-color: #dc3545; /* Red */
    color: white;
}
.statusDaProgrammare {
    background-color: #35ac51; /* Verde */
    color: white;
}
.statusProgrammataInCorso {
    background-color: #6f42c1; /* Viola Purple */
    color: white;
}
/* Diagonal 2-color stripes */
.statusProgrammataInCorsoNotConfirmed {
    background: repeating-linear-gradient( 45deg, #6f42c1 0, #6f42c1 12px, #999 12px, #999 24px );
    color: white;
}

.statusInterventoConcluso,
.statusInterventoConclusoConFiniture {
    background-color: #b73eb3; /* Gray */
    color: white;
}
.statusStandby {
    border: 1px solid #6c757d; /* Gray */
    background-color: #6c757d; /* Gray */
    color: white;
}
.statusChiuso {
    border: 1px solid #6c757d; /* Gray */
    /*background-color: #198754;*/ /* Green */
    color: black;
}
.statusRiaperto {
    background-color: #0d6efd; /* Blue */
    color: white;
}

select option:disabled {
    background-color: #f5f5f5;
    color: #6c757d;
}
/* ----- */
.truncate {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.sidebar .layer {
    background-color: rgba(248, 247, 216, 0.2);
}

.quickgrid .wrap80 .col-title-text {
    width: 80px;
    /*This two core settings*/
    overflow-wrap: break-word !important;
    white-space: normal !important;
    text-align: center;
}

td:has(.td-bg-warning),
div.form-floating:has(.div-bg-warning) {
    background-color: #ffc107;
}

td:has(.td-bg-danger),
div.form-floating:has(.div-bg-danger) {
    background-color: #dc3545;
}

.bg-danger, .bg-warning {
    margin: -4px !important;
    padding: 4px !important;
}

input.disabled {
    pointer-events: none;
    color: #212529;
    background: #e9ecef;
}

.form-floating label.ro {
    opacity: .65;
    transform: scale(.85) translateY(-.5rem) translateX(.15rem);
}

.form-floating span.ro {
    margin-left: 13px;
}

.grid td {
    align-content: center !important;
}


.grid tr td:has(.expired),
tr td:has(.expired) {
    background: var(--not-verified-color) !important;
    color: white !important;
}

.grid tr:has(.notverified),
tr:has(.notverified) {
    background: var(--not-verified-color) !important;
    color: #fff !important;
}

.grid tr:has(.rowNo),
tr:has(.rowNo) {
    color: var(--not-verified-color) !important;
}

.e-table tr:has(.inactive) td {
    background: #dedede !important;
    color: #aaa !important;
}

.e-table tr:has(.toprocess) td {
    border: var(--bs-warning-border-subtle) !important;
    background: var(--bs-warning-bg-subtle) !important;
    color: #343a40 !important;
}



.e-table tr:has(span.expired) td {
    background: #dc3545 !important;
    color: #eee !important;
}

span.expired {
    color: #dc3545;
}
.e-grid .e-altrow {
    background-color: #f2f2f2;
} 

.grid tr:has(.hidden), tr:has(.hidden),
.grid tr:has(span.hidden), tr:has(span.hidden),
.grid td:has(.hidden), td:has(.hidden) {
    /*background: #ddd !important;
    color: #999 !important;*/

    --bs-table-bg: #ddd !important;
    --bs-table-color: #999 !important;
    --bs-table-striped-bg: #bbb !important;
    --bs-table-striped-color: #777 !important;
}
.grid td.hidden-row {
    background: #ddd !important;
    color: #999 !important;
}

.grid th.hideColumn,
.grid td.hideColumn {
    visibility: hidden !important;
    display: none;
}

.sub-menu-container {
    margin: 0 0 0 55px !important;
}

.sub-menu-item {
    margin: 0;
    padding: 0;
    color: #d7d7d7 !important;
    font-size: 0.9rem;
}

    .sub-menu-item:hover {
        color: #fff !important;
    }

/*.grid tr:not(:has(.notempty)) {
    display: none;
}*/

.multiple-selector {
    display: flex;
}

.selectable-ul {
    height: 200px;
    overflow-y: auto;
    list-style-type: none;
    width: 170px;
    padding: 0;
    border-radius: 3px;
    border: 1px solid #ccc;
}

    .selectable-ul li {
        cursor: pointer;
        border-bottom: 1px #eee solid;
        padding: 2px 10px;
        font-size: 14px;
    }

        .selectable-ul li:hover {
            background-color: #08c;
        }

.multiple-selector-buttons {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 5px;
}

    .multiple-selector-buttons button {
        margin: 5px;
    }



/* Hide empty rows added to Quickgrid in .NET 9 using Pagination */
.quickgrid tr:has(> td:not(:empty)) > td {
    display: table-cell !important;
}

.quickgrid td:empty {
    display: none !important;
}

/* Multilines in blazor quickgrid headers */
.col-title-text {
    white-space: pre-wrap;
}




/* ----- */

/* Variables */
:root {
    --not-verified-color: #dc3545;
}

.quickgrid .wrap80 .col-title-text {
    width: 80px;
    /*This two core settings*/
    overflow-wrap: break-word !important;
    white-space: normal !important;
    text-align: center;
}

td:has(.td-bg-warning),
div.form-floating:has(.div-bg-warning) {
    background-color: #ffc107;
}

td:has(.td-bg-danger),
div.form-floating:has(.div-bg-danger) {
    background-color: #dc3545;
}

.bg-danger, .bg-warning {
    margin: -4px !important;
    padding: 4px !important;
}

input.disabled {
    pointer-events: none;
    color: #212529;
    background: #e9ecef;
}

.form-floating label.ro {
    opacity: .65;
    transform: scale(.85) translateY(-.5rem) translateX(.15rem);
}

.form-floating span.ro {
    margin-left: 13px;
}

.grid td {
    align-content: center !important;
}


.grid tr:has(.expired),
tr:has(.expired) {
    color: var(--not-verified-color) !important;
}

.grid tr:has(.notverified),
tr:has(.notverified) {
    background: var(--not-verified-color) !important;
    color: #fff !important;
}

.grid tr:has(.rowNo),
tr:has(.rowNo) {
    color: var(--not-verified-color) !important;
}

.grid tr:has(.hidden), tr:has(.hidden) {
    background: #ddd !important;
    color: #999 !important;
}

.grid th.hideColumn,
.grid td.hideColumn {
    visibility: hidden !important;
    display: none;
}

.sub-menu-container {
    margin: 0 0 0 55px !important;
}

.sub-menu-item {
    margin: 0;
    padding: 0;
    color: #d7d7d7 !important;
    font-size: 0.9rem;
}

    .sub-menu-item:hover {
        color: #fff !important;
    }

/*.grid tr:not(:has(.notempty)) {
    display: none;
}*/

.multiple-selector {
    display: flex;
}

.selectable-ul {
    height: 200px;
    overflow-y: auto;
    list-style-type: none;
    width: 170px;
    padding: 0;
    border-radius: 3px;
    border: 1px solid #ccc;
}

    .selectable-ul li {
        cursor: pointer;
        border-bottom: 1px #eee solid;
        padding: 2px 10px;
        font-size: 14px;
    }

        .selectable-ul li:hover {
            background-color: #08c;
        }

.multiple-selector-buttons {
    display: flex;
    flex-direction: column;
    justify-content: center;
    padding: 5px;
}

    .multiple-selector-buttons button {
        margin: 5px;
    }



/* Hide empty rows added to Quickgrid in .NET 9 using Pagination */
.quickgrid tr:has(> td:not(:empty)) > td {
    display: table-cell !important;
}

.quickgrid td:empty {
    display: none !important;
}

/* Multilines in blazor quickgrid headers */
.col-title-text {
    white-space: pre-wrap;
}