Index: wp-content/themes/twentyfourteen/functions.php
===================================================================
--- wp-content/themes/twentyfourteen/functions.php	(revision 25831)
+++ wp-content/themes/twentyfourteen/functions.php	(working copy)
@@ -239,7 +239,7 @@
 	if ( is_active_sidebar( 'sidebar-3' ) )
 		wp_enqueue_script( 'jquery-masonry' );
 
-	wp_enqueue_script( 'twentyfourteen-theme', get_template_directory_uri() . '/js/theme.js', array( 'jquery' ), '20130820', true );
+	wp_enqueue_script( 'twentyfourteen-script', get_template_directory_uri() . '/js/functions.js', array( 'jquery' ), '20131011', true );
 
 	// Add Lato font used in the main stylesheet.
 	wp_enqueue_style( 'twentyfourteen-lato', twentyfourteen_font_url(), array(), null );
@@ -374,6 +374,11 @@
 	if ( is_multi_author() )
 		$classes[] = 'group-blog';
 
+	if ( get_header_image() )
+		$classes[] = 'header-image';
+	else
+		$classes[] = 'masthead-fixed';
+
 	if ( is_archive() || is_search() || is_home() )
 		$classes[] = 'list-view';
 
Index: wp-content/themes/twentyfourteen/rtl.css
===================================================================
--- wp-content/themes/twentyfourteen/rtl.css	(revision 25831)
+++ wp-content/themes/twentyfourteen/rtl.css	(working copy)
@@ -59,22 +59,17 @@
 /* =Header
 ----------------------------------------------- */
 
-.header-main {
-	margin-left: 48px;
-	padding-right: 10px;
-	padding-left: 0;
-	margin-right: auto;
-}
-
 .header-extra {
 	float: left;
+	margin-left: 38px;
+	margin-right: auto;
 }
 
 .site-title {
 	float: right;
 }
 
-#nav-toggle {
+.menu-toggle {
 	left: 0;
 	right: auto;
 }
@@ -93,18 +88,17 @@
 ----------------------------------------------- */
 
 /* Primary Navigation */
-.primary-navigation {
-	float: left;
-	margin: 0 -10px 0 10px;
-}
-
 .primary-navigation ul {
 	padding-right: 0;
 	padding-left: 0;
 }
 
+.primary-navigation ul ul li {
+	margin-left: auto;
+	margin-right: 15px;
+}
+
 .primary-navigation ul ul {
-	float: right;
 	right: -999em;
 	left: auto;
 }
@@ -495,8 +489,11 @@
 
 @media screen and (min-width: 770px) {
 	.header-main {
+		padding: 0 27px 0 0;
+	}
+
+	.header-extra {
 		margin-left: 0;
-		margin-right: auto;
 	}
 }
 
Index: wp-content/themes/twentyfourteen/inc/customizer.php
===================================================================
--- wp-content/themes/twentyfourteen/inc/customizer.php	(revision 25831)
+++ wp-content/themes/twentyfourteen/inc/customizer.php	(working copy)
@@ -143,13 +143,18 @@
 		.hentry .mejs-controls .mejs-time-rail .mejs-time-current,
 		.header-extra,
 		.search-toggle,
-		.primary-navigation ul ul,
-		.primary-navigation li:hover > a,
 		.page-links a:hover,
 		.widget_calendar tbody a {
 			background-color: ' . $accent_color . ';
 		}
 
+		@media screen and (min-width: 770px) {
+			.primary-navigation ul ul,
+			.primary-navigation li:hover > a {
+				background-color: ' . $accent_color . ';
+			}
+		}
+
 		::-moz-selection {
 			background: ' . $accent_color . ';
 		}
Index: wp-content/themes/twentyfourteen/header.php
===================================================================
--- wp-content/themes/twentyfourteen/header.php	(revision 25831)
+++ wp-content/themes/twentyfourteen/header.php	(working copy)
@@ -45,15 +45,13 @@
 				</div>
 			</div>
 
