/*
 * Copyright (c) 2019.
 * SIC - Servizi Integrati & Consulenze S.r.l.
 * Via Rovetta 18, 20127, Milano
 * posta@sic-online.it
 */

body {
    padding-top: 70px;
    padding-bottom: 60px;
    font-size: 0.8rem;
}

nav {
    font-size: 1rem;
}
.btn .badge  {
    border-radius: 50%;
}
.rating-stars {
    font-size: 2rem;
    cursor: pointer;
}
.rating-stars i {
    color: #ddd;
    transition: all 0.3s ease;
    display: inline-block;
}
.rating-stars i:hover {
    transform: scale(1.3);
}
.rating-stars i.hover-active {
    color: #ffc107;
}
.rating-stars i.active {
    color: #ffc107;
}
/*tabella a righe alternate*/
.tabella-viaggi > table > tbody > tr > td,
.tabella-viaggi > table > tbody > tr > th {
    border: none;
}
.tabella-viaggi tbody tr:hover {
    background-color: rgba(0, 0, 0, 0);
}
.tabella-viaggi tbody tr.secondary-row:hover {
    background-color: rgba(0, 0, 0, 0.035);
}
.secondary-row {
    background-color: rgba(0, 0, 0, 0.035);
}
.primary-row {
    background-color: #fff
}

.padding0 {
    padding: 0 !important;
}

.table-wrapper{
    align-items: flex-start;
    display: flex;
    gap: 0;
}

.table-pd0 th,
.table-pd0 td {
    padding: 0.1rem 0.2rem;
}

.ui-front {
    z-index: 1000000 !important;
}

.phpError {

}

.box-gruppo {
    background-color: #f7f7f7;
    border-radius: 1%;
    border: 1px solid darkgrey;
    padding:5px 10px;
    margin-bottom:10px;
}

.viaggi-destinazioni{
    font-family: "Inter Tight", sans-serif;
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
    display: inline;
    margin-right: 6px;
}

.separatore{
    border-left: 1px solid darkgrey;
    margin:10px;
    display: inline;
    border-radius: 5%
}
.breadcrumb {
    background: inherit !important;
}

.tr-selezionata {
    background: rgba(24, 126, 62, 0.2) !important;
}

.maxwidth-150px {
    max-width: 150px;
}

/* VIAGGI */
.viaggiStato {
    border: solid 1px #ccc;
    border-radius: 5px;
    padding: 0 5px 2px;
    display: inline;
    font-weight: bold;
    white-space: nowrap;
}

/* VIAGGI */
.statoDainviareindeposito {
    background: #ffeea8;
}

/* VIAGGI */
.statoNonAttuabile {
    background: #ffe165;
}

/* VIAGGI */
.statoNonAttuabileindeposito {
    background: #ffe165;
}

/* VIAGGI */
.statoNoninviabileindeposito {
    background: #ffe165;
}

.statoInviatoindeposito\,nonattuabile {
    background: #ffe165;
}

.statoBloccato\,nonattuabile {
    background: #ffe165;
}

/* VIAGGI */
.statoCaricoeffettuato {
    background: #c0efb1;
}

.statoValidazioneincorso\,selostatopersistecontattareilDEPOSITANTE {
    background: #ffe165;
}

/* VIAGGI */
.statoCaricoeffettuatoindeposito {
    background: #c0efb1;
}

/* VIAGGI */
.statoInviatoindeposito {
    background: #d1d6ff;
}

/* VIAGGI */
.statoCancellato {
    background: hotpink; /*#ff4d4d;*/
}

/* VIAGGI */
.statoErroreDati, .statoErroredatiindeposito {
    background: #f38080;
}

.statoFineCaricoindeposito {
    background: #4BC9D7;
}

.statoFallitoprecheck {
    background: #f38080;
}

.viaggiStato.OK {
    background: #c0efb1;
}

.viaggiStato.ERROR {
    background: #f38080;
}

.viaggiStato.ATTESA {
    background: #ffeea8;
}

/* ui-select fix */
.open > .dropdown-menu {
    display: block;
}

.navbar-brand {
    position: absolute;
    margin-top: 0px;
    margin-bottom: 0px;
    padding: 0;
}

#navbarSupportedContent {
   /* margin-left: 80px;*/
    overflow-x: auto;
}

.navbar {
    padding-top: 0;
    padding-bottom: 0;
    padding-left: 0;
    /*height: 50px;*/

}

#navbarSupportedContent {
    overflow-y: auto;
}

.nav-link {
    overflow: hidden;
    text-align: center;
    display: table-cell;
    vertical-align: middle;
    white-space: initial;
}

