//----------------- LES STYLES -----------------------------------------------

//-- commun Win
commun_win = '.fond 	    	{  background-image:url(library/img/bg.gif); background-repeat:repeat-x; background-color:#FFFFFF }\n';

//-- internet explorer 4.x Win  
ie4win = commun_win
ie4win += 'td  			{ font-family: Arial; font-size:10pt; color:#454E52 }\n';
ie4win += '.photo 			{ font-family: Arial; font-size:7pt; color:#687880 }\n';
ie4win += 'a:link     		{ text-decoration: none; color:#3C87C1 }\n';
ie4win += 'a:visited 		{ text-decoration: none; color:#3C87C1 }\n';
ie4win += 'a:active    		{ text-decoration: underline; color:#3C87C1 }\n';
ie4win += 'a:hover     	 	{ text-decoration: underline; color:#FE8A01 }\n';

//-- internet explorer 5.x Win & Netscape 4.x Win (+1)
ns4win = commun_win
ns4win += 'td  			{ font-family: Arial; font-size:11pt; color:#454E52 }\n';
ns4win += '.photo 			{ font-family: Arial; font-size:8pt; color:#687880 }\n';
ns4win += 'a:link     		{ text-decoration: none; color:#3C87C1 }\n';
ns4win += 'a:visited 		{ text-decoration: none; color:#3C87C1 }\n';
ns4win += 'a:active    		{ text-decoration: underline; color:#3C87C1 }\n';
ie5win = ie4win;

//-- commun Mac
commun_mac = '.fond 	    	{  background-image:url(library/img/bg.gif); background-repeat:repeat-x; background-color:#FFFFFF }\n';

//-- internet explorer 4.x Mac (+2)
ie4mac = commun_mac
ie4mac += 'td  			{ font-family: Arial; font-size:10pt; color:#454E52 }\n';
ie4mac += '.photo 			{ font-family: Arial; font-size:7pt; color:#687880 }\n';
ie4mac += 'a:link     		{ text-decoration: none; color:#3C87C1 }\n';
ie4mac += 'a:visited 		{ text-decoration: none; color:#3C87C1 }\n';
ie4mac += 'a:active    		{ text-decoration: underline; color:#3C87C1 }\n';
ie4mac += 'a:hover     	 	{ text-decoration: underline; color:#FE8A01 }\n';

//-- Netscape 4.x Mac (+4)
ns4mac = commun_mac
ns4mac += 'td  			{ font-family: Arial; font-size:11pt; color:#454E52 }\n';
ns4mac += '.photo 			{ font-family: Arial; font-size:8pt; color:#687880 }\n';
ns4mac += 'a:link     		{ text-decoration: none; color:#3C87C1 }\n';
ns4mac += 'a:visited 		{ text-decoration: none; color:#3C87C1 }\n';
ns4mac += 'a:active    		{ text-decoration: underline; color:#3C87C1 }\n';

//-- internet explorer 5.x Mac 
ie5mac = ie4win
ie5mac += '\n';

//-------------------- CODE -----------------------------------------------
//-- variables ------
var path 	= '/library/css/';
var unknown	= 0;
var win		= 1;
var mac		= 2;
var ie		= 1;
var ns		= 2;

var hstyle = '<style type="text/css">\n<!--\n';
var fstyle = '//-->\n</style>\n';

//-- init --------------
var browser = new Object();
browser.is5 = navigator.userAgent.indexOf("5.")
browser.Navigator = unknown;
browser.plateform = unknown;

//-- Quel Navigateur ---
if (navigator.appName.indexOf("Netscape") != -1) browser.navigator = ns;
else if (navigator.appName.indexOf("Microsoft") != -1) browser.navigator = ie;

//-- Quelle Plateforme ---
if (navigator.userAgent.indexOf("Win")!=-1) browser.plateform = win ;
else if (navigator.userAgent.indexOf("Mac")!=-1) browser.plateform = mac ;

with (browser) {
 switch (plateform) {
 //--- environnement WINDOWS ---
 case 1 :
  switch (navigator) {
   case 1 : //--- Internet Explorer
    	if (is5!=-1) {
    	  document.write (hstyle+ie5win+fstyle);
 	 }
    	else {
    	  document.write (hstyle+ie4win+fstyle);
    	 }

   	break;
   case 2: //-- Netscape
    	document.write (hstyle+ns4win+fstyle);
    	break;
  }
  break;
 //--- environnement MAC ---
 case 2:
  switch (navigator) {
   case 1 : //--- Internet Explorer
    	if (is5!=-1) {
          document.write (hstyle+ie5mac+fstyle);
    	 }
    	else {
          document.write (hstyle+ie4mac+fstyle);
    	 }
   	break;
   case 2 : //-- Netscape
   	document.write (hstyle+ns4mac+fstyle);
    	break;
  }
  break;

 } 
}