-			<nav role="navigation" class="site-navigation primary-navigation">
-				<h1 class="screen-reader-text"><?php _e( 'Primary Menu', 'twentyfourteen' ); ?></h1>
-				<a class="screen-reader-text skip-link" href="#content"><?php _e( 'Skip to content', 'twentyfourteen' ); ?></a></a>
-				<?php wp_nav_menu( array( 'theme_location' => 'primary' ) ); ?>
+			<nav id="primary-navigation" class="site-navigation primary-navigation" role="navigation">
+				<h1 class="menu-toggle"><?php _e( 'Primary Menu', 'twentyfourteen' ); ?></h1>
+				<a class="screen-reader-text skip-link" href="#content"><?php _e( 'Skip to content', 'twentyfourteen' ); ?></a>
+				<?php wp_nav_menu( array( 'theme_location' => 'primary', 'menu_class' => 'nav-menu' ) ); ?>
 			</nav>
 		</div>
 
-		<div id="mobile-navigations" class="hide"></div>
-
 		<div id="search-container" class="search-box-wrapper hide">
 			<div class="search-box clear">
 				<?php get_search_form(); ?>
Index: wp-content/themes/twentyfourteen/style.css
===================================================================
--- wp-content/themes/twentyfourteen/style.css	(revision 25831)
+++ wp-content/themes/twentyfourteen/style.css	(working copy)
@@ -724,6 +724,7 @@
 
 /* Genericons */
 
+.menu-toggle:before,
 .comment-edit-link:before,
 .comment-reply-link:before,
 .comment-reply-login:before,
@@ -785,14 +786,14 @@
 }
 
 .header-main {
-	margin-right: 48px;
 	min-height: 48px;
-	padding-left: 10px;
+	padding: 0 10px;
 }
 
 .header-extra {
 	background-color: #24890d;
 	float: right;
+	margin-right: 38px;
 }
 
 .site-title {
@@ -869,22 +870,6 @@
 	width: 326px;
 }
 
-/* Fixed Header */
-
-.site-header.masthead-fixed {
-	box-shadow: 0 1px 8px rgba(0, 0, 0, 0.2);
-	position: fixed;
-	top: 0;
-}
-
-.admin-bar .site-header.masthead-fixed {
-	top: 28px;
-}
-
-.admin-bar.mp6 .site-header.masthead-fixed {
-	top: 32px;
-}
-
 
 /**
  * 5.0 Navigations
@@ -908,78 +893,53 @@
 /* Primary Navigation */
 
 .primary-navigation {
-	display: none;
-	float: right;
-	font-size: 11px;
-	line-height: 1.6363636363;
-	margin: 0 10px 0 -10px;
-}
-
-.primary-navigation ul {
-	margin: 0;
-	padding-left: 0;
-}
-
-.primary-navigation li {
+	background-color: #000;
 	-webkit-box-sizing: border-box;
 	-moz-box-sizing:    border-box;
 	box-sizing:         border-box;
-	display: inline-block;
-	height: 48px;
-	line-height: 48px;
-	position: relative;
+	font-size: 14px;
+	font-weight: 700;
+	margin: 1px auto 0;
+	padding: 24px 10px 0;
 }
 