/* Da tablet/desktop in su */
@media (min-width: 768px) {
    .nav-link {
        padding-top: 0;
        padding-bottom: 0;
        border-left: 1px solid lightgrey;
        width: 6.5em;
        height: 3em;
        overflow: hidden;
        text-align: center;
        display: table-cell;
        vertical-align: middle;
        white-space: initial;
    }
}

.lastNavItem {
    border-right: 1px solid lightgrey;
}

.nav-item.active {
    background: #E0E0E0;
    font-weight: bold;
    font-size: 1.1rem;
}
@media (max-width: 768px) {
    .nav-item {
        padding-left: 10px;
    }
}

.navbar-nav .nav-link:hover {
    color: rgba(0, 0, 0, 0.9) !important;
}

.nav-username {
    border: none;
    white-space: nowrap;
    width: max-content;
}

.infoOrdine {
    clear: both;
    display: block;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    padding: 5px 20px;
    background: #eee;
    min-height: 60px;
}

[ng\:cloak], [ng-cloak], [data-ng-cloak], [x-ng-cloak], .ng-cloak, .x-ng-cloak {
    display: none !important;
}

.stati ul {
    margin-left: 0;
    padding: 0;
}

.stati li {
    list-style-type: none;
    height: 40px;
    border: solid 1px red;
}

.alberoRuoli {

}

#contenitoreAlberoRuoli {

}

.alberoRuoli ul {

}

.alberoRuoli li {
    list-style-type: none;
    margin-top: 10px;
}

.rowtotalicomp {
    border-bottom: double blue !important;
    background-color: #DD7799 !important;
}

.rowtotali {
    background-color: #C0C0EF !important;
}

/* Colorazione delle stato del buono */
span.statoBuono_corretto {
    font-weight: bold;
    font-size: 1.1em;
    color: green;
}

/* Colorazione delle stato del buono */
span.statoBuono_attesa {
    font-weight: bold;
    font-size: 1.1em;
    color: orange;
}

/* Colorazione delle stato del buono */
span.statoBuono_errato {
    font-weight: bold;
    font-size: 1.1em;
    color: red;
}

#collapseLeftmenu .list-group-item, #collapseLeftmenu .card-header {
    padding-top: 4px;
    padding-bottom: 4px;
    padding-left: 15px;
}

.btn-collapse {
    cursor: pointer;
}

#titolo {
    padding-left: 0;
}

.list-group-item.active, .btn-primary {
    background-color: rgb(28, 126, 66);
    border-color: rgb(28, 126, 66);
}

.btn-primary:hover, .btn-primary:not(:disabled):not(.disabled):active, .btn-primary:not(:disabled):not(.disabled).active {
    color: #fff;
    background-color: rgb(28, 126, 66);
    border-color: rgb(28, 126, 66);
}

small.sic-filtra {
    font-size: inherit;
    text-transform: uppercase;
}

#filtri .input-group-text {
    font-size: 0.8rem;
}

.filtriBorder {

}

.sic-ordina {
    cursor: pointer;
}
.sic-intestazione{
    /*min-width: 120px;*/
    overflow: hidden;
    display: block;
}

.sic-th-attivo {
    color: rgb(28, 126, 66);
}

.btn-attivo, .btn-attivo a:hover {
    color: #ffffff !important;
    background-color: rgb(28, 126, 66);
    border-color: rgb(28, 126, 66);
}
.btn-info-attivo, .btn-info-attivo a:hover {
    color: #ffffff !important;
    background-color: #17a2b8;
    border-color: #17a2b8;
}

.calendar-disabled {
    background-color: #e9ecef;
}


#subnav {
    position: fixed;
    top: 49px;
    left: 0;
    z-index: 999;
    width: 100%;
    background: white;
    margin: 0 !important;
    padding: 2rem 1rem 0.5rem;
}

#mainContainer {
}

#mainContainer.withSubNav {
    padding-top: 50px;
}

#sicFooter {
    font-size: 1em;
}


#collapseLeftmenu .list-group-item {
    border: none;
}

.minw-75 {
    min-width: 90% !important;
}

.input-group {
    flex-wrap: nowrap;
}

.ui-select-match {
}

.ui-select-match > .ui-select-toggle {
    overflow: hidden;
}

.form-control-plaintext {
    font-family: monospace;
    font-size: large;
}

.buono-alert {
    background: darkred !important;
    color: whitesmoke !important;
}

.tooltip-inner {
    text-align: left !important;
}

.btn-link-muted, .btn-link-muted:hover {
    color: inherit !important;
    text-decoration: none !important;
}

