textarea{
    height: 3 em;
}
.socialIcons {
    margin-left: 10px;
    color: black;
}

.carousel-inner .carousel-item.active,
.carousel-inner .carousel-item-next,
.carousel-inner .carousel-item-prev {
    display: flex;
}

.carousel-inner .carousel-item-right.active,
.carousel-inner .carousel-item-next {
    transform: translateX(33.333%);
}

.carousel-inner .carousel-item-left.active,
.carousel-inner .carousel-item-prev {
    transform: translateX(-33.333%);
}

.carousel-inner .carousel-item-right,
.carousel-inner .carousel-item-left {
    transform: translateX(0);
}

#shopPicHere {
    height: 90px;
    width: 90px;
}

#addPicsHere .carousel-item {
    height: 150px;
}

.carouselImage {
    max-height: 100%;
    max-width: 100%;
    width: auto;
    height: auto;
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    right: 0;
    margin: auto;
}

.modal-header {
    height: 0px;
    border: none;
}

aside.main-sidebar.sidebar-dark-primary.elevation-4::-webkit-scrollbar {
    display: none;
}

aside.main-sidebar.sidebar-dark-primary.elevation-4 {
    -ms-overflow-style: none;
    /* IE and Edge */
    scrollbar-width: none;
    /* Firefox */
}

.stickyWithSidebar {
    position: sticky;
    max-width: 100vw;
    left: 0px;
}

.sidebar-open:not(.layout-top-nav) .stickyWithSidebar {
    left: 250px;
    max-width: calc(100vw - 250px);
}

@media (min-width: 991.98px) {
    .sidebar-collapse .stickyWithSidebar {
        left: 4.6rem;
        max-width: calc(100vw - 4.6rem);
    }
}
.dark-mode .socialIcons {
    color: #3f6791;
}
.content-wrapper{
    height:fit-content;
    padding-bottom: .5rem;
}
.productHeartBtn{
    color: red;
}
.btn-outline-light {
    color: #f8f9fa;
    border-color: #f8f9fa;
}
#durationContainerDiv table, #durationContainerDiv th, #durationContainerDiv td {
    border: 1px solid black;
    border-collapse: collapse;
}
#addProductsHere .card{
    width: 100%;
}
span.carousel-control-next-icon, .carousel-control-prev-icon {
    background-color: gray;
    border-radius: 100px;
}
.editor-toolbar.fullscreen {
    z-index: 1035 !important;
}
.fidelityTitleBtn{
    width: 100%;
}
.photoPreview {
    max-width: 100px;
    max-height: 100px;
}
.card-header[data-toggle="collapse"] {
    cursor: pointer;
}

.collapsed .chevron-icon {
    transform: rotate(0deg);
}
.chevron-icon {
    transition: transform 0.3s ease;

    transform: rotate(180deg);
}
@media (min-width: 600px) {
    .serviceBlock,
    .genericServiceCard {
        transition: width 0.3s ease, max-width 0.3s ease;
        width: 100%;
    }
    .serviceBlock:has(.serviceHeader.collapsed),
    .genericServiceCard:has(.genericServiceHeader.collapsed) {
        transition: width 0.3s ease, max-width 0.3s ease;
        width: fit-content;
    }
    /* Settings sections with width animation */
    .settingsSection {
        width: 100%;
        transition: width .3s ease;
    }
    .settingsSection.collapsed-setting {
        width: auto;
    }
}

/* Opzioni collegate o dipendenti (es. un interruttore e i campi che abilita): riquadro sottile riutilizzabile */
.settings-option-group {
    border: 1px solid rgba(108, 117, 125, .35);
    border-radius: .5rem;
    padding: .75rem .75rem .25rem;
    margin-bottom: 1rem;
}
.row > .settings-option-group {
    flex: 0 0 calc(100% - 15px);
    max-width: calc(100% - 15px);
    margin-left: 7.5px;
    margin-right: 7.5px;
}
.dark-mode .settings-option-group {
    border-color: rgba(206, 212, 218, .3);
}

/* Ricerca impostazioni: opzioni non corrispondenti nascoste nelle sezioni trovate */
.settings-search-hidden {
    display: none !important;
}

