/*****************************************************************************
It is adviced to place the sIFR JavaScript calls in this file, keeping it
separate from the `sifr.js` file. That way, you can easily swap the `sifr.js`
file for a new version, while keeping the configuration.

You must load this file *after* loading `sifr.js`.

That said, you're of course free to merge the JavaScript files. Just make sure
the copyright statement in `sifr.js` is kept intact.
*****************************************************************************/

// Make an object pointing to the location of the Flash movie on your web server.
// Try using the font name as the variable name, makes it easy to remember which
// object you're using. As an example in this file, we'll use Futura.
// var futura = { src: '/path/to/futura.swf' };

// Now you can set some configuration settings.
// See also <http://wiki.novemberborn.net/sifr3/JavaScript+Configuration>.
// One setting you probably want to use is `sIFR.useStyleCheck`. Before you do that,
// read <http://wiki.novemberborn.net/sifr3/DetectingCSSLoad>.

// sIFR.useStyleCheck = true;

// Next, activate sIFR:
// sIFR.activate(futura);

// If you want, you can use multiple movies, like so:
//
//    var futura = { src: '/path/to/futura.swf' };
//    var garamond = { src '/path/to/garamond.swf' };
//    var rockwell = { src: '/path/to/rockwell.swf' };
//    
//    sIFR.activate(futura, garamond, rockwell);
//
// Remember, there must be *only one* `sIFR.activate()`!

// Now we can do the replacements. You can do as many as you like, but just
// as an example, we'll replace all `<h1>` elements with the Futura movie.
// 
// The first argument to `sIFR.replace` is the `futura` object we created earlier.
// The second argument is another object, on which you can specify a number of
// parameters or "keyword arguemnts". For the full list, see "Keyword arguments"
// under `replace(kwargs, mergeKwargs)` at 
// <http://wiki.novemberborn.net/sifr3/JavaScript+Methods>.
// 
// The first argument you see here is `selector`, which is a normal CSS selector.
// That means you can also do things like '#content h1' or 'h1.title'.
//
// The second argument determines what the Flash text looks like. The main text
// is styled via the `.sIFR-root` class. Here we've specified `background-color`
// of the entire Flash movie to be a light grey, and the `color` of the text to
// be red. Read more about styling at <http://wiki.novemberborn.net/sifr3/Styling>.
/* sIFR.replace(futura, {
  selector: 'h1',
  css: '.sIFR-root { background-color: #F9F9F9; color: #FF0000; }'
}); */

var amwayOpti = { src: '/flash/amwayopti.swf' };
var amwayOptiBold = { src: '/flash/amwayoptibold.swf' };
var helveticaNeueLtStd = { src: '/flash/helveticaneueltstd.swf' };

sIFR.activate(amwayOpti, amwayOptiBold, helveticaNeueLtStd);

// Global nav states.
sIFR.replace(amwayOpti, {
  selector: 'div#bgNav ul li',
  css: [
		'.sIFR-root { text-transform: uppercase; letter-spacing: 1.2; font-size: 12px; }',
		'a { color: #999999; text-decoration: none; }',
		'a:hover { color: #ffffff; }',
		'.navOn { color: #ffffff }'
	],
	wmode: 'transparent',
	forceSingleLine: true,
	tuneHeight: -7,
	offsetTop: 2
});

// Product page headings.
sIFR.replace(amwayOptiBold, {
  selector: 'h1.colour',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #cd5a13; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.colour2',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #cd5a13; text-align: right; leading: -26; }',
		'.txtTop { font-size: 25px; leading: -13; display: block; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -22,
	offsetTop: -15,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.frizz',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #003592; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.frizz2',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #003592; text-align: right; leading: -26; }',
		'.txtTop { font-size: 25px; leading: -13; display: block; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -22,
	offsetTop: -15,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.lusciousLong',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #ad1015; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.lusciousLong2',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #ad1015; text-align: right; leading: -26; }',
		'.txtTop { font-size: 25px; leading: -13; display: block; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -22,
	offsetTop: -15,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.miracleMoist',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #0072b1; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.miracleMoist2',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #0072b1; text-align: right; leading: -26; }',
		'.txtTop { font-size: 25px; leading: -13; display: block; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -22,
	offsetTop: -15,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.miracleMoist3',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 28px; color: #0072b1; text-align: right; leading: -18; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
	selector: 'h1.miracleReconstructor',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #ad1015; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.mega',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #96004b; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.mega2',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #96004b; text-align: right; leading: -26; }',
		'.txtTop { font-size: 25px; leading: -13; display: block; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -22,
	offsetTop: -15,
	offsetLeft: 3
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1.volume',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 35px; color: #006579; text-align: right; leading: -26; }',
		'.txtBtm { font-size: 15px; display: block; }'
	],
	wmode: 'transparent',
	tuneHeight: -12,
	offsetTop: -5,
	offsetLeft: 3
});