.consegna-warning {
    background: lightyellow;
}

.coloreRosso {
    color: red;
}

.bdc-viaggi input, .ui-select-match .ui-select-toggle, .bdc-viaggi select {
    height: 50px !important;
}

.ui-select-placeholder {
    display: inline-block;
    margin-top: 5px;
}

.control-label {
    margin-bottom: 0.1rem;
}

.twitter-typeahead {
    display: block !important;
}

.tt-menu {
    background: white;
    border: solid 1px lightgray;
}

.tt-selectable {
    padding: 10px;
}

.tt-selectable:hover {
    background: lightgray;
}

.tt-menu {
    max-height: 150px;
    overflow-y: auto;
    width: 100%;
    min-width: 200px;
}

.sic-group-right {
    border-top-right-radius: 0;
    border-bottom-right-radius: 0;
}

.sic-group-left {
    border-top-left-radius: 0;
    border-bottom-left-radius: 0;
}

.twitter-typeahead {
    width: 100%;
}

.sic-typeahead-clear {
    cursor: pointer;
}

.tt-highlight {
    color: rgb(28, 126, 66);
}


debugcode {
    white-space: pre;
    font-family: monospace;
    overflow: scroll;
}

#formfeedback {
    display: none;
}

.debug {
    border: solid 1px red !important;
}

.table {
    margin-bottom: 0;
}

.table .thead-light th {
    color: #495057;
    background-color: rgba(0, 0, 0, 0.03);
    border-color: #dee2e6;
    text-transform: uppercase;
    white-space: nowrap;
}

.report-table [id^="table-"] th,
.report-table [id^="table-"] td {
    border-left: 1px solid #ccc;
    border-right: 1px solid #ccc;
}

.report-table .table .thead-light th {
    white-space: normal;
    text-align: center;
    align-content: center;
}


.nav-username {
    padding-right: 0px !important;
}

.col-formlogin {
    width: 450px;
}

dd {
    display: inline-flex;
}

.dropdown-item {
    cursor: pointer;
}

input[type="date"] {
    height: auto;
}

.hoverDanger:hover {
    background: red;
    color: black;
}

.i18n-small-flag {
    width: 60px;
    height: 40px;
}

#loader {
    position: fixed;
    top: 0;
    left: 0;
    z-index: 1050;
    overflow: hidden;
    outline: 0;
    margin-left: 50%;
    margin-top: 20%;
}

.cursor-pointer {
    cursor: pointer;
}

.dropdown-submenu:hover + .manuali-menu, .manuali-menu:hover {
    display: block;
}

.manuali-menu {
    margin-right: -5px !important;
}

.ui-select-container[disabled], .ui-select-match[disabled], .ui-select-toggle[disabled] {
    background-color: #e9ecef;
    opacity: 1;
}

.close {
    font-size: 1.2rem !important;
}

pre {
    max-width: 100% !important;
}

.legendv2 {
    display: block;
    width: auto;
    padding: 0 5px;
    margin-bottom: 0;
    font-size: 20px;
    line-height: inherit;
    border-bottom: none;
}

.fieldsetConBordo {
    border: 2px groove threedface;
    padding: 5px;
}

.filterFull {
    border: 2px solid rgb(28, 126, 66);
}

.form-control:disabled {
    background-color: #e9ecef !important;
}

.tt-disabled {
    /*cursor: not-allowed !important;*/
    pointer-events: none;
    color: #777;
    text-decoration: line-through;
}

.thin-lines tbody td{
    border: none;
    border-bottom: 1px solid #eeeeee;
    padding: 0.1rem;
}

.thin-lines  thead th {
    border: none ;
    padding: 0.1rem;
}

