
  var gotlayers = 0;
  var TopPos = 195;
  var Shown = false;
  var Box1Left = 298;
  var Box2Left = 157;
  var Box3Left = 0;


  var in_1, out1, in_2, out2, in_3, out3, in_4, out4;
 

  if ((navigator.userAgent.substring(0,9) == "Mozilla/3") || (navigator.userAgent.substring(0,9) == "Mozilla/4"))
    ns = true;


  if (ns)
  {
    in_1 = new Image();
    in_1.src = "gfx/menu/menu1_on.gif";
    out1 = new Image();
    out1.src = "gfx/menu/menu1_off.gif";
 
    in_2 = new Image();
    in_2.src = "gfx/menu/menu2_on.gif";
    out2 = new Image();
    out2.src = "gfx/menu/menu2_off.gif";
 
    in_3 = new Image();
    in_3.src = "gfx/menu/menu3_on.gif";
    out3 = new Image();
    out3.src = "gfx/menu/menu3_off.gif";
 
    in_4 = new Image();
    in_4.src = "gfx/menu/menu4_on.gif";
    out4 = new Image();
    out4.src = "gfx/menu/menu4_off.gif";

    menI_1_1 = new Image();
    menI_1_1.src = "images/people_on.gif";
    menO_1_1 = new Image();
    menO_1_1.src = "images/people.gif";
 
    menI_1_2 = new Image();
    menI_1_2.src = "images/portfolio_on.gif";
    menO_1_2 = new Image();
    menO_1_2.src = "images/portfolio.gif";

    menI_2_1 = new Image();
    menI_2_1.src = "images/consulting_on.gif";
    menO_2_1 = new Image();
    menO_2_1.src = "images/consulting.gif";

    menI_2_2 = new Image();
    menI_2_2.src = "images/design_on.gif";
    menO_2_2 = new Image();
    menO_2_2.src = "images/design.gif";

    menI_2_3 = new Image();
    menI_2_3.src = "images/soft_dev_on.gif";
    menO_2_3 = new Image();
    menO_2_3.src = "images/soft_dev.gif";
  }
 

  function switchimage (imgname, target)
  { 
    if (ns) document.images[imgname].src = target.src;
  }


  NS4 = (document.layers) ? 1 : 0;
  IE4 = (document.all) ? 1 : 0;
  ver4 = (NS4 || IE4) ? 1 : 0;

  function moveLayers(eventObject)
  {
    if (gotlayers) 
    {
      if (!NS4) 
      {         
        document.all['SW'].style.pixelLeft   = getwidth(1);
        document.all['SW'].style.pixelTop    = TopPos - 178;         
        document.all['SC'].style.pixelLeft   = getwidth(2);          
        document.all['SC'].style.pixelTop    = TopPos - 157;
        document.all['ILLU'].style.pixelLeft = getwidth(3);
        document.all['ILLU'].style.pixelTop  = TopPos + 23;
  
      }
    }
  }


  function DropDown(menuName,on, eventObject) 
  {
    if (gotlayers) 
      if (on)  
    { 	  
      moveLayers(eventObject);  
      if (NS4) 
        document.layers[menuName].visibility = "show";
      else 
        document.all[menuName].style.visibility = "visible";
      Shown = true;
    } 
      else 
    { 	  
      if (NS4) 
        document.layers[menuName].visibility = "hide";
      else 
        document.all[menuName].style.visibility = "hidden";
      Shown = false;
    }
  }


  loaded = 1;


  function MouseMoved(eventObject, cas)
  {	
    if (Shown == false)
      if (gotlayers) 
    {
      DropDown(cas, true, eventObject);
    }
  }


  function getwidth(item)
  {
    if (document.body.clientWidth < 600)
    {
      if (item == 1) return Box1Left;
      if (item == 2) return Box2Left;
      if (item == 3) return Box3Left;
    }
      else
    {
      if (item == 1) return Box1Left + ((document.body.clientWidth - 600) / 2);
      if (item == 2) return Box2Left + ((document.body.clientWidth - 600) / 2);
      if (item == 3) return Box3Left + ((document.body.clientWidth - 600) / 2);
    }
  }
