/*  стили */
			
			.logo {
				display: flex;
				align-items: center;
				justify-content: center;
				text-align: center;
				width: 100%;
			}
			.logo img {
				margin-right: 10px;
				width: 50px;
				height: auto;
			}
			.header-spacing {
				margin-bottom: 10px;
			}
			.section-spacing {
				margin-top: 120px;
			}
			.sub-title {
				font-size: 18px;
				margin-top: -10px;
			}
			body {
				font-family: Arial, sans-serif;
				background-color: #f4f4f4;
				color: #0c5460;
				margin: 0;
				padding: 0;
			}
			.container {
				width: 95%;
				margin: auto;
				overflow: hidden;
			}
			main {
				padding: 20px;
				background: #ced4da;
				margin-top: 20px;
				box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
				border-radius: 5px;
			}
			.filter {
				margin-bottom: 20px;
			}
			.table {
				border-collapse: collapse;
			}
			.table td, .table th {
				border: 1px solid #ddd;
				padding: 8px;
			}
			.filter-container {
				display: flex;
				flex-wrap: wrap;
				gap: 10px;
				align-items: flex-end;
				margin-bottom: 20px;
			}
			.filter-group {
				display: flex;
                flex-direction: column;
                justify-content: flex-end;
			}
			.filter-group label {
				margin-bottom: 5px;
			}
			
			.filter-buttons {
				display: flex;
				justify-content: center;
				gap: 10px;
				margin-top: 10px;
			}
			.chart-container {
				margin-top: 30px;
				text-align: center;
			}
			.export-buttons {
				margin-top: 20px;
				text-align: center;
			}
			.modal {
				display: none;
				position: fixed;
				z-index: 1000;
				left: 0;
				top: 0;
				width: 100%;
				height: 100%;
				background-color: rgba(0,0,0,0.4);
			}
			.modal-content {
				background-color: #fefefe;
				margin: 5% auto;
				padding: 20px;
				border: 1px solid #888;
				width: 80%;
				max-width: 500px;
				max-height: 80vh;
				overflow-y: auto;
			}
			.close {
				color: #aaa;
				float: right;
				font-size: 28px;
				font-weight: bold;
				cursor: pointer;
			}
			.close:hover {
				color: black;
			}
			#fileInput {
				display: none;
			}
			
			.table {
				border-collapse: collapse;
				width: 100%;
				margin-top: 20px;
			}
			.table td, .table th {
				border: 1px solid #c4dddd;
				padding: 8px;
				
			}
			.table th {
				background-color: #0c5460;
				color: white;
			}
			
			/* Новые стили для интерактивных строк */
			.table tbody tr {
				cursor: pointer;
				transition: all 0.2s;
			}
			.table tbody tr:hover {
				transform: scale(1.01);
				box-shadow: 0 0 10px rgba(0,0,0,0.1);
			}
			
			.btn-edit, .btn-delete {
    margin: 0 2px;
    padding: 3px 3px;
    cursor: pointer;
}
.btn-edit { background-color: #d8ff15; }
.btn-delete { background-color: #dc64d2; color: white; }

.unavailable:hover::after {
    content: "Временно недоступно";
    position: absolute;
    background: #ffebee;
    padding: 5px;
    border: 1px solid #c62828;
    border-radius: 4px;
    margin-left: 10px;
    z-index: 100;
}
.status-badge {
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
}

.status-badge.available {
    background-color: #d4edda;
    color: #6ad032;
}

.status-badge.unavailable {
    background-color: #f8d7da;
    color: #d31bd3;
}
.btn-toggle-availability {
    background: none;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 4px 8px;
    cursor: pointer;
    margin-left: 5px;
}
.btn-toggle-availability:hover {
    background-color: #f0f0f0;
}

.error-input {
    border: 2px solid #e86cb7 !important;
    animation: shake 0.5s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-5px); }
    40%, 80% { transform: translateX(5px); }
}



@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; }
}