.truncate {
    display: inline-block;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.feedback-wrapper {
    display: flex;
    align-items: center;
    max-width: min-content;
    white-space: nowrap;
}

@media (min-width: 1646px) {
    .feedback-wrapper {
        flex-direction: row;
        gap: 8px;
    }

    .btn-feedback {
        order: 1;
    }

    .custom-switch {
        order: 2;
    }
}

@media (max-width: 1645px) {
    .feedback-wrapper {
        flex-direction: column;
        align-items: flex-end;
    }

    .custom-switch {
        order: 1;
    }

    .btn-feedback {
        order: 2;
        align-self: center;
        display: block;
        position: relative;
        top: 5px;
    }
}

.colw-100 {
    width: 100px;
}

.hover-zoom {
    display: inline-block;
    transition: transform 0.2s ease-in-out;
}

.hover-zoom:hover {
    transform: scale(1.3);
}

/* serve per i componenti di Tomselect */
.col-multiple {
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
}

.ts-wrapper.multi .ts-control>div {
    background: #efefef;
    border: 0 solid #dee2e6;
    color: #343a40;
    cursor: pointer;

    margin: 0 3px 3px 0;
    overflow: auto;
    padding: 1px 5px;
}
.ts-wrapper.multi .ts-control>div {
    border-radius: calc(var(--bs-border-radius) - 1px);
}
.ts-wrapper.multi.has-items .ts-control {
    padding-left: calc(.75rem - 5px);
    --ts-pr-min: calc(0.75rem - 5px);
}
.ts-control,
.ts-dropdown {
    border: 1px solid #ccc !important;
    background: white !important;
}

.ts-wrapper.form-control {
    padding: 0;
    height: auto;
}

.ts-control {
    min-height: calc(1.5em + .5rem + 2px);
    padding: .25rem .5rem;
}

.ts-control input {
    min-height: 1.5em;
}

.ts-wrapper:not(.tomselect-typeahead) .ts-control {
    cursor: pointer !important;
}

.ts-wrapper:not(.tomselect-typeahead) .ts-control input {
    cursor: pointer !important;
}
/*--------------------------------------------------------------*/
.grey-text th, .grey-text b{
    color:#6c757d;
}

.border-primary {
    border-color: rgb(28, 126, 66) !important;
}


/* =========================================================
   NUOVA UI VIAGGI
   =========================================================
CONTENITORE GENERALE */
.viaggi-list {
    width: 100%;
    margin-top: 8px;
}

/* =========================================================
   AZIONI GLOBALI VIAGGI
   ========================================================= */

.viaggi-list .viaggi-global-actions {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    margin-bottom: 8px;
}

/* base */
.viaggi-list .viaggi-global-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 30px;
    padding: 4px 10px;
    border-radius: 6px;
    font-size: 0.76rem;
    font-weight: 500;
    box-shadow: none;
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease, opacity 0.15s ease;
}


/* APRI TUTTI */
.viaggi-list .viaggi-open-all {
    color: rgb(28, 126, 66);
    border: 1px solid rgba(28, 126, 66, 0.45);
    background-color: #ffffff;
}


.viaggi-list .viaggi-open-all:hover {
    color: rgb(28, 126, 66);
    border-color: rgb(28, 126, 66);
    background-color: rgba(28, 126, 66, 0.07);
}


/* CHIUDI TUTTI */

.viaggi-list .viaggi-close-all {
    color: #5f666d;
    border: 1px solid #d8dde2;
    background-color: #ffffff;
}


.viaggi-list .viaggi-close-all:hover {
    color: #343a40;
    border-color: #adb5bd;
    background-color: #f5f6f7;
}

/* DISABILITATI */
.viaggi-list .viaggi-global-btn:disabled {
    opacity: 0.42;
    cursor: default;
    pointer-events: none;
}

/* ICONE */
.viaggi-list .viaggi-global-btn i {
    font-size: 0.72rem;
}

