/*  
===============================================================================
WResize is the jQuery plugin for fixing the IE window resize bug
...............................................................................
                                               Copyright 2007 / Andrea Ercolino
-------------------------------------------------------------------------------
LICENSE: http://www.opensource.org/licenses/mit-license.php
WEBSITE: http://noteslog.com/
===============================================================================
*/
( function( $ ) 
{
	$.fn.wresize = function( f ) 
	{
		version = '1.1';
		wresize = {fired: false, width: 0};
		function resizeOnce() 
		{
			if ( $.browser.msie )
			{
				if ( ! wresize.fired )
				{
					wresize.fired = true;
				}
				else 
				{
					var version = parseInt( $.browser.version, 10 );
					wresize.fired = false;
					if ( version < 7 )
					{
						return false;
					}
					else if ( version == 7 )
					{
						//a vertical resize is fired once, an horizontal resize twice
						var width = $( window ).width();
						if ( width != wresize.width )
						{
							wresize.width = width;
							return false;
						}
					}
				}
			}
			return true;
		}

		function handleWResize( e ) 
		{
			if ( resizeOnce() )
			{
				return f.apply(this, [e]);
			}
		}

		this.each( function() 
		{
			if ( this == window )
			{
				$( this ).resize( handleWResize );
			}
			else
			{
				$( this ).resize( f );
			}
		} );

		return this;
	};

} ) ( jQuery );
/*  for plati.ru only */
jQuery( function( $ ) 
{
	function content_resize() 
	{
		var w = $( window ); var H = w.height(); var W = w.width();		
		var dim0=810; var dim1=1052; var dim2=1261; var dim3 = 1350;		
		if (W<dim0) {
			$( '#sz1' ).css("display", "none");$( '#sz2' ).css("display", "none");$( '#sz3' ).css("display", "none");$( '#sz4' ).css("display", "none");			
			return;
		}
		if (W<dim1) {
			$( '#sz2' ).css("display", "none");$( '#sz3' ).css("display", "none");$( '#sz4' ).css("display", "none");			
		}
		else {
			$( '#sz2' ).css("display", "");
			if (W<dim2) {
				$( '#sz3' ).css("display", "none");$( '#sz4' ).css("display", "none");
			}
			else {			
				$( '#sz3' ).css("display", ""); 
				if (W<dim3) $( '#sz4' ).css("display", "none");	else $( '#sz4' ).css("display", "");					
			}
		}
		$( '#sz1' ).css("display", "");
	}
	$( window ).wresize( content_resize );
	content_resize();
} );
