/**
 * Стили для страницы Gantt Plan.
 *
 * Минимальный CSS — только то, что Bootstrap 5 не покрывает:
 * 1. Gantt page padding override
 * 2. Right panel collapse
 * 3. dhtmlxGantt task status colors
 * 4. dhtmlxGantt problem indicators
 * 5. dhtmlxGantt grid/scale overrides
 */

/* =============================================================================
 * Layout
 * ============================================================================= */

/* Убрать padding от page-container */
.gantt-page {
    padding: 0;
}

/* Свёрнутая нижняя панель */
.gantt-right-panel-collapsed {
    height: 0 !important;
    overflow: hidden;
}

/* Resize handle между Gantt и нижней панелью */
.gantt-resize-handle {
    height: 5px;
    background: #e0e0e0;
    cursor: ns-resize;
    flex-shrink: 0;
    transition: background 0.15s;
}

.gantt-resize-handle:hover,
.gantt-resize-handle.active {
    background: #2196f3;
}

/* =============================================================================
 * dhtmlxGantt — grid/scale overrides
 * ============================================================================= */

.gantt_grid_head_cell {
    background: #f5f5f5;
    border-color: #e0e0e0;
    font-weight: 600;
}

.gantt_grid_data .gantt_row {
    border-bottom: 1px solid #f0f0f0;
}

.gantt_grid_data .gantt_row:hover {
    background: #f9f9f9;
}

.gantt_scale_cell {
    background: #f5f5f5;
    border-color: #e0e0e0;
}

.gantt_task_cell.gantt_task_cell_today {
    background-color: #fff9c4;
}

.gantt_task_cell.week_end {
    background-color: #f5f5f5;
}

/* Стрелки связей */
.gantt_task_link {
    stroke: #2196f3;
    stroke-width: 2;
}

.gantt_task_link:hover {
    stroke: #1976d2;
    stroke-width: 3;
}

.gantt_task_link.link_hidden {
    display: none;
}

/* Полупрозрачность незвязанных задач */
.task_dimmed {
    opacity: 0.25;
}

/* Tooltip */
.gantt_tooltip {
    background: #fff;
    border: 1px solid #ddd;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    padding: 10px;
    font-size: 13px;
    line-height: 1.6;
}

/* =============================================================================
 * Drop target highlight (вертикальный drag между оборудованием)
 * ============================================================================= */

.gantt_row_drop_target {
    background: #e3f2fd !important;
    box-shadow: inset 0 0 0 2px #2196f3;
}

/* =============================================================================
 * Status dropdown — keep open on checkbox click
 * ============================================================================= */

.gantt-status-dropdown .dropdown-menu {
    min-width: 160px;
}