/*CARD SINGOLO VIAGGIO */
.viaggi-list .viaggio-card {
    width: 100%;
    margin-bottom: 5px !important;
    border: 1px solid #dce2e6;
    border-radius: 7px;
    background-color: #ffffff;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.04);
    overflow: hidden;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.viaggi-list .viaggio-card:hover {
    border-color: #d4d9de;
    box-shadow: 0 2px 7px rgba(0, 0, 0, 0.06);
}

.viaggi-list .viaggio-card:has(.viaggio-collapse-btn[aria-expanded="true"]) {
    border-color: rgb(28, 126, 66);
}

/* HEADER / RIEPILOGO VIAGGIO */
.viaggi-list .viaggio-header {
    background-color: #F5F7F7;
}

/*
 * Il renderer genera:
 *
 * .viaggio-header
 *     > .d-flex
 *         > viaggio-action
 *         > viaggio-info
 *         > viaggio-info
 *         ...
 */

.viaggi-list .viaggio-header > .d-flex {
    width: 100%;
    flex-wrap: nowrap !important;
    align-items: stretch !important;
}

.viaggi-list .viaggio-info {
    position: relative;
    min-width: 0;
    flex: 1 1 0;
    padding: 5px 14px !important;
    border-left: none;
    color: #343a40;
    overflow: hidden;
}

/* Separatore verticale */
.viaggi-list .viaggio-info::before {
    content: "";
    position: absolute;
    top: 10px;
    bottom: 10px;
    left: 0;
    width: 1px;
    background-color: #e0e5e8;
    pointer-events: none;
}

.viaggi-list .viaggio-data {
    flex: 0 0 150px;
}

.viaggi-list .viaggio-id {
    flex: 0 0 135px;
}

.viaggi-list .viaggio-stato-wrapper {
    flex: 0 0 165px;
}
.viaggi-list .viaggio-documento {
    flex: 0 0 170px;
}

.viaggi-list .viaggio-deposito {
    flex: 1.1 1 180px;
}

.viaggi-list .viaggio-depositante {
    flex: 1 1 165px;
}

.viaggi-list .viaggio-cessionario {
    flex: 1 1 165px;
}

.viaggi-list .viaggio-logistica {
    flex: 1.25 1 200px;
}

.viaggi-list .viaggio-emittente {
    flex: 0 0 120px;
}

/* LABEL CAMPI*/
.viaggi-list .viaggio-info-label {
    margin-bottom: 4px !important;
    color: #707780;
    font-size: 0.72rem;
    font-weight: 600 !important;
    text-transform: uppercase;
    letter-spacing: 0.025rem;
    white-space: nowrap;
}


/*  VALORE CAMPI */
.viaggi-list .viaggio-info-value {
    min-width: 0;
    color: #30353a;
    font-size: 0.82rem;
    line-height: 1.4;
    overflow: hidden;
    word-break: break-word;
}


.viaggi-list .viaggio-info-value > div {
    margin-bottom: 1px;
}

/* Data e ID guidano la lettura le altre informazioni restano secondarie. */
.viaggi-list .viaggio-data .viaggio-info-value {
    color: #212529;
    font-weight: 600;
}

@media (min-width: 768px) {
    .viaggi-list .viaggio-id .viaggio-info-value {
        font-size: 0.95rem;
    }
}
/* Link ID viaggio */
.viaggi-list .viaggio-id a {
    color: #212529 !important;
    text-decoration: none;
}

.viaggi-list .viaggio-id a:hover {
    color: rgb(28, 126, 66) !important;
    text-decoration: underline;
}

/*ICONE INFO */
.viaggi-list .viaggio-info-value + i,
.viaggi-list .viaggio-info i {
    color: #6c757d;
}

/* STATO VIAGGIO */
.viaggi-list .viaggio-stato-badge {
    display: inline-flex;
    align-items: center;
    max-width: 100%;
    padding: 5px 8px;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    color: #253028;
    font-size: 0.8rem;
    font-weight: 600;
    line-height: 1.2;
    white-space: normal;
    text-align: left;
}

.viaggi-list .viaggio-stato-badge i {
    flex-shrink: 0;
    font-size: 0.75rem;
}
/*DOCUMENTO STATO */
.viaggi-list .documento-stato {
    display: flex;
    align-items: flex-start;
    gap: 5px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.35;
}

.viaggi-list .documento-stato.ERROR {
    color: #b42318;
}

.viaggi-list .documento-stato.OK {
    color: rgb(28, 126, 66);
}

.viaggi-list .documento-stato.ATTESA {
    color: #dede00;
    -webkit-text-stroke: 0.3px rgba(190, 115, 0, 0.55);
}

/* Supera la regola del tema che rende grigie le icone. */
.viaggi-list .viaggio-info .documento-stato > i {
    color: inherit;
    flex-shrink: 0;
}

.viaggi-list .documento-stato > span {
    min-width: 0;
    overflow-wrap: anywhere;
}

/* BOTTONE COLLAPSE VIAGGIO*/
.viaggi-list .viaggio-actions {
    flex: 0 0 46px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 6px 6px;
}


/* bottone base */
.viaggi-list .viaggio-action-btn {
    width: 30px;
    height: 30px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    border-radius: 6px;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.15s ease, border-color 0.15s ease, background-color 0.15s ease;
}


/* azioni*/
.viaggi-list .viaggio-detail-btn {
    border: 1px solid gray;
    color: #000000;
}

.viaggi-list .viaggio-detail-btn:hover {
    color: #ffffff;
    background-color: rgb(24, 108, 57);
    border-color: rgb(24, 108, 57);
    text-decoration: none;
}

.viaggi-list .viaggio-detail-btn:focus {
    color: #ffffff;
    outline: none;
    box-shadow: 0 0 0 2px rgba(28, 126, 66, 0.18);
}

.viaggi-list .viaggio-collapse-btn {
    border: 1px solid #dfe3e8;
    color: #6c757d;
    background-color: #ffffff;
    box-shadow: none;
}

.viaggi-list .viaggio-collapse-btn:hover {
    color: rgb(28, 126, 66);
    border-color: rgba(28, 126, 66, 0.4);
    background-color: rgba(28, 126, 66, 0.06);
}

.viaggi-list .viaggio-collapse-btn:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(28, 126, 66, 0.13);
}