/* Стили для диалога подтверждения */
.confirm-dialog {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.confirm-dialog .dialog-content {
    background: white;
    padding: 25px;
    border-radius: 10px;
    max-width: 400px;
    width: 100%;
    box-shadow: 0 5px 20px rgba(0,0,0,0.2);
}

.confirm-dialog h3 {
    margin-top: 0;
    color: #333;
}

.confirm-dialog p {
    margin: 15px 0;
    color: #555;
}

.dialog-buttons {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
}

.btn-cancel, .btn-confirm {
    padding: 8px 16px;
    border-radius: 4px;
    cursor: pointer;
    border: none;
    font-weight: 500;
}

.btn-cancel {
    background: #f0f0f0;
    color: #333;
}

.btn-confirm {
    background: #e84293;
    color: white;
}
/* Стиль для недоступных блюд в выпадающем списке */
select option[data-unavailable="true"] {
    color: #999;
    font-style: italic;
}

/* Стили для уведомлений */
.notification {
    position: fixed;
    top: 70px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 5px;
    color: white;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    z-index: 1000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 400px;
    transition: all 0.3s ease;
}

.notification.success {
    background-color: #4CAF50;
}

.notification.error {
    background-color: #F44336;
}

.notification.info {
    background-color: #2196F3;
}

.close-notification {
    margin-left: 15px;
    cursor: pointer;
    font-weight: bold;
    font-size: 18px;
}

.fade-out {
    opacity: 0;
    transform: translateY(-20px);
}

/* Стили секции фильтров (как на странице заказов) */
.filter-section {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.filter-group {
    flex: 0 1 auto;
    min-width: 100px;
}

.filter-group label {
    display: block;
    font-size: 0.85rem;
    margin-bottom: 4px;
    font-weight: 500;
    color: #495057;
}

.filter-group .form-control {
    height: 38px;
    padding: 6px 12px;
    font-size: 0.95rem;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
}

/* Группа поиска (растягивается) */
.filter-group.search-group {
    min-width: 50px;
    flex: 1 1 auto;
}

/* Кнопка очистки */
.clear-btn {
    white-space: nowrap;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.clear-btn:hover {
    background: #c82333;
}

/* Адаптивность */
@media (max-width: 992px) {
    .filter-section {
        flex-direction: column;
        align-items: stretch;
    }
    .filter-group {
        width: 100%;
    }
}

/* Стили для компактной статистики */
.compact-stats {
    display: inline-block;
    background: #e9ecef;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 1rem;
    border: 1px solid #ced4da;
    font-weight: 500;
}

.compact-stats span {
    font-weight: 600;
    color: #0d6efd;
}

/* Стили секции фильтров */
.filter-section {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    align-items: flex-end;
    background: #f8f9fa;
    padding: 15px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.filter-group {
    flex: 0 1 auto;
    min-width: 140px;
}

.filter-group label {
    display: block;
    font-size: 0.95rem;
    margin-bottom: 4px;
    font-weight: 800;
    color: #495057;
}

.filter-group .form-control {
    height: 38px;
    padding: 6px 12px;
    font-size: 0.95rem;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
}

.filter-group.search-group {
    min-width: 100px;
    flex: 1 1 auto;
}

.clear-btn {
    white-space: nowrap;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.clear-btn:hover {
    background: #c82333;
}

/* Оверлей */
.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.65);
    z-index: 998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    cursor: pointer;
}

.menu-overlay.active {
    opacity: 1;
    visibility: visible;
}

body.menu-open {
    overflow: hidden;
}
.form-control {
    font-weight: 600;
}
/* ФИНАЛЬНЫЕ ИСПРАВЛЕНИЯ ДЛЯ КНОПКИ ОЧИСТИТЬ */

/* Делаем все filter-group более компактными */
.filter-section .filter-group {
    min-width: 50px;  /* уменьшаем минимальную ширину */
    flex: 0 1 auto;
}

/* Группа поиска может расти */
.filter-section .search-group {
    flex: 1 1 150px;
    min-width: 120px;
}

/* Контейнер кнопки очистки */
.filter-section .clear-button-group {
    min-width: auto;
    flex: 0 0 auto;
    margin-left: auto;  /* прижимаем к правому краю */
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
}

/* Сама кнопка */
.filter-section .clear-btn {
    white-space: nowrap;
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 0 16px;
    font-size: 14px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    height: 38px;           /* ровно как у полей ввода */
    line-height: 1;
    box-shadow: none;
    transition: background 0.2s;
    /* убираем возможные лишние отступы */
    margin: 0;
}

.filter-section .clear-btn:hover {
    background: #c82333;
    color: white;
}

/* Убираем пустой label для кнопки, он не нужен */
.filter-section .clear-button-group label {
    display: none;
}

/* На мобильных кнопка на всю ширину */
@media (max-width: 992px) {
    .filter-section {
        flex-direction: column;
        align-items: stretch;
    }
    .filter-section .filter-group {
        width: 100%;
        min-width: 100%;
    }
    .filter-section .clear-button-group {
        width: 100%;
        margin-left: 0;
        margin-top: 10px;
    }
    .filter-section .clear-btn {
        width: 100%;
        justify-content: center;
    }
}
.promo-row {
    background-color: #fff3cd !important; /* светло-жёлтый */
}

.custom-tree-select {
    position: relative;
    width: 100%;
}

.tree-dropdown {
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
}

.tree-dropdown ul {
    list-style: none;
    padding-left: 20px;
    margin: 5px 0;
}

.tree-dropdown li {
    margin: 3px 0;
    cursor: pointer;
    user-select: none;
}

.tree-dropdown li span {
    display: inline-block;
    padding: 4px 8px;
    border-radius: 3px;
    transition: background 0.2s;
    width: calc(100% - 30px);
}

.tree-dropdown li span:hover {
    background: #e0e0e0;
}

.tree-dropdown li span.selected {
    background: #007bff;
    color: white;
}

.tree-dropdown .caret {
    cursor: pointer;
    display: inline-block;
    width: 20px;
    text-align: center;
    font-weight: bold;
    margin-right: 5px;
}

.tree-dropdown .caret::before {
    content: "▶";
}

.tree-dropdown .caret-down::before {
    content: "▼";
}

.tree-dropdown .nested {
    display: none;
}

.tree-dropdown .active {
    display: block;
}

.tree-dropdown .leaf {
    margin-left: 25px;
}

.category-photo-modal {
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}
