@charset "utf-8";
/* ==========================================================================
   WOLFY 5.0 - GLOBAL STYLESHEET
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. LAYOUT GLOBALE & PAGINA
   -------------------------------------------------------------------------- */
body {
    background-color: #ffffff;
    padding: 0;
    overflow-x: hidden; /* Evita scroll orizzontale imprevisto */
    font-family: "Poppins", sans-serif; /* Assicurati che il font sia caricato altrove */
}

/* Wrapper per le pagine "modali" o pop-up (new_ e mod_) */
.page-wrapper-custom {
    padding: 20px;
}

/* Titoli Pagina Standardizzati */
.page-title {
    color: #333;
    font-weight: 600;
    border-bottom: 1px solid #eee;
    padding-bottom: 15px;
    margin-bottom: 20px;
}

/* --------------------------------------------------------------------------
   2. SIDEBAR
   -------------------------------------------------------------------------- */
.sidebar-nav ul li a {
    padding: 0px 35px 0px 15px;
}
.sidebar-nav > ul > li > a.active {
    background-color: #e4f1fe;
    font-weight: 500;
}

/* --------------------------------------------------------------------------
   3. FORM & INPUT (Standard Generico)
   -------------------------------------------------------------------------- */

/* Etichette: Maiuscolo, piccolo, grigio scuro */
.form-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 700;
    color: #6c757d;
    margin-bottom: 5px;
}

/* Input Base: Altezza forzata a 38px per coerenza */
.form-control, 
.form-select {
    min-height: 38px !important;
    border-radius: 4px !important;
    border: 1px solid #ced4da;
    font-size: 0.9rem;
}

/* Textarea: Reset altezza per permettere rows="..." */
textarea.form-control {
    min-height: auto !important;
    resize: vertical;
}

/* --- FIX CRUCIALE PER SELECT2 (Tema Bootstrap 5) --- */
/* Questo rende le Select2 identiche agli input standard */
.select2-container--bootstrap-5 .select2-selection {
    min-height: 38px !important;
    border: 1px solid #ced4da !important;
    border-radius: 4px !important;
    padding-top: 5px !important; /* Centratura verticale testo */
    padding-bottom: 5px !important;
}

/* Correzione posizione freccetta e testo */
.select2-container--bootstrap-5 .select2-selection--single .select2-selection__rendered {
    line-height: 1.5 !important;
    color: #495057;
    padding-left: 12px;
}

/* Focus color (Blue Bootstrap) */
.select2-container--bootstrap-5.select2-container--focus .select2-selection, 
.select2-container--bootstrap-5 .select2-selection:focus {
    border-color: #86b7fe !important;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25) !important;
}

/* --------------------------------------------------------------------------
   4. BOTTONI CUSTOM
   -------------------------------------------------------------------------- */
.btn-custom-save {
    background-color: #0d6efd;
    color: white;
    border: none;
    font-weight: 500;
}
.btn-custom-save:hover {
    background-color: #0b5ed7;
    color: white;
}

.btn-custom-cancel {
    background-color: #f8f9fa;
    color: #333;
    border: 1px solid #ddd;
}
.btn-custom-cancel:hover {
    background-color: #e2e6ea;
}

/* Pulsante modifica semplice (nella tabella) */
.btn-edit-simple {
    background: none !important;
    border: none !important;
    color: #007bff !important;
    font-size: 22px !important;
    padding: 0;
    cursor: pointer;
    line-height: 1;
    display: inline-block;
    transition: transform 0.2s;
}
.btn-edit-simple:hover {
    color: #0056b3 !important;
    transform: scale(1.1);
}

/* --------------------------------------------------------------------------
   5. TABELLE (Wolfy Compact UI)
   -------------------------------------------------------------------------- */
#myTable {
    width: 100% !important;
    margin-bottom: 0 !important;
}

/* Intestazione */
.table thead th {
    background-color: #f8f9fa;
    text-transform: uppercase;
    font-weight: 700;
    font-size: 11px !important;
    color: #495057;
    border-bottom: 2px solid #dee2e6 !important;
    vertical-align: middle;
}

/* Corpo Tabella */
.table.table-sm td, 
.table.table-sm th {
    padding: 0.5rem 0.6rem !important;
    font-size: 13px !important;
    vertical-align: middle !important;
}

/* Hover Effect */
.table-hover tbody tr:hover {
    background-color: rgba(0, 123, 255, 0.05) !important;
    transition: background 0.1s ease-in-out;
}

/* Colonne Speciali */
.col-data {
    white-space: nowrap !important;
    min-width: 70px;
}

/* Titolo Commessa / Badge Container */
.title-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

/* Badge e Label */
.badge, .label {
    font-size: 10px !important;
    padding: 2px 6px !important;
    font-weight: 600;
    text-transform: uppercase;
}

/* Icona manutenzione */
.toggle-manutenzione {
    font-size: 18px;
    cursor: pointer;
}

/* --------------------------------------------------------------------------
   6. AZIONI & UTILITY
   -------------------------------------------------------------------------- */
.action-bar {
    background: #fdfdfd;
    border: 1px solid #e9ecef;
    padding: 8px 12px;
    border-radius: 4px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.hider {
    display: none; /* Gestito via JS */
}

input[type="checkbox"].check {
    cursor: pointer;
    transform: scale(1.1);
}

/* --------------------------------------------------------------------------
   7. DATATABLES STYLING
   -------------------------------------------------------------------------- */
.dataTables_wrapper .row:first-child {
    margin-bottom: 10px;
    align-items: center;
}
.dataTables_wrapper .row:last-child {
    margin-top: 15px;
    align-items: center;
}
.dataTables_filter input,
.dataTables_length select {
    border: 1px solid #ced4da;
    border-radius: 4px;
    padding: 4px 8px;
    margin-left: 5px;
}
.dataTables_paginate .pagination {
    justify-content: flex-end;
    margin: 0;
}

/* Responsività Tabella */
.table-responsive {
    overflow-x: hidden;
}
@media (max-width: 992px) {
    .table-responsive {
        overflow-x: auto;
    }
}
/* STILE MEGA MENU WOLFY */
.wolfy-menu-title {
    font-size: 13px;
    font-weight: 700;
    color: #455a64;
    text-transform: uppercase;
    border-bottom: 1px solid #e9ecef;
    padding-bottom: 10px;
    margin-bottom: 15px;
    letter-spacing: 0.5px;
}

.wolfy-menu-list li {
    margin-bottom: 8px;
}

.wolfy-menu-list li a {
    display: block;
    color: #67757c;
    font-size: 14px;
    transition: all 0.2s ease-in-out;
    text-decoration: none;
}

.wolfy-menu-list li a i {
    width: 20px;
    display: inline-block;
    color: #adb5bd; /* Grigio chiaro per le icone a riposo */
    font-size: 16px;
    vertical-align: middle;
}

/* Effetto Hover: Spostamento a destra e cambio colore */
.wolfy-menu-list li a:hover {
    color: #1e88e5; /* Colore Primary del tuo tema */
    transform: translateX(5px);
}

.wolfy-menu-list li a:hover i {
    color: #1e88e5;
}