/* rotazione freccia */
.viaggi-list .viaggio-collapse-btn i {
    display: inline-block;
    transform: rotate(0deg);
    transition: transform 0.18s ease;
}

.viaggi-list .viaggio-collapse-btn[aria-expanded="true"] i {
    transform: rotate(180deg);
}

.viaggi-list .viaggio-collapse-btn:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(28, 126, 66, 0.13) !important;
}

/*CONSEGNE */
.viaggi-list .viaggio-consegne {
    border-top: 1px solid #dce2e6;
    background-color: #ffffff;
}

/*TITOLO CONSEGNE*/
.viaggi-list .viaggio-consegne-title {
    min-height: 38px;
    display: flex;
    align-items: center;
    border-bottom: 1px solid #e5e7eb;
    background-color: #f8f9fa;
    color: #343a40;
    font-size: 0.82rem;
    letter-spacing: 0.01rem;
}

.viaggi-list .viaggio-consegne-title .text-muted {
    margin-left: 4px;
    font-weight: 400;
}


/* TABELLA CONSEGNE */
.viaggi-list .viaggio-consegne .table-responsive {
    margin: 0;
    border: none;
}

.viaggi-list .viaggio-consegne-table {
    width: 100%;
    margin: 0;
    background-color: #ffffff;
    font-size: 0.76rem;
}

.viaggi-list .viaggio-consegne-table thead.thead-light th {
    padding: 7px 8px;
    border-top: none;
    border-bottom: 1px solid #dee2e6;
    background-color: #F5F7F7;
    color: #687079;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.02rem;
    vertical-align: middle;
    white-space: nowrap;
}

.viaggi-list .viaggio-consegne-table tbody td {
    padding: 5px;
    border-top: 1px solid #eeeeee;
    color: #343a40;
    line-height: 1.35;
    vertical-align: top;
}


/*Prima riga senza bordo doppio */
.viaggi-list .viaggio-consegne-table tbody tr:first-child td {
    border-top: none;
}

.viaggi-list .viaggio-consegne-table tbody tr {
    transition: background-color 0.12s ease;
}

.viaggi-list .viaggio-consegne-table tbody tr:hover {
    background-color: rgba(28, 126, 66, 0.035);
}


/*  PRODOTTI*/
.viaggi-list .viaggio-prodotti-cell {
    min-width: 210px;
    max-width: 340px;
}

.viaggi-list .viaggio-prodotto {
    position: relative;
    margin-bottom: 3px;
    padding-left: 10px;
    line-height: 1.35;
}

.viaggi-list .viaggio-prodotto:last-child {
    margin-bottom: 0;
}

.viaggi-list .viaggio-prodotto::before {
    content: "";
    position: absolute;
    top: 6px;
    left: 0;
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background-color: rgb(28, 126, 66);
}


/*  NESSUNA CONSEGNA */

.viaggi-list .viaggio-consegne > .text-muted {
    font-size: 0.8rem;
    background-color: #ffffff;
}

@media (min-width: 1400px) {
    .viaggi-list .viaggio-header > .d-flex {
        flex-wrap: nowrap !important;
    }
}

@media (min-width: 992px) and (max-width: 1399.98px) {
    /*
     * Su schermi meno larghi permettiamo alla seconda metà
     * del riepilogo di andare su una nuova riga.
     */
    .viaggi-list .viaggio-header > .d-flex {
        flex-wrap: wrap !important;
    }

    .viaggi-list .viaggio-action {
        flex: 0 0 45px;
    }

    .viaggi-list .viaggio-data {
        flex: 0 0 155px;
    }
    .viaggi-list .viaggio-id {
        flex: 0 0 140px;
    }

    .viaggi-list .viaggio-stato-wrapper {
        flex: 1 1 170px;
    }

    .viaggi-list .viaggio-documento {
        flex: 1 1 180px;
    }

    .viaggi-list .viaggio-deposito,
    .viaggi-list .viaggio-depositante,
    .viaggi-list .viaggio-cessionario,
    .viaggi-list .viaggio-logistica {
        flex: 1 1 24%;
        border-top: 1px solid #eeeeee;
    }

    .viaggi-list .viaggio-emittente {
        flex: 1 1 140px;
        border-top: 1px solid #eeeeee;
    }

}

