Cufon.replace('#menu li a', { hover: true });
Cufon.replace('#login a');
Cufon.replace('h1');
Cufon.replace('.h1');
Cufon.replace('#content h3');
Cufon.replace('#sidebar h3');

var user = "váš e-mail";
var password = "heslo";

$(document).ready(function() {
  Cufon.replace($('h2:not(.nocufon)'));

  $(".inputwrapper").mouseover(function() {
    if(!$(this).find("select, input").hasClass("focused")) {
      $(this).find("label").css({ "backgroundPosition" : "0 -28px", "backgroundColor" : "#1f82bd", "color" : "#ffffff" });
    }
  }).mouseout(function() {
    if(!$(this).find("select, input").hasClass("focused")) {
      $(this).find("label").attr("style","");
    }
  });
  $(".inputwrapper select, .inputwrapper input").focus(function() {
    $(this).parent().parent().find("label").css({ "backgroundPosition" : "0 -28px", "backgroundColor" : "#1f82bd", "color" : "#ffffff" });
    $(this).addClass('focused');
  }).blur(function() {
    $(this).parent().parent().find("label").attr("style","");
    $(this).removeClass('focused');
  });
  
  $("#login a.prihlaseni").click(function() {
    if($("#loginbox").is(":hidden")) {
      $("#loginbox").slideDown(400);
    } else {
      $("#loginbox").slideUp(400);
    }
  });
  
  $("input#user").focus(function () {
    if($(this).val()==user) { $(this).val(''); }
  }).blur(function () {
    if($(this).val()=="") { $(this).val(user); }
  });
  $("input#pass").focus(function () {
    if($(this).val()==password) { $(this).val(''); }
  }).blur(function () {
    if($(this).val()=="") { $(this).val(password); }
  });
  
  $("#prohlidky .box-velky div").not(":first-child").hide();
  $("#prohlidky ul.seznam a").click(function() {
      $("#prohlidky ul.seznam li").removeClass("active");
      $(this).parent().addClass("active");
      var selected = $('#prohlidky ul.seznam li').index($('.active'));
      $("#prohlidky .box-velky div").hide();
      $("#prohlidky .box-velky div").eq(selected).fadeIn(400);
  });
  
  $('#prohlidky .box a').hover(function () {
    $(this).find("strong").fadeOut(400);
  },function () {
    $(this).find("strong").fadeIn(400);
  });

  
});