﻿/*****************************************************************************
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.
*****************************************************************************/

// Specifically Don’t Replace Certain Text

parseSelector.pseudoClasses = {
  'not': function(nodes, selector) {
    var result = [];
    each: for(var i = 0, node; i < nodes.length; i++) {
      node = nodes[i];
      var ignore = parseSelector(selector, node.parentNode);
      for(var j = 0; j < ignore.length; j++) {
        if(ignore[j] == node) continue each;
      }
      result.push(node);
    }
    return result;
  }
}

var georgia = { src: '/assets/flash/georgia.swf' };

sIFR.useStyleCheck = true;
// sIFR.useDomLoaded = false;

sIFR.activate(georgia);


// styling Headers

sIFR.replace(georgia, {
    selector: '.overview-block h1, .overview-block h2'
    , forceWidth: 'true'
    , wmode: 'transparent'
    , css: [
        '.sIFR-root { color: #ffffff; font-size: 15px; letter-spacing: 0.3; font-weight: normal; text-align: left; leading: -2;}'
    ]
});

sIFR.replace(georgia, {
    selector: 'h1, .h1, .page h2'
    ,forceWidth: 'true'
    ,wmode: 'transparent'
    ,css: [
        '.sIFR-root { color: #ffffff; font-size: 26px; text-align: left; leading: -2;}; strong{font-weight:normal; font-size:20px;}'
        ,'a { text-decoration: none }'
        ,'a:link { color: #ffffff }'
        ,'a:hover { color: #ffffff }'
    ]
});

sIFR.replace(georgia, {
selector: '.secondary-content h2, .secondary-content h3, .page h3, .page .h4, .secondary-content .sign-up h4'
    , forceWidth: 'true'
    , wmode: 'transparent'
    , css: [
        '.sIFR-root { color: #ffffff; font-size: 16px; font-weight: normal; text-align: left; leading: -2;}'
        , 'strong { font-weight: normal; }'
    ]
});


sIFR.replace(georgia, {
    selector: '.homelarge .block-title h3, .homenews h3, .homesmalltop .sign-up h4'
    , forceWidth: 'true'
    , wmode: 'transparent'
    , css: [
        '.sIFR-root { color: #ffffff; font-size: 20px; font-weight: normal; text-align: left; leading: -2;}'
    ]
});