@media (min-width: 768px) and (max-width: 991.98px) {
    .viaggi-list .viaggio-card {
        margin-bottom: 5px !important;
    }

    .viaggi-list .viaggio-header > .d-flex {
        display: flex;
        flex-wrap: wrap !important;
    }

    /*
     * freccia a tutta altezza sulla sinistra
     */
    .viaggi-list .viaggio-action {
        flex: 0 0 44px;
    }

    /*
     * Data + ID
     */
    .viaggi-list .viaggio-data {
        flex: 1 1 calc(50% - 44px);
    }

    .viaggi-list .viaggio-id {
        flex: 1 1 40%;
    }

    /*
     * Le altre informazioni vanno a due colonne.
     */
    .viaggi-list .viaggio-stato-wrapper,
    .viaggi-list .viaggio-documento,
    .viaggi-list .viaggio-deposito,
    .viaggi-list .viaggio-depositante,
    .viaggi-list .viaggio-cessionario,
    .viaggi-list .viaggio-logistica,
    .viaggi-list .viaggio-emittente {
        flex: 1 1 50%;
        border-top: 1px solid #eeeeee;
    }

    .viaggi-list .viaggio-info {
        min-height: 72px;
    }


    /*
     * La tabella può scorrere orizzontalmente.
     */
    .viaggi-list .viaggio-consegne-table {
        min-width: 1100px;
    }

}

/* =========================================================
   NUOVA UI VIAGGI - MOBILE
   ========================================================= */

