﻿jQuery(document).ready(function() {

    //RadMenu Expanded class css fix
    jQuery(".slide").hover(
      function() {
          var LinkClass = jQuery(this).parent().find("a.expanded").attr("class").toString();
          if (LinkClass == "link OurNurseries expanded") {
              jQuery(this).parent().children("a.link").addClass("OurNurseriesOn");
          }
          else if (LinkClass == "link BeingAtFootprints expanded") {
              jQuery(this).parent().children("a.link").addClass("BeingAtFootprintsOn");
          }
      },
      function() {

      }
    );


    //Request a Vist image css amend  
    jQuery(".imageRAV1").css("text-align", "center");
    jQuery(".imageRAV1").css("background-color", "#B3D75E");

    //Privacy Policy min-height css
    jQuery(".twocolumns").css("min-height", "580px");
    if (/MSIE (\d+\.\d+);/.test(navigator.userAgent)) {
        jQuery(".twocolumns").css("height", "580px !important");
    }

    //Sitemap css
    //Border lines
    jQuery("#sitemap ul li:nth-child(1)").css("border-top", "2px solid #f37324");
    jQuery("#sitemap ul li:nth-child(2)").css("border-top", "2px solid #ec008c");
    jQuery("#sitemap ul li:nth-child(3)").css("border-top", "2px solid #f37324");
    jQuery("#sitemap ul li:nth-child(4)").css("border-top", "2px solid #ec008c");
    jQuery("#sitemap ul li:nth-child(5)").css("border-top", "2px solid #f37324");
    jQuery("#sitemap ul li:nth-child(6)").css("border-top", "2px solid #ec008c");
    jQuery("#sitemap ul li:nth-child(7)").css("border-top", "2px solid #f37324");
    jQuery("#sitemap ul li:nth-child(8)").css("border-top", "2px solid #ec008c");
    jQuery("#sitemap ul li:nth-child(8)").css("border-bottom", "2px solid #f37324");
    jQuery("#sitemap ul li ul li").css("border", "0");

    //Star bullets
    jQuery("#sitemap ul li:nth-child(1)").css("background", "url(/images/SmapOrange.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(2)").css("background", "url(/images/SmapBlue.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(3)").css("background", "url(/images/SmapTurquoise.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(4)").css("background", "url(/images/SmapGreen.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(5)").css("background", "url(/images/SmapPurple.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(6)").css("background", "url(/images/SmapPink.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(7)").css("background", "url(/images/SmapLightGreen.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li:nth-child(8)").css("background", "url(/images/SmapOrange.gif) no-repeat 0 5px");
    jQuery("#sitemap ul li ul li").css("background", "none");

    //Privacy Policy links
    var Page = window.location.pathname;
    if (Page == "/privacy-policy.aspx") {
        jQuery(".twocolumns a").attr("id", "PPLink");
    }

    //IE News Page bg fix
        
    if ((jQuery(".imageNewsItem").html() != null) && (jQuery(".imageNewsItem").html().toString() == "")) {
        jQuery(".imageNewsItem").hide(0);
    }

});