// Add to my Hair Must-Haves link.
sIFR.replace(amwayOptiBold, {
  selector: 'div#containerAddHairMustHaves a',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 19px; color: #970bb3; leading: -7; }'
	],
	wmode: 'transparent',
	tuneHeight: -10,
	offsetTop: -5
});

// You may also like... heading.
sIFR.replace(amwayOptiBold, {
  selector: 'div#containerAlsoLike h3',
  css: [
		'.sIFR-root { font-size: 20px; color: #999999; }'
	],
	wmode: 'transparent',
	tuneHeight: -10,
	offsetTop: -5
});

// Frizz forecast callout.
sIFR.replace(helveticaNeueLtStd, {
  selector: 'div#calloutFrizzForecast a',
  css: [
		'.sIFR-root { font-size: 13px; font-weight: bold; color: #ffffff; leading: -4; cursor: pointer; }',
		'.span { font-size: 10px; }'
	],
	wmode: 'transparent',
	tuneHeight: -8,
	offsetTop: -3
});

// Frizz forecast callout 2.
sIFR.replace(helveticaNeueLtStd, {
  selector: 'div#calloutFrizzForecast2 a',
  css: [
		'.sIFR-root { font-size: 29px; font-weight: bold; color: #ffffff; leading: -8; cursor: pointer; }',
		'.span { font-size: 17px; }',
		//'.break { font-size: 12px; }',
		'.download { font-size: 17px; leading: -14; }'
	],
	wmode: 'transparent',
	tuneHeight: -20,
	offsetTop: -16
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsFrizz',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #003592; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsColour',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #cd5a13; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsLusciousLong',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #ad1015; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsMiracleMoist',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #0072b1; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsMega',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #96004b; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'h1#collectionsVolume',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 36px; color: #006579; leading: -26; }',
	],
	wmode: 'transparent',
	tuneHeight: -21,
	offsetTop: -9,
	offsetLeft: 0
});

sIFR.replace(amwayOptiBold, {
  selector: 'div#scrollPane h1',
  css: [
		'.sIFR-root { text-transform: uppercase; font-size: 39px; color: #ad1015; }',
	],
	wmode: 'transparent',
	tuneHeight: -15,
	offsetTop: -9,
	offsetLeft: 4
});

// homepage callout 0.
sIFR.replace(helveticaNeueLtStd, {
  selector: 'div#callout0 a',
  css: [
		'.sIFR-root { font-size: 21px; font-weight: bold; color: #ffffff; leading: -7; cursor: pointer; }',
		'.homeCallout { font-size: 13px; font-weight: normal; leading: -12; letter-spacing: 0.5; }',
		'.break { leading: 15; }'
	],
	wmode: 'transparent',
	tuneHeight: -10,
	offsetTop: -6
});

// homepage callout 1.
sIFR.replace(helveticaNeueLtStd, {
	selector: 'div#callout1 a',
	css: [
		'.sIFR-root { font-size: 21px; font-weight: bold; color: #ffffff; leading: -7; cursor: pointer; }',
		'.homeCallout { font-size: 13px; font-weight: normal; leading: -9; letter-spacing: 0.5; }',
		'.homeCallout2 { font-size: 13px; font-weight: normal; leading: -3; letter-spacing: 0.5; }',
		'.homeCalloutLge { font-size: 28px; leading: -7; }',
		'.break { leading: -4; }'
	],
	wmode: 'transparent',
	tuneHeight: -15,
	offsetTop: -8
});

// Your Hair Must-Haves header.
sIFR.replace(amwayOptiBold, {
	selector: 'h1#hdrYourHairMustHaves',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 19px; color: #970bb3; }'
	],
	wmode: 'transparent',
	tuneHeight: -14,
	offsetTop: -4
});

// Your Hair Must-Haves Product headers
sIFR.replace(amwayOptiBold, {
	selector: 'h3.myHdr',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 14px; color: #666666; leading: -8; background-color: #00ff00; }',
		'.txtBtm { font-size: 11px; }'
	],
	wmode: 'transparent',
	tuneHeight: -9,
	offsetTop: -4
});

sIFR.replace(amwayOptiBold, {
	selector: 'h3.myHdr2',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 14px; color: #666666; leading: -8; background-color: #00ff00; }',
		'.txtTop { font-size: 12px; leading: -5; }',
		'.txtBtm { font-size: 11px; }'
	],
	wmode: 'transparent',
	tuneHeight: -9,
	offsetTop: -5
});

sIFR.replace(amwayOptiBold, {
	selector: 'h3.myHdr3',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 13px; color: #666666; leading: -6; background-color: #00ff00; }',
		'.txtBtm { font-size: 11px; }'
	],
	wmode: 'transparent',
	tuneHeight: -7,
	offsetTop: -3
});

// Share It header.
sIFR.replace(amwayOptiBold, {
	selector: 'div#calloutsProducts h2#hdrShareIt',
	css: [
		'.sIFR-root { text-transform: uppercase; font-size: 19px; color: #970bb3; }'
	],
	wmode: 'transparent',
	tuneHeight: -14,
	offsetTop: -4
});