* Ivory Coast's Gbagbo detained by French special forces
* ICE cocoa futures trim gains after rallying 3 percent
* Maersk plan to stop at Abidjan for cocoa exports Wednesday
(Adds comment, background, updates news and price)
By David Brough and Sarah McFarlane
LONDON, April 11 (Reuters) - The arrest of Ivory Coast leader Laurent Gbagbo and the lifting of European Union sanctions on the two main ports of the top cocoa producer mean cocoa exports may be possible by next week, dealers said.
Exports of stocks held at Abidjan and San Pedro should start quite quickly as the ports are secure, cocoa dealers said.
"We just need to get machinery back in there to move the containers around, which should take a week, and then get vessels booked and moved in," a dealer at an international trade house said, adding that purchasing cocoa could be trickier.
"The general process of buying cocoa would be difficult because you need cash on the ground. The supply chain for getting bush cocoa down to the port is going to be disrupted," said the dealer.
A unit of Danish shipping and oil group A.P Moller-Maersk hopes to make its first call to Abidjan on Wednesday to collect cargo including cocoa since EU sanctions were lifted, the company said on Monday.
The EU lifted sanctions on Friday on Abidjan and San Pedro as well as on the Ivorian Refining Company and the Coffee and Cocoa Trade Management Committee, following a request from presidential claimant Alassane Ouattara.
Meanwhile, French special forces have detained Gbagbo and handed him to leaders of the opposition under Alassane Outtara, after French tanks forced their way into his residence, a Gbagbo adviser in France said on Monday.
MID CROP
The EU sanctions, an export ban imposed by Ouattara and a crippled banking system have halted activity in Ivory Coast's cocoa industry in recent months.
"The EU statement is a step in the right direction for the cocoa trade," said Jonathan Parkman, joint head of agriculture at brokerage Marex Financial.
One physical cocoa trader said the EU's move was a welcome step towards resuming normal trade patterns but added, "A formal lifting of the export ban is now needed and a stop to fighting."
Dealers and analysts said that while exports may resume in the near term, concerns remained about the coming mid-crop.
Gary Mead, an analyst at VM Group, said, "The real question is -- what will be the fate of the Ivorian mid crop? All the time fighting and bloodshed and uncertainty continue, that (mid crop) has a shadow hanging over it. Longer term -- out to the 2011/12 season -- there are even more doubts."
Ivory Coast's mid-crop harvest starts this month. Many cocoa farmers have fled due to violence in the country.
The resumption of trade will also depend on restoring the country's crippled banking system.
"Without the banking system, it's hard to see how trade will resume," Parkman said.
ICE July cocoa futures was up $26, or 0.9 percent, at $3,011 a tonne at 1326 GMT. They earlier peaked at $3,079 a tonne, up over 3 percent, which compared with a 32-year high of $3,775 per tonne on March 4. (Additional reporting by Jonathan Saul, Charlie Dunmore and Michael Hogan; editing by Keiron Henderson and Jane Baird)