body {
    font-size: .875rem;
}

.feather {
    width: 16px;
    height: 16px;
    vertical-align: text-bottom;
}

/*
 * Sidebar
 */

.sidebar {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 100; /* Behind the navbar */
    padding: 48px 0 0; /* Height of navbar */
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
    color: white;
}

@media (max-width: 767.98px) {
    .sidebar {
        top: 5rem;
    }
}

.sidebar-sticky {
    position: relative;
    top: 0;
    height: calc(100vh - 48px);
    padding-top: 1rem;
    overflow-x: hidden;
    overflow-y: auto; /* Scrollable contents if viewport is shorter than content. */
}

@supports ((position: -webkit-sticky) or (position: sticky)) {
    .sidebar-sticky {
        position: -webkit-sticky;
        position: sticky;
    }
}

/* Assicura che la navbar sia coerente in tutte le pagine */
.navbar-nav {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.sidebar .nav-link {
    font-weight: 500;
    color: rgba(255, 255, 255, 0.8);
    border-radius: 10px;
    margin: 5px 15px;
    padding: 12px 15px;
    transition: all 0.3s ease;
    text-decoration: none;
}

.sidebar .nav-link i {
    margin-right: 8px;
    color: rgba(255, 255, 255, 0.7);
    width: 16px;
    text-align: center;
}

.sidebar .nav-link:hover {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    transform: translateX(5px);
    text-decoration: none;
}

.sidebar .nav-link.active {
    background: rgba(255, 255, 255, 0.25);
    color: white;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.sidebar .nav-link:hover i,
.sidebar .nav-link.active i {
    color: white;
}

.sidebar-heading {
    font-size: .75rem;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 600;
    letter-spacing: 1px;
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

/*
 * Navbar
 */

.navbar-brand {
    padding-top: .75rem;
    padding-bottom: .75rem;
    font-size: 1rem;
    background-color: rgba(0, 0, 0, .25);
    box-shadow: inset -1px 0 0 rgba(0, 0, 0, .25);
}

.navbar .navbar-toggler {
    top: .25rem;
    right: 1rem;
}

.navbar .form-control {
    padding: .75rem 1rem;
    border-width: 0;
    border-radius: 0;
}

.form-control-dark {
    color: #fff;
    background-color: rgba(255, 255, 255, .1);
    border-color: rgba(255, 255, 255, .1);
}

.form-control-dark:focus {
    border-color: transparent;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, .25);
}

/* Custom styles */
.card-header {
    background-color: #f8f9fa;
    font-weight: 500;
}

.btn-group-sm > .btn, .btn-sm {
    padding: .25rem .5rem;
    font-size: .75rem;
}

.table th {
    background-color: #f8f9fa;
}

.badge {
    font-size: 85%;
}

/*
 * Content
 */

.card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: #f8f9fa;
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
}

/* Form styles */
.form-control:focus {
    border-color: #80bdff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

/* Button styles */
.btn-primary {
    background-color: #007bff;
    border-color: #007bff;
}

.btn-primary:hover {
    background-color: #0069d9;
    border-color: #0062cc;
}

/* Table styles */
.table th {
    background-color: #f8f9fa;
}

/* Notification styles */
.notification-badge {
    position: absolute;
    top: -8px;
    right: -8px;
    padding: 3px 6px;
    border-radius: 50%;
    background-color: #dc3545;
    color: white;
    font-size: 0.7rem;
}
.notification-dropdown {
    width: 350px;
    max-height: 400px;
    overflow-y: auto;
}
.notification-item {
    border-bottom: 1px solid #eee;
    padding: 10px;
}
.notification-item:last-child {
    border-bottom: none;
}
.notification-item:hover {
    background-color: #f8f9fa;
}
.notification-time {
    font-size: 0.8rem;
    color: #6c757d;
}
.notification-empty {
    padding: 20px;
    text-align: center;
    color: #6c757d;
}



/*PRENOTAZIONI*/

/* Container per icone azioni: mantiene tutto su una riga */
.action-icons {
    display: inline-flex;
    align-items: center;
    flex-wrap: nowrap;
}
.action-icons > * {
    margin-right: 0.5rem;
}
.action-icons > *:last-child {
    margin-right: 0;
}
.action-icons .btn {
    white-space: nowrap;
}

.stato-in-attesa {
    background-color: #fff3cd;
    border-left: 4px solid #ffc107;
}
.stato-confermata {
    background-color: #d1ecf1;
    border-left: 4px solid #17a2b8;
}
.stato-pagata {
    background-color: #d4edda;
    border-left: 4px solid #28a745;
}
.stato-consegnata {
    background-color: #c3e6cb;
    border-left: 4px solid #20c997;
}
.stato-annullata {
    background-color: #f8d7da;
    border-left: 4px solid #dc3545;
}
.stato-badge {
    display: inline-block;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    margin-right: 5px;
}
.badge-in-attesa {
    background-color: #ffc107;
}
.badge-confermata {
    background-color: #17a2b8;
}
.badge-pagata {
    background-color: #28a745;
}
.badge-consegnata {
    background-color: #20c997;
}
.badge-annullata {
    background-color: #dc3545;
}
.sort-icon {
    font-size: 0.8em;
    margin-left: 5px;
}
.sortable {
    cursor: pointer;
}
.sortable:hover {
    background-color: #f8f9fa;
}


/*AIUTO*/
.help-section {
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
    font-size: 16px;
}
.help-section:last-child {
    border-bottom: none;
}
.help-section h3 {
    color: #007bff;
    margin-bottom: 15px;
}
.help-section p {
    line-height: 1.6;
}
.help-nav {
    position: sticky;
    top: 20px;
}
.help-nav .nav-link {
    padding: 0.5rem 1rem;
    color: #495057;
}
.help-nav .nav-link.active {
    color: #007bff;
    font-weight: bold;
    background-color: #f8f9fa;
}
.search-highlight {
    background-color: #ffff99;
    padding: 2px;
}