@media (max-width: 767.98px) {

    /*
     * Evita che un figlio largo costringa tutta la pagina
     * ad allargarsi oltre il viewport.
     */
    #dati {
        width: 100%;
        min-width: 0;

        padding-left: 8px;
        padding-right: 8px;

        overflow-x: hidden !important;
    }


    .viaggi-list {
        width: 100%;
        min-width: 0;
        max-width: 100%;

        margin-top: 6px;
    }


    /* =====================================================
       AZIONI APRI / CHIUDI TUTTI
       ===================================================== */

    .viaggi-list .viaggi-global-actions {
        width: 100%;
        display: flex;
        flex-wrap: wrap;
        justify-content: flex-end;
        gap: 5px;
        margin-bottom: 6px;
    }


    .viaggi-list .viaggi-global-btn {
        min-height: 32px;
        padding: 5px 9px;
        font-size: 0.72rem;
    }


    /* =====================================================
       CARD
       ===================================================== */

    .viaggi-list .viaggio-card {
        width: 100%;
        min-width: 0;
        max-width: 100%;
        margin-bottom: 5px !important;
        border-radius: 6px;
        overflow: hidden;
    }


    /*
     * Su mobile smettiamo di usare il layout flex desktop.
     *
     * Grid ci permette di controllare esattamente la posizione
     * dei campi senza combattere con flex-basis da desktop.
     */
    .viaggi-list .viaggio-header > .d-flex {
        display: grid !important;
        width: 100%;
        grid-template-columns:46px minmax(0, 1fr) minmax(0, 1fr);
        flex-wrap: unset !important;
        align-items: stretch !important;
    }


    /* =====================================================
       RIGA 1
       [azioni] [ ID VIAGGIO ]
       ===================================================== */

    .viaggi-list .viaggio-actions {
        grid-column: 1;
        grid-row: 1;
        width: 46px;
        min-width: 46px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 5px;
        padding: 7px 6px;
    }


    .viaggi-list .viaggio-id {
        grid-column: 2 / 4;
        grid-row: 1;
        width: auto;
        min-width: 0;
        flex: none;
        border-left: none;
        border-bottom: 1px solid #eeeeee;
    }


    /*
     * ID più evidente, essendo l'informazione principale
     * per riconoscere il viaggio.
     */
    .viaggi-list .viaggio-id .viaggio-info-value {
        font-size: 0.9rem;
    }

    /* =====================================================
       RIGA 2
       [ DATA                     ][ STATO ]
       ===================================================== */

    .viaggi-list .viaggio-data {
        grid-column: 1 / 3;
        grid-row: 2;
        width: auto;
        min-width: 0;
        flex: none;
        border-left: none;
    }


    .viaggi-list .viaggio-stato-wrapper {
        grid-column: 3;
        grid-row: 2;
        width: auto;
        min-width: 0;
        flex: none;
        border-left: none;
    }

    /* Su mobile solo lo stato ha un campo affiancato da separare. */
    .viaggi-list .viaggio-info:not(.viaggio-stato-wrapper)::before {
        content: none;
    }

    /* =====================================================
       RESTO DELLE INFORMAZIONI
       Una riga per informazione
       ===================================================== */

    .viaggi-list .viaggio-documento {
        grid-column: 1 / 4;
        grid-row: 3;
    }


    .viaggi-list .viaggio-deposito {
        grid-column: 1 / 4;
        grid-row: 4;
    }


    .viaggi-list .viaggio-depositante {
        grid-column: 1 / 4;
        grid-row: 5;
    }


    .viaggi-list .viaggio-cessionario {
        grid-column: 1 / 4;
        grid-row: 6;
    }


    .viaggi-list .viaggio-logistica {
        grid-column: 1 / 4;
        grid-row: 7;
    }


    .viaggi-list .viaggio-emittente {
        grid-column: 1 / 4;
        grid-row: 8;
    }


    .viaggi-list .viaggio-documento,
    .viaggi-list .viaggio-deposito,
    .viaggi-list .viaggio-depositante,
    .viaggi-list .viaggio-cessionario,
    .viaggi-list .viaggio-logistica,
    .viaggi-list .viaggio-emittente {
        width: auto;
        min-width: 0;

        flex: none;

        border-left: none;
        border-top: 1px solid #eeeeee;
    }


    /* =====================================================
       INFO
       ===================================================== */

    .viaggi-list .viaggio-info {
        min-width: 0;
        padding: 8px 12px !important;
        overflow: visible;
    }


    .viaggi-list .viaggio-info-label {
        margin-bottom: 3px !important;
        font-size: 0.65rem;
        white-space: normal;
    }


    .viaggi-list .viaggio-info-value {
        width: 100%;
        min-width: 0;
        font-size: 0.78rem;
        line-height: 1.35;
        overflow: visible;
        word-break: normal;
        overflow-wrap: anywhere;
    }


    /* =====================================================
       STATO
       ===================================================== */

    .viaggi-list .viaggio-stato-badge {
        max-width: 100%;
        padding: 4px 6px;
        font-size: 0.68rem;
        white-space: normal;
    }


    /* =====================================================
       BOTTONI AZIONI
       ===================================================== */

    .viaggi-list .viaggio-action-btn {
        width: 29px;
        height: 29px;
        flex-shrink: 0;
    }


    /* =====================================================
       CONSEGNE
       ===================================================== */

    .viaggi-list .viaggio-consegne {
        width: 100%;
        min-width: 0;
    }


    .viaggi-list .viaggio-consegne-title {
        min-height: 36px;
        padding: 8px 12px !important;
        font-size: 0.78rem;
    }


    /*
     * La tabella NON deve cercare di comprimere
     * 9 colonne dentro 350px.
     *
     * Rimane larga e si scorre orizzontalmente.
     */
    .viaggi-list .viaggio-consegne .table-responsive {
        display: block;
        width: 100%;
        overflow-x: auto !important;
        overflow-y: hidden;
        -webkit-overflow-scrolling: touch;
    }


    .viaggi-list .viaggio-consegne-table {
        width: 100%;
        min-width: 1000px;
        font-size: 0.72rem;
    }


    .viaggi-list .viaggio-consegne-table thead th {
        padding: 6px 7px;
        font-size: 0.64rem;
    }


    .viaggi-list .viaggio-consegne-table tbody td {
        padding: 7px;
    }


    .viaggi-list .viaggio-prodotti-cell {
        min-width: 220px;
        max-width: 280px;
    }

    /* =========================================================
   CRUSCOTTO MOBILE
   ========================================================= */

    #accordion {
        width: 100%;
        min-width: 0;
    }


    /*
     * È la prima d-flex dentro card-body:
     *
     * Cruscotto | Viaggi | Consegne | Prodotti
     */
    #accordion > .card > .card-body > .d-flex:first-child {
        display: grid !important;
        grid-template-columns:
        repeat(3, minmax(0, 1fr));
        gap: 6px;
        width: 100%;
        padding: 10px !important;
    }


    /*
     * Titolo Cruscotto
     *
     * Sovrascrive anche style="width: 8%"
     */
    #accordion > .card > .card-body > .d-flex:first-child > div:first-child {
        grid-column: 1 / 4;
        width: 100% !important;
        margin-bottom: 2px;
    }


    #accordion > .card > .card-body > .d-flex:first-child > div:first-child h4 {
        font-size: 1rem;
        white-space: nowrap;
    }


    /*
     * Viaggi / Consegne / Prodotti
     */
    #accordion > .card > .card-body > .d-flex:first-child > .col {
        width: auto;
        max-width: none;
        flex: none;
        padding: 0;
    }


    #accordion > .card > .card-body > .d-flex:first-child > .col > .col {
        width: 100%;
        padding: 0;
        justify-content: center !important;
    }


    #accordion > .card > .card-body > .d-flex:first-child h5 {
        font-size: 0.76rem;
        white-space: nowrap;
    }

}