/* Auto-save animations */
@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.auto-save-indicator {
    font-size: 0.85em;
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Time input styling - compact and responsive */
.time-input {
    width: auto;
    max-width: fit-content;
    display: inline-block;
}

/* Ensure time fields look good when side-by-side on larger screens */
@media (min-width: 768px) {
    [data-field] .time-input {
        min-width: 140px;
    }
}

/* Number input styling - compact width based on content */
.number-input {
    width: auto;
    max-width: 150px;
    display: inline-block;
}

@media (min-width: 768px) {
    [data-field] .number-input {
        min-width: 120px;
    }
}

/* Field help toggle styling */
.field-help-toggle {
    text-decoration: none;
    font-size: 0.9em;
    transition: color 0.2s ease;
}

.field-help-toggle:hover {
    color: #007bff !important;
    text-decoration: none;
}

.field-help-content {
    margin-top: 0.25rem;
    padding: 0.5rem;
    background-color: #f8f9fa;
    border-left: 3px solid #17a2b8;
    border-radius: 0.25rem;
    animation: slideDown 0.3s ease;
}

.dark-mode .field-help-content {
    background-color: #2c3034;
    border-left-color: #17a2b8;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.select2-selection{
    height: calc(2.25rem + 2px) !important;
}

/* Le select2 a scelta multipla (es. razze dei tag) crescono con le scelte e mostrano chip leggibili. */
.select2-selection.select2-selection--multiple{
    height: auto !important;
    min-height: calc(2.25rem + 2px);
}
.select2-container--default .select2-selection--multiple .select2-selection__choice{
    color: #212529;
    background-color: #e9ecef;
}
body.dark-mode .select2-container--default .select2-selection--multiple .select2-selection__choice{
    color: #f8f9fa;
    background-color: #454d55;
    border-color: #6c757d;
}

/* Tabella degli stati (clienti fuori frequenza): in tema scuro Bootstrap usa
   testo scuro sulle superfici del tema e l'intestazione ha uno sfondo bianco
   inline. Regola mirata, il tema chiaro resta invariato. */
.dark-mode #frequencyOutliersCard .table {
    color: #dee2e6;
}
.dark-mode #frequencyOutliersCard .sticky-header thead {
    background-color: #3f474e;
}

/* Reset native dialog geometry; Bootstrap supplies the modal viewport. */
dialog.modal {
    background: transparent;
    margin: 0;
    padding: 0;
    border: 0;
    max-width: none;
    max-height: none;
    color: inherit;
}

.form-section-title {
    font-size: 1rem;
    font-weight: 700;
    line-height: inherit;
    margin-bottom: .5rem;
}

.native-status {
    display: block;
    margin-bottom: 1rem;
}

.configuration-progress {
    appearance: none;
    border: 0;
    background: transparent;
    width: 100%;
    height: 100%;
}
.configuration-progress::-webkit-progress-bar {
    background: transparent;
}
.configuration-progress::-webkit-progress-value {
    background-color: #28a745;
}
.configuration-progress::-moz-progress-bar {
    background-color: #28a745;
}
.configuration-progress-label {
    color: #212529;
    position: absolute;
    inset: 0;
    text-align: center;
}

/* Opzione aperta da "Cerca una funzione": bordo ben visibile in tema chiaro e scuro, oltre al focus del campo. */
.settings-search-target {
    outline: 3px solid #007bff;
    outline-offset: 4px;
    border-radius: .25rem;
}

/* FR-CARRELLO-DETTAGLIO: product showcase, a row of cards that scrolls sideways. */
.home-products .card-header { border-bottom: 0; }
.home-products-row { display: flex; gap: 1rem; overflow-x: auto; scroll-snap-type: x mandatory; padding: 0.25rem 0.25rem 0.75rem; -webkit-overflow-scrolling: touch; }
.home-product { flex: 0 0 260px; max-width: 260px; margin: 0; scroll-snap-align: start; box-shadow: 0 1px 3px rgba(0,0,0,.12), 0 1px 2px rgba(0,0,0,.18); }
.home-product-picture { display: flex; align-items: center; justify-content: center; width: 100%; height: 180px; padding: 0; border: 0; border-radius: .25rem .25rem 0 0; background: #f4f6f9; overflow: hidden; cursor: zoom-in; }
.home-product-picture img { max-width: 100%; max-height: 100%; object-fit: contain; }
.home-product-placeholder { cursor: default; color: #adb5bd; font-size: 3rem; }
.home-product-name { font-size: 1.1rem; font-weight: 600; margin-bottom: .5rem; overflow-wrap: anywhere; }
.home-product-description { font-size: .95rem; color: #495057; max-height: 4.5em; overflow: hidden; overflow-wrap: anywhere; }
.home-product-description p { margin-bottom: .25rem; }
.home-product.expanded .home-product-description { max-height: none; }
.home-product-more { align-self: flex-start; }
@media (max-width: 575.98px) {
    .home-product { flex-basis: 82%; max-width: 82%; }
    .home-products-nav { display: none; }
}

/* Orari fissi scritti dal negozio: una riga per giorno, come li ha scritti. */
.homeCoverHoursText {
    white-space: pre-line;
    text-align: right;
}

/* SimpleMDE uses its own light surfaces independently of AdminLTE. */
.dark-mode .CodeMirror,
.dark-mode .editor-preview,
.dark-mode .editor-preview-side {
    background: #292e33;
    color: #dee2e6;
    border-color: #59636d;
}
.dark-mode .CodeMirror-cursor { border-color: #f8f9fa; }
.dark-mode .CodeMirror-selected,
.dark-mode .CodeMirror-focused .CodeMirror-selected { background: #394e64; }
.dark-mode .editor-toolbar { border-color: #59636d; }
.dark-mode .editor-toolbar a { color: #dee2e6 !important; }
.dark-mode .editor-toolbar a:hover,
.dark-mode .editor-toolbar a.active {
    background: #3f4851;
    border-color: #7b8792;
}
.dark-mode .editor-preview pre,
.dark-mode .editor-preview-side pre {
    background: #343a40;
    color: inherit;
}