-.primary-navigation a {
-	display: inline-block;
-	padding: 0 10px;
-	text-decoration: none;
-	white-space: nowrap;
+.primary-navigation.toggled-on {
+	padding-top: 72px;
 }
-
-.primary-navigation ul ul {
-	background-color: #24890d;
-	float: left;
-	position: absolute;
-	top: 48px;
-	left: -999em;
-	z-index: 99999;
+.primary-navigation .nav-menu {
+	display: none;
 }
-
-.primary-navigation li li {
+.primary-navigation.toggled-on .nav-menu {
 	display: block;
-	height: auto;
-	line-height: 1.6363636363;
 }
 
-.primary-navigation ul ul ul {
-	left: -999em;
-	top: 0;
+.primary-navigation ul {
+	list-style: none;
+	margin: 0;
+	padding-left: 0;
 }
 
-.primary-navigation ul ul a {
-	padding: 9px 12px;
-	white-space: normal;
-	width: 148px;
+.primary-navigation li {
+	border-top: 1px solid rgba(255, 255, 255, 0.4);
 }
 
-.primary-navigation li:hover > a {
-	background-color: #24890d;
-	color: #fff;
+.primary-navigation li li {
+	border-top: 1px solid rgba(255, 255, 255, 0.2);
 }
 
-.primary-navigation ul ul a:hover {
-	background-color: #000;
+.primary-navigation ul ul li {
+	margin-left: 15px;
 }
 
-.primary-navigation ul li:hover > ul,
-.primary-navigation ul li.focus > ul {
-	left: auto;
+.primary-navigation a {
+	color: #fff;
+	display: block;
+	padding: 7px 0 7px;
+	text-decoration: none;
 }
 
-.primary-navigation ul ul li:hover > ul,
-.primary-navigation ul ul li.focus > ul {
-	left: 100%;
+.primary-navigation a:hover { 
+	color: rgba(255, 255, 255, 0.7);
 }
 
 /* Secondary Navigation */
@@ -1016,59 +976,19 @@
 	border-top: 1px solid rgba(255, 255, 255, 0.2);
 }
 
-/* Mobile Navigations */
-
-#mobile-navigations {
-	margin: 1px auto 0;
-	max-width: 474px;
-}
-
-.mobile-navigation {
-	background-color: #000;
-	-webkit-box-sizing: border-box;
-	-moz-box-sizing:    border-box;
-	box-sizing:         border-box;
-	font-size: 14px;
-	padding: 24px 10px 0;
-}
-
-.mobile-navigation ul {
-	margin: 0;
-}
-
-.mobile-navigation li {
-	border-top: 1px solid rgba(255, 255, 255, 0.4);
-}
-
-.mobile-navigation li li {
-	border-top: 1px solid rgba(255, 255, 255, 0.2);
-}
-
-.mobile-navigation ul ul li {
-	margin-left: 15px;
-}
-
-.mobile-navigation a {
-	display: block;
-	padding: 7px 0;
-	text-decoration: none;
-}
-
-.mobile-navigation a:hover {
-	color: rgba(255, 255, 255, 0.7);
-}
-
-#nav-toggle {
+.menu-toggle {
 	background-color: #000;
 	cursor: pointer;
-	line-height: 1;
+	font-size: 0;
+	height: 16px;
+	margin: 0;
 	padding: 16px;
 	position: absolute;
 	top: 0;
 	right: 0;
 }
 
-#nav-toggle:before {
+.menu-toggle:before {
 	color: #fff;
 	content: "\f419";
 }
@@ -1111,7 +1031,6 @@
 	background: #767676;
 	background-attachment: fixed;
 	background-image: -webkit-linear-gradient(135deg, #767676 12.5%, #fff 12.5%, #fff 50%, #767676 50%, #767676 62.5%, #fff 62.5%);
-	background-image:         linear-gradient(135deg, #767676 12.5%, #fff 12.5%, #fff 50%, #767676 50%, #767676 62.5%, #fff 62.5%);
 	background-size: 4px 4px;
 	display: none;
 	float: none;
@@ -1127,7 +1046,6 @@
 	background: #919191;
 	background-attachment: fixed;
 	background-image: -webkit-linear-gradient(135deg, #919191 12.5%, #fff 12.5%, #fff 50%, #919191 50%, #919191 62.5%, #fff 62.5%);
-	background-image:         linear-gradient(135deg, #919191 12.5%, #fff 12.5%, #fff 50%, #919191 50%, #919191 62.5%, #fff 62.5%);
 	background-size: 4px 4px;
 }
 
@@ -2919,11 +2837,125 @@
 
 @media screen and (min-width: 770px) {
 	.header-main {
+		padding: 0 0 0 27px;
+	}
+
+	.header-extra {
 		margin-right: 0;
 	}
 
+	/* Fixed Header */
+
+	.masthead-fixed .site-header {
+		box-shadow: 0 1px 8px rgba(0, 0, 0, 0.2);
+		position: fixed;
+		top: 0;
+	}
+
+	.admin-bar.masthead-fixed .site-header {
+		top: 28px;
+	}
+
+	.admin-bar.mp6.masthead-fixed .site-header {
+		top: 32px;
+	}
+
+	.masthead-fixed .site-main {
+		margin-top: 48px;
+	}
+
 	.primary-navigation {
+		float: right;
+		font-size: 11px;
+		line-height: 1.6363636363;
+		margin: 0 10px 0 -10px;
+		padding: 0;
+		text-transform: uppercase;
+	}
+
+	.primary-navigation .menu-toggle {
+		display: none;
+		padding: 0;
+	}
+
+	.primary-navigation .nav-menu {
+		display: block;
+	}
+
+	.primary-navigation.toggled-on {
+		padding: 0;
+	}
+
+	.primary-navigation li {
+		border: 0;
+		-webkit-box-sizing: border-box;
+		-moz-box-sizing:    border-box;
+		box-sizing:         border-box;
+		display: inline-block;
+		height: 48px;
+		line-height: 48px;
+		position: relative;
+	}
+
+	.primary-navigation a {
+		display: inline-block;
+		padding: 0 10px;
+		white-space: nowrap;
+	}
+
+	.primary-navigation ul ul {
+		background-color: #24890d;
+		float: left;
+		position: absolute;
+		top: 48px;
+		left: -999em;
+		z-index: 99999;
+	}
+
+	.primary-navigation li li {
+		border: 0;
 		display: block;
+		height: auto;
+		line-height: 1.6363636363;
+	}
+
+	.primary-navigation ul ul ul {
+		left: -999em;
+		top: 0;
+	}
+
+	.primary-navigation ul ul li {
+		margin: 0;
+	}
+
+	.primary-navigation ul ul a {
+		padding: 9px 12px;
+		white-space: normal;
+		width: 148px;
+	}
+
+	.primary-navigation li:hover > a {
+		background-color: #24890d;
+		color: #fff;
+	}
+
+	.primary-navigation ul ul a:hover {
+		background-color: #000;
+	}
+
+	.primary-navigation ul li:hover > ul,
+	.primary-navigation ul li.focus > ul {
+		left: auto;
+	}
+
+	.primary-navigation ul ul li:hover > ul,
+	.primary-navigation ul ul li.focus > ul {
+		left: 100%;
+	}
+
+	.primary-navigation .current_page_item > a, 
+	.primary-navigation .current-menu-item > a { 
+		color: #5ff23d;
 	}
 }
 
@@ -3035,10 +3067,6 @@
 }
 
 @media screen and (min-width: 1008px) {
-	.header-main {
-		padding-left: 27px;
-	}
-
 	.search-box-wrapper {
 		padding-left: 182px;
 	}
Index: wp-content/themes/twentyfourteen/js/functions.js
===================================================================
--- wp-content/themes/twentyfourteen/js/functions.js	(revision 0)
+++ wp-content/themes/twentyfourteen/js/functions.js	(revision 0)
@@ -0,0 +1,98 @@
+( function( $ ) {
+	var body    = $( 'body' ),
+	    _window = $( window );
+
+	/**
+	 * Enables menu toggle for small screens.
+	 */
+	( function() {
+		var nav = $( '#primary-navigation' ), button, menu;
+		if ( ! nav )
+			return;
+
+		button = nav.find( '.menu-toggle' );
+		if ( ! button )
+			return;
+
+		// Hide button if menu is missing or empty.
+		menu = nav.find( '.nav-menu' );
+		if ( ! menu || ! menu.children().length ) {
+			button.hide();
+			return;
+		}
+ 
+		$( '.menu-toggle' ).on( 'click.twentyfourteen', function() {
+			nav.toggleClass( 'toggled-on' );
+		} );
+	} )();
+ 
+	/**
+	 * Makes "skip to content" link work correctly in IE9 and Chrome for better
+	 * accessibility.
+	 *
+	 * @link http://www.nczonline.net/blog/2013/01/15/fixing-skip-to-content-links/
+	 */
+	_window.on( 'hashchange.twentyfourteen', function() {
+		var element = document.getElementById( location.hash.substring( 1 ) );
+
+		if ( element ) {
+			if ( ! /^(?:a|select|input|button|textarea)$/i.test( element.tagName ) )
+				element.tabIndex = -1;
+
+			element.focus();
+		};
+	} );
+
+	$( function() {
+		/**
+ 		* Search toggle.
+		*/
+		$( '.search-toggle' ).on( 'click.twentyfourteen', function() {
+			var that    = $( this ),
+			    wrapper = $( '.search-box-wrapper' );
+
+			that.toggleClass( 'active' );
+			wrapper.toggleClass( 'hide' );
+
+			if ( that.is( '.active' ) )
+				wrapper.find( '.search-field' ).focus();
+		} );
+
+		/**
+		 * Fixed navbar.
+		 * 
+		 * The callback on the scroll event is only added if there is a header
+		 * image and we are not on mobile.
+		 */
+		if ( body.is( '.header-image' ) && _window.width() > 769 ) {
+			var toolbarOffset  = body.is( '.admin-bar' ) ? $( '#wpadminbar' ).height() : 0,
+			    mastheadOffset = $( '#masthead' ).offset().top - toolbarOffset;
+
+			_window.on( 'scroll.twentyfourteen', function() {
+				if ( window.scrollY > mastheadOffset )
+					body.addClass( 'masthead-fixed' );
+				else
+					body.removeClass( 'masthead-fixed' );
+			} );
+		}
+
+		/**
+		 * Focus styles for primary menu.
+		 */
+		$( '.primary-navigation' ).find( 'a' ).on( 'focus.twentyfourteen blur.twentyfourteen', function() {
+			$( this ).parents().toggleClass( 'focus' );
+		} );
+	} );
+
+	/** 
+	 * Arranges footer widgets vertically.
+	 */
+	if ( $.isFunction( $.fn.masonry ) ) {
+		$( '#footer-sidebar' ).masonry( {
+			itemSelector: '.widget',
+			columnWidth: 315,
+			gutterWidth: 0,
+			isRTL: $( 'body' ).is( '.rtl' )
+		} );
+	}
+} )( jQuery );

Property changes on: wp-content/themes/twentyfourteen/js/functions.js
___________________________________________________________________
Added: svn:mime-type
   + text/plain
Added: svn:eol-style
   + native

Index: wp-content/themes/twentyfourteen/js/theme.js
===================================================================
--- wp-content/themes/twentyfourteen/js/theme.js	(revision 25831)
+++ wp-content/themes/twentyfourteen/js/theme.js	(working copy)
@@ -1,124 +0,0 @@
-( function( $ ) {
-
-	$( document ).ready( function() {
-
-		var $primaryNaviClone,
-			$secondaryNaviClone,
-			$masthead = $( '#masthead' ),
-			$secondaryTop = $( '#secondary-top' ),
-			$mobileNavigations = $( '#mobile-navigations'),
-			$searchBoxWrapper = $( 'div.search-box-wrapper' ),
-			$searchToggle = $( 'div.search-toggle' ),
-			timeout = false;
-
-		// Toggle function.
-		function menuToggle() {
-			$( 'span#nav-toggle' ).toggleClass( 'active' );
-			$masthead.find( '#mobile-navigations' ).toggleClass( 'hide' );
-		}
-
-		// Click event for toggle the search
-		$searchToggle.click( function() {
-			$( this ).toggleClass( 'active' );
-			$searchBoxWrapper.toggleClass( 'hide' );
-
-			if ( $( this ).hasClass( 'active' ) )
-				$searchBoxWrapper.find( '.search-field' ).focus();
-		} );
-
-		// DOM manipulations for mobile header
-		function mobileHeader()	{
-			// Check if the toggler exists. If not add it.
-			if ( ! $( '#nav-toggle' ).length )
-			$( '<span id="nav-toggle" class="genericon" />' ).appendTo( $masthead );
-
-			// Clone and detach the primary navigation for use later
-			$primaryNaviClone = $masthead.find( 'nav.primary-navigation' ).detach();
-
-			// Clone and detach the secondary navigation for use later
-			$secondaryNaviClone = $secondaryTop.find( 'nav.secondary-navigation' ).detach();
-
-			// Prepend the primary navigation clone to #mobile-navigations and remove the class and add an id
-			$primaryNaviClone.prependTo( $mobileNavigations ).removeClass( 'primary-navigation' ).addClass( 'mobile-navigation' ).attr( 'id', 'primary-mobile-navigation' );
-
-			// Append the secondary navigation clone to #mobile-navigations and remove the class and add an id
-			$secondaryNaviClone.appendTo( $mobileNavigations ).removeClass( 'secondary-navigation' ).addClass( 'mobile-navigation' ).attr( 'id', 'secondary-mobile-navigation' );
-
-			// Remove the click event first and bind it after to make sure it's invoked once.
-			$( 'span#nav-toggle' ).off( 'click', menuToggle ).click( menuToggle );
-		};
-
-		// DOM manupilations for desktop header
-		function normalHeader()	{
-			// Check if the toggler exists. If it does remove it.
-			if ( $( 'span#nav-toggle').length )
-			$( 'span#nav-toggle' ).remove();
-
-			// Clone and detach the primary mobile navigation for use later
-			$primaryNaviClone = $mobileNavigations.find( '#primary-mobile-navigation' ).detach();
-
-			// Clone and detach the secondary mobile navigation for use later
-			$secondaryNaviClone = $mobileNavigations.find( '#secondary-mobile-navigation' ).detach();
-
-			// Append the secondary navigation clone to #mobile-navigations and remove the class and add an id
-			$primaryNaviClone.appendTo( '.header-main' ).removeClass( 'mobile-navigation' ).removeAttr( 'id' ).addClass( 'primary-navigation' );
-
-			// Append the secondary navigation clone to #mobile-navigations and remove the class and add an id
-			$secondaryNaviClone.appendTo( $secondaryTop ).removeClass( 'mobile-navigation' ).removeAttr( 'id' ).addClass( 'secondary-navigation' );
-		};
-
-		// Check viewport width when user resizes the browser window.
-		$( window ).resize( function() {
-			if ( false !== timeout )
-				clearTimeout( timeout );
-
-			timeout = setTimeout( function() {
-				if ( $( window ).width() < 770 ) {
-					mobileHeader();
-				} else {
-					normalHeader();
-				}
-			}, 100 );
-
-		} ).resize();
-
-		// Sticky header.
-		var $mastheadOffset  = -1,
-			$toolbarOffset = $( 'body' ).is( '.admin-bar' ) ? 32 : 0,
-			$maindiv = $( '#main' );
-
-		$( window ).on( 'scroll', false, function() {
-			if ( $mastheadOffset < 0 )
-				$mastheadOffset = $masthead.offset().top - $toolbarOffset;
-
-			if ( ( window.scrollY > $mastheadOffset ) && ( $( window ).width() > 769 ) ) {
-				$masthead.addClass( 'masthead-fixed' );
-				$maindiv.css( {
-					marginTop: $masthead.height()
-				} );
-			} else {
-				$masthead.removeClass( 'masthead-fixed' );
-				$maindiv.css( {
-					marginTop: 0
-				} );
-			}
-		} );
-
-		// Arranges footer widgets vertically.
-		if ( $.isFunction( $.fn.masonry ) ) {
-
-			$( '#footer-sidebar' ).masonry( {
-				itemSelector: '.widget',
-				columnWidth: 315,
-				gutterWidth: 0,
-				isRTL: $( 'body' ).is( '.rtl' )
-			} );
-		}
-
-	} );
-
-	/* Focus styles for primary menu. */
-	$( '.primary-navigation' ).find( 'a' ).on( 'focus.twentyfourteen blur.twentyfourteen', function() {
-		$( this ).parents().toggleClass( 'focus' );
-	});
-} )( jQuery );
\ No newline at end of file
