<?xml version="1.0" encoding="UTF-8"?>
<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL"
                  xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI"
                  xmlns:dc="http://www.omg.org/spec/DD/20100524/DC"
                  xmlns:di="http://www.omg.org/spec/DD/20100524/DI"
                  xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                  id="Definitions_Operaciones"
                  targetNamespace="http://workmed.cl/bpmn/operaciones"
                  exporter="EMERCOM SpA"
                  exporterVersion="2.0">

  <bpmn:collaboration id="Collaboration_Op">
    <bpmn:participant id="Participant_Op" name="Workmed - Operaciones · Atención Preocupacional + Acreditados + Operativos Terreno" processRef="Process_Op"/>
  </bpmn:collaboration>

  <bpmn:process id="Process_Op" isExecutable="false">
    <bpmn:laneSet id="LaneSet_Op">
      <bpmn:lane id="Lane_Trabajador" name="Trabajador (postulante)">
        <bpmn:flowNodeRef>Start_Op</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_Pablo" name="Pablo Martínez · Subgerencia Operaciones (reporta a Ricardo Jorquera)">
        <bpmn:flowNodeRef>GW_Tipo</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>Task_PrestarPersonal</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>End_OperativosTerreno</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>GW_Centro</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_JefaCentro" name="Jefa Centro · María Ignacia (Manuel Montt + jefas red)">
        <bpmn:flowNodeRef>SubProc_GestionPicos</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_CentroPropio" name="Centro Propio · Admisión + TENS Estaciones (Manuel Montt ~45% nacional)">
        <bpmn:flowNodeRef>CallAct_CentroPropio</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_CentroAcreditado" name="Centro Acreditado · Red Salud / BestMed / Copia a Po (sin Megafy ni RobleLabs)">
        <bpmn:flowNodeRef>CallAct_CentroAcreditado</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_Salubristas" name="Médicos Salubristas · Homologación parámetros por cliente">
        <bpmn:flowNodeRef>SubProc_Homologacion</bpmn:flowNodeRef>
      </bpmn:lane>
      <bpmn:lane id="Lane_Sistemas" name="Sistemas (FlowMed · SACMed · Megafy · RobleLabs · OneDrive · CEMA · LIS partners)">
        <bpmn:flowNodeRef>Task_CerrarPaquete</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>Send_Contraloria</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>End_Op</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_FlowMed</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_SACMed</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_Megafy</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_RobleLabs</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_OneDrive</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_CEMA</bpmn:flowNodeRef>
        <bpmn:flowNodeRef>DS_LIS</bpmn:flowNodeRef>
      </bpmn:lane>
    </bpmn:laneSet>

    <!-- Eventos -->
    <bpmn:startEvent id="Start_Op" name="OS confirmada en FlowMed (handoff desde Agendamiento)">
      <bpmn:outgoing>F1</bpmn:outgoing>
    </bpmn:startEvent>
    <bpmn:endEvent id="End_OperativosTerreno" name="Servicio prestado a Operativos Terreno (RN-08 · HU-07)">
      <bpmn:incoming>F_OT_END</bpmn:incoming>
    </bpmn:endEvent>
    <bpmn:endEvent id="End_Op" name="Paquete entregado a Contraloría · SLA 8h activo (RN-06 · HU-10)">
      <bpmn:incoming>F_END</bpmn:incoming>
    </bpmn:endEvent>

    <!-- Pablo · Gateways y operativos terreno -->
    <bpmn:exclusiveGateway id="GW_Tipo" name="¿Operativos Terreno o Preocupacional?">
      <bpmn:incoming>F1</bpmn:incoming>
      <bpmn:outgoing>F_OT</bpmn:outgoing>
      <bpmn:outgoing>F_PRE</bpmn:outgoing>
    </bpmn:exclusiveGateway>
    <bpmn:userTask id="Task_PrestarPersonal" name="Prestar personal clínico (servicio, no liderado · RN-08 · HU-07)">
      <bpmn:incoming>F_OT</bpmn:incoming>
      <bpmn:outgoing>F_OT_END</bpmn:outgoing>
    </bpmn:userTask>
    <bpmn:exclusiveGateway id="GW_Centro" name="¿Centro propio o acreditado? (RN-01 / RN-05)">
      <bpmn:incoming>F_PRE</bpmn:incoming>
      <bpmn:outgoing>F_PROP</bpmn:outgoing>
      <bpmn:outgoing>F_ACR</bpmn:outgoing>
    </bpmn:exclusiveGateway>

    <!-- Call activities -->
    <bpmn:callActivity id="CallAct_CentroPropio" name="Atención Centro Propio (ver preocupacional-centro-propio.bpmn)" calledElement="Process_CP">
      <bpmn:incoming>F_PROP</bpmn:incoming>
      <bpmn:outgoing>F_PROP_OUT</bpmn:outgoing>
    </bpmn:callActivity>
    <bpmn:callActivity id="CallAct_CentroAcreditado" name="Atención Centro Acreditado (ver preocupacional-centro-no-propio.bpmn)" calledElement="Process_CA">
      <bpmn:incoming>F_ACR</bpmn:incoming>
      <bpmn:outgoing>F_ACR_OUT</bpmn:outgoing>
    </bpmn:callActivity>

    <!-- Sub-process Jefa Centro · gestión picos -->
    <bpmn:subProcess id="SubProc_GestionPicos" name="Gestión de pico (HU-08 · HU-09 · RN-10) · paralelo">
      <bpmn:incoming>F_PRE_PICO</bpmn:incoming>
      <bpmn:outgoing>F_PICO_OUT</bpmn:outgoing>

      <bpmn:startEvent id="GP_Start" name="Pico detectado">
        <bpmn:outgoing>GP_F1</bpmn:outgoing>
      </bpmn:startEvent>
      <bpmn:manualTask id="GP_Detectar" name="Detectar pico (Lunes 160-200, buses Fluor Salfa 120, BHP 200) · HU-08 · HU-09">
        <bpmn:incoming>GP_F1</bpmn:incoming>
        <bpmn:outgoing>GP_F2</bpmn:outgoing>
      </bpmn:manualTask>
      <bpmn:userTask id="GP_Activar" name="Activar Manpower / Line · capacidad sin tope (RN-10)">
        <bpmn:incoming>GP_F2</bpmn:incoming>
        <bpmn:outgoing>GP_F3</bpmn:outgoing>
      </bpmn:userTask>
      <bpmn:userTask id="GP_Comunicar" name="Comunicar espera (5h+, galletitas/juguito a las 9:00 y 12:30)">
        <bpmn:incoming>GP_F3</bpmn:incoming>
        <bpmn:outgoing>GP_F4</bpmn:outgoing>
      </bpmn:userTask>
      <bpmn:manualTask id="GP_Corregir" name="Corrección manualidades hasta 20:00 (RUT mal, fechas, género · HU-09)">
        <bpmn:incoming>GP_F4</bpmn:incoming>
        <bpmn:outgoing>GP_F5</bpmn:outgoing>
      </bpmn:manualTask>
      <bpmn:endEvent id="GP_End" name="Pico absorbido">
        <bpmn:incoming>GP_F5</bpmn:incoming>
      </bpmn:endEvent>

      <bpmn:sequenceFlow id="GP_F1" sourceRef="GP_Start" targetRef="GP_Detectar"/>
      <bpmn:sequenceFlow id="GP_F2" sourceRef="GP_Detectar" targetRef="GP_Activar"/>
      <bpmn:sequenceFlow id="GP_F3" sourceRef="GP_Activar" targetRef="GP_Comunicar"/>
      <bpmn:sequenceFlow id="GP_F4" sourceRef="GP_Comunicar" targetRef="GP_Corregir"/>
      <bpmn:sequenceFlow id="GP_F5" sourceRef="GP_Corregir" targetRef="GP_End"/>
    </bpmn:subProcess>

    <!-- Sub-process Salubristas · homologación parámetros -->
    <bpmn:subProcess id="SubProc_Homologacion" name="Homologación parámetros por cliente (HU-06 · RN-07) · paralelo">
      <bpmn:incoming>F_PRE_HOM</bpmn:incoming>
      <bpmn:outgoing>F_HOM_OUT</bpmn:outgoing>

      <bpmn:startEvent id="HM_Start" name="Cliente nuevo / cambio">
        <bpmn:outgoing>HM_F1</bpmn:outgoing>
      </bpmn:startEvent>
      <bpmn:userTask id="HM_Reunion" name="Reunión con cliente sobre evidencia y población (HU-06)">
        <bpmn:incoming>HM_F1</bpmn:incoming>
        <bpmn:outgoing>HM_F2</bpmn:outgoing>
      </bpmn:userTask>
      <bpmn:userTask id="HM_Definir" name="Definir parámetros homologados (Fluor Salfa IGE ≤7, BHP IMC ≤32.9, faena ≤33.9 · RN-07)">
        <bpmn:incoming>HM_F2</bpmn:incoming>
        <bpmn:outgoing>HM_F3</bpmn:outgoing>
      </bpmn:userTask>
      <bpmn:serviceTask id="HM_Documentar" name="Documentar set de parámetros para Contraloría">
        <bpmn:incoming>HM_F3</bpmn:incoming>
        <bpmn:outgoing>HM_F4</bpmn:outgoing>
      </bpmn:serviceTask>
      <bpmn:endEvent id="HM_End" name="Set documentado">
        <bpmn:incoming>HM_F4</bpmn:incoming>
      </bpmn:endEvent>

      <bpmn:sequenceFlow id="HM_F1" sourceRef="HM_Start" targetRef="HM_Reunion"/>
      <bpmn:sequenceFlow id="HM_F2" sourceRef="HM_Reunion" targetRef="HM_Definir"/>
      <bpmn:sequenceFlow id="HM_F3" sourceRef="HM_Definir" targetRef="HM_Documentar"/>
      <bpmn:sequenceFlow id="HM_F4" sourceRef="HM_Documentar" targetRef="HM_End"/>
    </bpmn:subProcess>

    <!-- Convergencia y handoff -->
    <bpmn:userTask id="Task_CerrarPaquete" name="Cerrar paquete clínico (SACMed centro propio / OneDrive acreditado · contradicción §6.1)">
      <bpmn:incoming>F_PROP_OUT</bpmn:incoming>
      <bpmn:incoming>F_ACR_OUT</bpmn:incoming>
      <bpmn:incoming>F_PICO_OUT</bpmn:incoming>
      <bpmn:incoming>F_HOM_OUT</bpmn:incoming>
      <bpmn:outgoing>F_HANDOFF</bpmn:outgoing>
    </bpmn:userTask>
    <bpmn:sendTask id="Send_Contraloria" name="Handoff a Contraloría (HU-10)">
      <bpmn:incoming>F_HANDOFF</bpmn:incoming>
      <bpmn:outgoing>F_END</bpmn:outgoing>
    </bpmn:sendTask>

    <!-- Sistemas -->
    <bpmn:dataStoreReference id="DS_FlowMed" name="FlowMed (core)"/>
    <bpmn:dataStoreReference id="DS_SACMed" name="SACMed (HIS · sólo 2 informes auto · RN-09)"/>
    <bpmn:dataStoreReference id="DS_Megafy" name="Megafy / Appian (preadmisión)"/>
    <bpmn:dataStoreReference id="DS_RobleLabs" name="RobleLabs (cédula+huella · RN-02)"/>
    <bpmn:dataStoreReference id="DS_OneDrive" name="OneDrive (acreditados · RN-05)"/>
    <bpmn:dataStoreReference id="DS_CEMA" name="CEMA (Cardiomedics ECG/espir)"/>
    <bpmn:dataStoreReference id="DS_LIS" name="LIS partners (Bionet · LaboCenter · Workmed · Blanco)"/>

    <!-- Eventos paralelos para subprocesos · sequence flows -->
    <bpmn:sequenceFlow id="F_PRE_PICO" sourceRef="GW_Centro" targetRef="SubProc_GestionPicos"/>
    <bpmn:sequenceFlow id="F_PRE_HOM" sourceRef="GW_Centro" targetRef="SubProc_Homologacion"/>

    <!-- Text annotations · RN-01 a RN-10 -->
    <bpmn:textAnnotation id="Ann_RN01">
      <bpmn:text>RN-01 · Preadmisión obligatoria por Megafy en centros propios (todos los pacientes salvo acreditados) [Operaciones-20260407 35:42, 56:32]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN01" sourceRef="Ann_RN01" targetRef="CallAct_CentroPropio"/>

    <bpmn:textAnnotation id="Ann_RN02">
      <bpmn:text>RN-02 · Validación biométrica RobleLabs sólo en admisión y drogas. Trabajadores intentan engañar también en audiometría/antropometría [Operaciones-20260407 1:03:33, 1:04:15]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN02" sourceRef="Ann_RN02" targetRef="CallAct_CentroPropio"/>

    <bpmn:textAnnotation id="Ann_RN03">
      <bpmn:text>RN-03 · TENS reingresa identificadores 6+ veces por persona/día. Errores RUT/género/fecha arrastran a cobranza con atrasos hasta 30 días [Operaciones-20260407 11:43, 12:38, 13:09, 33:49]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN03" sourceRef="Ann_RN03" targetRef="CallAct_CentroPropio"/>

    <bpmn:textAnnotation id="Ann_RN04">
      <bpmn:text>RN-04 · Enrutamiento manual de muestras. Cadena custodia + documentación particular por LIS. Hasta 4 LIS por persona en Santiago. "Pero tengo que detectarlo yo" (María Ignacia) [Operaciones-20260407 16:01, 16:22, 16:53]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN04" sourceRef="Ann_RN04" targetRef="CallAct_CentroPropio"/>

    <bpmn:textAnnotation id="Ann_RN05">
      <bpmn:text>RN-05 · Centros acreditados consolidan vía OneDrive · NO usan Megafy ni RobleLabs ni SACMed. Onboarding presencial en FlowMed con papeles físicos [Operaciones-20260407 17:15, 56:32, 1:02:08]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN05" sourceRef="Ann_RN05" targetRef="CallAct_CentroAcreditado"/>

    <bpmn:textAnnotation id="Ann_RN06">
      <bpmn:text>RN-06 · SLA 8 horas desde checkout. "Pero para eso volamos" [Operaciones-20260407 23:30]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN06" sourceRef="Ann_RN06" targetRef="Send_Contraloria"/>

    <bpmn:textAnnotation id="Ann_RN07">
      <bpmn:text>RN-07 · Parámetros homologados por cliente sobre acuerdo minero base. Médicos salubristas definen, Contraloría aplica [Operaciones-20260407 6:51, 7:43, 8:12, 9:08]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN07" sourceRef="Ann_RN07" targetRef="SubProc_Homologacion"/>

    <bpmn:textAnnotation id="Ann_RN08">
      <bpmn:text>RN-08 · Operativos en terreno = servicio prestado, no liderado. Subgerencia distinta coordina con Comercial; Operaciones aporta personal clínico [Operaciones-20260407 2:50, 3:18]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN08" sourceRef="Ann_RN08" targetRef="Task_PrestarPersonal"/>

    <bpmn:textAnnotation id="Ann_RN09">
      <bpmn:text>RN-09 · SACMed sólo emite auto: audiometría encaninada + screening vestibular (sólo si admisión bien capturada); resto manual [Operaciones-20260407 12:12]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN09" sourceRef="Ann_RN09" targetRef="Task_CerrarPaquete"/>

    <bpmn:textAnnotation id="Ann_RN10">
      <bpmn:text>RN-10 · Capacidad sin tope · agenda abierta. BHP 200 personas un lunes; Workmed compromete y absorbe peak con personal externo [Operaciones-20260407 25:20]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_RN10" sourceRef="Ann_RN10" targetRef="SubProc_GestionPicos"/>

    <bpmn:textAnnotation id="Ann_Excepciones">
      <bpmn:text>Excepciones críticas · §2.5 · RUTs con cero adelante: FlowMed no limpia el cero (atrasos hasta 30 días en cobranza) · Buses Concepción 120 personas revientan bloque 7:30 · SACMed sólo emite 2 informes auto (audiometría/screening vestibular)</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_Excep" sourceRef="Ann_Excepciones" targetRef="Task_CerrarPaquete"/>

    <bpmn:textAnnotation id="Ann_Contradic">
      <bpmn:text>Contradicción §6.1 · "FlowMed = 100% post-SACMed" (Llancao) [Flowmed-20260409 23:53] vs UCI usa 2 orígenes según sucursal: SACMed via botón espejo (6/12 propias) o SharePoint con digitación manual (acreditadas) [Contraloria-20260421 12:30, 12:46]</bpmn:text>
    </bpmn:textAnnotation>
    <bpmn:association id="Assoc_Contradic" sourceRef="Ann_Contradic" targetRef="Task_CerrarPaquete"/>

    <!-- Sequence flows principales -->
    <bpmn:sequenceFlow id="F1" sourceRef="Start_Op" targetRef="GW_Tipo"/>
    <bpmn:sequenceFlow id="F_OT" name="Operativos Terreno (RN-08)" sourceRef="GW_Tipo" targetRef="Task_PrestarPersonal"/>
    <bpmn:sequenceFlow id="F_PRE" name="Preocupacional" sourceRef="GW_Tipo" targetRef="GW_Centro"/>
    <bpmn:sequenceFlow id="F_OT_END" sourceRef="Task_PrestarPersonal" targetRef="End_OperativosTerreno"/>
    <bpmn:sequenceFlow id="F_PROP" name="Centro Propio (RN-01)" sourceRef="GW_Centro" targetRef="CallAct_CentroPropio"/>
    <bpmn:sequenceFlow id="F_ACR" name="Centro Acreditado (RN-05)" sourceRef="GW_Centro" targetRef="CallAct_CentroAcreditado"/>
    <bpmn:sequenceFlow id="F_PROP_OUT" sourceRef="CallAct_CentroPropio" targetRef="Task_CerrarPaquete"/>
    <bpmn:sequenceFlow id="F_ACR_OUT" sourceRef="CallAct_CentroAcreditado" targetRef="Task_CerrarPaquete"/>
    <bpmn:sequenceFlow id="F_PICO_OUT" sourceRef="SubProc_GestionPicos" targetRef="Task_CerrarPaquete"/>
    <bpmn:sequenceFlow id="F_HOM_OUT" sourceRef="SubProc_Homologacion" targetRef="Task_CerrarPaquete"/>
    <bpmn:sequenceFlow id="F_HANDOFF" sourceRef="Task_CerrarPaquete" targetRef="Send_Contraloria"/>
    <bpmn:sequenceFlow id="F_END" sourceRef="Send_Contraloria" targetRef="End_Op"/>
  </bpmn:process>

  <!-- =====================================================
       DI Layout
       Pool x=120 y=60 w=4200 h=1620
       Lanes:
         Trabajador      y=60   h=120  (60..180)
         Pablo           y=180  h=200  (180..380)
         JefaCentro      y=380  h=180  (380..560)
         CentroPropio    y=560  h=200  (560..760)
         CentroAcred     y=760  h=200  (760..960)
         Salubristas     y=960  h=180  (960..1140)
         Sistemas        y=1140 h=540  (1140..1680)
       Annotations: y=1700..1900 below pool (no overlap)
       ===================================================== -->
  <bpmndi:BPMNDiagram id="Diagram_Op">
    <bpmndi:BPMNPlane id="Plane_Op" bpmnElement="Collaboration_Op">

      <bpmndi:BPMNShape id="Participant_Op_di" bpmnElement="Participant_Op" isHorizontal="true">
        <dc:Bounds x="120" y="60" width="4200" height="1620"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_Trabajador_di" bpmnElement="Lane_Trabajador" isHorizontal="true">
        <dc:Bounds x="150" y="60" width="4170" height="120"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_Pablo_di" bpmnElement="Lane_Pablo" isHorizontal="true">
        <dc:Bounds x="150" y="180" width="4170" height="200"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_JefaCentro_di" bpmnElement="Lane_JefaCentro" isHorizontal="true">
        <dc:Bounds x="150" y="380" width="4170" height="180"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_CentroPropio_di" bpmnElement="Lane_CentroPropio" isHorizontal="true">
        <dc:Bounds x="150" y="560" width="4170" height="200"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_CentroAcreditado_di" bpmnElement="Lane_CentroAcreditado" isHorizontal="true">
        <dc:Bounds x="150" y="760" width="4170" height="200"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_Salubristas_di" bpmnElement="Lane_Salubristas" isHorizontal="true">
        <dc:Bounds x="150" y="960" width="4170" height="180"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Lane_Sistemas_di" bpmnElement="Lane_Sistemas" isHorizontal="true">
        <dc:Bounds x="150" y="1140" width="4170" height="540"/>
      </bpmndi:BPMNShape>

      <!-- Trabajador -->
      <bpmndi:BPMNShape id="Start_Op_di" bpmnElement="Start_Op">
        <dc:Bounds x="220" y="102" width="36" height="36"/>
        <bpmndi:BPMNLabel><dc:Bounds x="180" y="145" width="120" height="30"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>

      <!-- Pablo (y=180..380, mid 280) -->
      <bpmndi:BPMNShape id="GW_Tipo_di" bpmnElement="GW_Tipo" isMarkerVisible="true">
        <dc:Bounds x="500" y="255" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="445" y="310" width="160" height="30"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Task_PrestarPersonal_di" bpmnElement="Task_PrestarPersonal">
        <dc:Bounds x="700" y="200" width="280" height="60"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="End_OperativosTerreno_di" bpmnElement="End_OperativosTerreno">
        <dc:Bounds x="1042" y="212" width="36" height="36"/>
        <bpmndi:BPMNLabel><dc:Bounds x="990" y="255" width="160" height="30"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="GW_Centro_di" bpmnElement="GW_Centro" isMarkerVisible="true">
        <dc:Bounds x="900" y="305" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="845" y="285" width="160" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>

      <!-- Jefa Centro (y=380..560, mid 470) -->
      <bpmndi:BPMNShape id="SubProc_GestionPicos_di" bpmnElement="SubProc_GestionPicos" isExpanded="false">
        <dc:Bounds x="1500" y="420" width="300" height="100"/>
      </bpmndi:BPMNShape>

      <!-- Centro Propio (y=560..760, mid 660) -->
      <bpmndi:BPMNShape id="CallAct_CentroPropio_di" bpmnElement="CallAct_CentroPropio">
        <dc:Bounds x="1500" y="610" width="320" height="100"/>
      </bpmndi:BPMNShape>

      <!-- Centro Acreditado (y=760..960, mid 860) -->
      <bpmndi:BPMNShape id="CallAct_CentroAcreditado_di" bpmnElement="CallAct_CentroAcreditado">
        <dc:Bounds x="1500" y="810" width="320" height="100"/>
      </bpmndi:BPMNShape>

      <!-- Salubristas (y=960..1140, mid 1050) -->
      <bpmndi:BPMNShape id="SubProc_Homologacion_di" bpmnElement="SubProc_Homologacion" isExpanded="false">
        <dc:Bounds x="1500" y="1000" width="320" height="100"/>
      </bpmndi:BPMNShape>

      <!-- Sistemas (y=1140..1680) -->
      <bpmndi:BPMNShape id="Task_CerrarPaquete_di" bpmnElement="Task_CerrarPaquete">
        <dc:Bounds x="2400" y="1180" width="320" height="100"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Send_Contraloria_di" bpmnElement="Send_Contraloria">
        <dc:Bounds x="2820" y="1180" width="220" height="100"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="End_Op_di" bpmnElement="End_Op">
        <dc:Bounds x="3120" y="1212" width="36" height="36"/>
        <bpmndi:BPMNLabel><dc:Bounds x="3060" y="1255" width="180" height="50"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>

      <!-- Datastores (y=1380..1430) -->
      <bpmndi:BPMNShape id="DS_Megafy_di" bpmnElement="DS_Megafy">
        <dc:Bounds x="280" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="240" y="1435" width="140" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_RobleLabs_di" bpmnElement="DS_RobleLabs">
        <dc:Bounds x="500" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="455" y="1435" width="160" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_FlowMed_di" bpmnElement="DS_FlowMed">
        <dc:Bounds x="720" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="680" y="1435" width="140" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_SACMed_di" bpmnElement="DS_SACMed">
        <dc:Bounds x="940" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="880" y="1435" width="180" height="40"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_OneDrive_di" bpmnElement="DS_OneDrive">
        <dc:Bounds x="1200" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="1140" y="1435" width="180" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_CEMA_di" bpmnElement="DS_CEMA">
        <dc:Bounds x="1430" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="1370" y="1435" width="180" height="20"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="DS_LIS_di" bpmnElement="DS_LIS">
        <dc:Bounds x="1660" y="1380" width="50" height="50"/>
        <bpmndi:BPMNLabel><dc:Bounds x="1580" y="1435" width="220" height="40"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNShape>

      <!-- Annotations (below pool y=1700+) -->
      <bpmndi:BPMNShape id="Ann_RN01_di" bpmnElement="Ann_RN01">
        <dc:Bounds x="200" y="1700" width="300" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN02_di" bpmnElement="Ann_RN02">
        <dc:Bounds x="540" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN03_di" bpmnElement="Ann_RN03">
        <dc:Bounds x="900" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN04_di" bpmnElement="Ann_RN04">
        <dc:Bounds x="1260" y="1700" width="340" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN05_di" bpmnElement="Ann_RN05">
        <dc:Bounds x="1640" y="1700" width="340" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN06_di" bpmnElement="Ann_RN06">
        <dc:Bounds x="2020" y="1700" width="280" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN07_di" bpmnElement="Ann_RN07">
        <dc:Bounds x="2340" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN08_di" bpmnElement="Ann_RN08">
        <dc:Bounds x="2700" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN09_di" bpmnElement="Ann_RN09">
        <dc:Bounds x="3060" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_RN10_di" bpmnElement="Ann_RN10">
        <dc:Bounds x="3420" y="1700" width="320" height="80"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_Excepciones_di" bpmnElement="Ann_Excepciones">
        <dc:Bounds x="200" y="1820" width="700" height="100"/>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Ann_Contradic_di" bpmnElement="Ann_Contradic">
        <dc:Bounds x="940" y="1820" width="800" height="100"/>
      </bpmndi:BPMNShape>

      <!-- ====== EDGES ====== -->
      <!-- Start → GW_Tipo (downward) -->
      <bpmndi:BPMNEdge id="F1_di" bpmnElement="F1">
        <di:waypoint x="238" y="138"/><di:waypoint x="238" y="280"/>
        <di:waypoint x="500" y="280"/>
      </bpmndi:BPMNEdge>
      <!-- GW_Tipo → Task_PrestarPersonal (upper branch · operativos terreno) -->
      <bpmndi:BPMNEdge id="F_OT_di" bpmnElement="F_OT">
        <di:waypoint x="525" y="255"/><di:waypoint x="525" y="230"/>
        <di:waypoint x="700" y="230"/>
        <bpmndi:BPMNLabel><dc:Bounds x="540" y="210" width="180" height="14"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_OT_END_di" bpmnElement="F_OT_END">
        <di:waypoint x="980" y="230"/><di:waypoint x="1042" y="230"/>
      </bpmndi:BPMNEdge>
      <!-- GW_Tipo → GW_Centro (lower branch · preocupacional) -->
      <bpmndi:BPMNEdge id="F_PRE_di" bpmnElement="F_PRE">
        <di:waypoint x="525" y="305"/><di:waypoint x="525" y="330"/>
        <di:waypoint x="900" y="330"/>
        <bpmndi:BPMNLabel><dc:Bounds x="600" y="335" width="160" height="14"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <!-- GW_Centro → CallAct_CentroPropio -->
      <bpmndi:BPMNEdge id="F_PROP_di" bpmnElement="F_PROP">
        <di:waypoint x="950" y="330"/><di:waypoint x="1850" y="330"/>
        <di:waypoint x="1850" y="610"/><di:waypoint x="1820" y="610"/>
        <bpmndi:BPMNLabel><dc:Bounds x="1100" y="310" width="200" height="14"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <!-- GW_Centro → CallAct_CentroAcreditado -->
      <bpmndi:BPMNEdge id="F_ACR_di" bpmnElement="F_ACR">
        <di:waypoint x="925" y="355"/><di:waypoint x="925" y="860"/>
        <di:waypoint x="1500" y="860"/>
        <bpmndi:BPMNLabel><dc:Bounds x="935" y="600" width="200" height="14"/></bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <!-- GW_Centro → SubProc_GestionPicos (paralelo) -->
      <bpmndi:BPMNEdge id="F_PRE_PICO_di" bpmnElement="F_PRE_PICO">
        <di:waypoint x="950" y="330"/><di:waypoint x="1330" y="330"/>
        <di:waypoint x="1330" y="470"/><di:waypoint x="1500" y="470"/>
      </bpmndi:BPMNEdge>
      <!-- GW_Centro → SubProc_Homologacion (paralelo) -->
      <bpmndi:BPMNEdge id="F_PRE_HOM_di" bpmnElement="F_PRE_HOM">
        <di:waypoint x="925" y="355"/><di:waypoint x="925" y="1050"/>
        <di:waypoint x="1500" y="1050"/>
      </bpmndi:BPMNEdge>
      <!-- Convergencia · 4 incoming a Task_CerrarPaquete -->
      <bpmndi:BPMNEdge id="F_PROP_OUT_di" bpmnElement="F_PROP_OUT">
        <di:waypoint x="1820" y="660"/><di:waypoint x="2200" y="660"/>
        <di:waypoint x="2200" y="1230"/><di:waypoint x="2400" y="1230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_ACR_OUT_di" bpmnElement="F_ACR_OUT">
        <di:waypoint x="1820" y="860"/><di:waypoint x="2240" y="860"/>
        <di:waypoint x="2240" y="1230"/><di:waypoint x="2400" y="1230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_PICO_OUT_di" bpmnElement="F_PICO_OUT">
        <di:waypoint x="1800" y="470"/><di:waypoint x="2160" y="470"/>
        <di:waypoint x="2160" y="1230"/><di:waypoint x="2400" y="1230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_HOM_OUT_di" bpmnElement="F_HOM_OUT">
        <di:waypoint x="1820" y="1050"/><di:waypoint x="2280" y="1050"/>
        <di:waypoint x="2280" y="1230"/><di:waypoint x="2400" y="1230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_HANDOFF_di" bpmnElement="F_HANDOFF">
        <di:waypoint x="2720" y="1230"/><di:waypoint x="2820" y="1230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="F_END_di" bpmnElement="F_END">
        <di:waypoint x="3040" y="1230"/><di:waypoint x="3120" y="1230"/>
      </bpmndi:BPMNEdge>

      <!-- Annotations associations -->
      <!-- Para evitar cruzar los call activities/subprocs en x=1500..1820, ruteamos por x<1500 (izquierda) o x>1820 (derecha) -->
      <bpmndi:BPMNEdge id="Assoc_RN01_di" bpmnElement="Assoc_RN01">
        <di:waypoint x="350" y="1700"/><di:waypoint x="350" y="660"/>
        <di:waypoint x="1500" y="660"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN02_di" bpmnElement="Assoc_RN02">
        <di:waypoint x="700" y="1700"/><di:waypoint x="700" y="640"/>
        <di:waypoint x="1500" y="640"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN03_di" bpmnElement="Assoc_RN03">
        <di:waypoint x="1060" y="1700"/><di:waypoint x="1060" y="680"/>
        <di:waypoint x="1500" y="680"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN04_di" bpmnElement="Assoc_RN04">
        <di:waypoint x="1430" y="1700"/><di:waypoint x="1430" y="700"/>
        <di:waypoint x="1500" y="700"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN05_di" bpmnElement="Assoc_RN05">
        <di:waypoint x="1810" y="1700"/><di:waypoint x="1900" y="1700"/>
        <di:waypoint x="1900" y="860"/><di:waypoint x="1820" y="860"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN06_di" bpmnElement="Assoc_RN06">
        <di:waypoint x="2160" y="1700"/><di:waypoint x="2160" y="1610"/>
        <di:waypoint x="2930" y="1610"/><di:waypoint x="2930" y="1280"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN07_di" bpmnElement="Assoc_RN07">
        <di:waypoint x="2380" y="1700"/><di:waypoint x="2380" y="1050"/>
        <di:waypoint x="1820" y="1050"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN08_di" bpmnElement="Assoc_RN08">
        <di:waypoint x="2860" y="1700"/><di:waypoint x="2860" y="1590"/>
        <di:waypoint x="1010" y="1590"/><di:waypoint x="1010" y="260"/>
        <di:waypoint x="980" y="260"/><di:waypoint x="980" y="230"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN09_di" bpmnElement="Assoc_RN09">
        <di:waypoint x="3220" y="1700"/><di:waypoint x="3220" y="1330"/>
        <di:waypoint x="2540" y="1330"/><di:waypoint x="2540" y="1280"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_RN10_di" bpmnElement="Assoc_RN10">
        <di:waypoint x="3580" y="1700"/><di:waypoint x="3580" y="470"/>
        <di:waypoint x="1800" y="470"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_Excep_di" bpmnElement="Assoc_Excep">
        <di:waypoint x="500" y="1820"/><di:waypoint x="500" y="1530"/>
        <di:waypoint x="2620" y="1530"/><di:waypoint x="2620" y="1280"/>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Assoc_Contradic_di" bpmnElement="Assoc_Contradic">
        <di:waypoint x="1740" y="1820"/><di:waypoint x="1740" y="1790"/>
        <di:waypoint x="1980" y="1790"/><di:waypoint x="1980" y="1500"/>
        <di:waypoint x="2680" y="1500"/><di:waypoint x="2680" y="1280"/>
      </bpmndi:BPMNEdge>

    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>

</bpmn:definitions>
