<!doctype html>
<html lang="en">
<head>
	<?php
		$languages = App::make('LanguageController')->all();
	?>
	<meta charset="UTF-8">
	<meta http-equiv="X-UA-Compatible" content="IE=edge">
	<meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" />
	<?php echo $__env->yieldContent('meta-content'); ?>
	<meta name="rootURL" content="<?php echo URL::to('/'); ?>">
	<meta name="_token" content="<?php echo csrf_token(); ?>">
	<meta name="auth_download" content="<?php echo $settings->auth_download; ?>">
	<meta name="is_login" content="<?php if(Auth::guest()): ?> 0 <?php else: ?> 1 <?php endif; ?>">
	<meta name="vk_auth" content="<?php echo $settings->vk_auth; ?>">

	<link rel="stylesheet" href="<?php echo URL::asset('assets/css/bootstrap.css'); ?>" />
	<link rel="stylesheet" href="<?php echo URL::asset('assets/css/font-awesome.css'); ?>" />
	<link rel="stylesheet" href="<?php echo URL::asset('assets/css/bar-ui.css'); ?>" />
    <link rel="stylesheet" href="<?php echo URL::asset('assets/css/style.css?v=2'); ?>" />

    <link rel="icon" href="<?php echo URL::asset('assets/images/favicon.ico'); ?>" type="image/x-icon">
    <link rel="shortcut icon" href="<?php echo URL::asset('assets/images/favicon.ico'); ?>" type="image/x-icon">

    <script type="text/javascript" src="<?php echo URL::asset('assets/js/jquery-1.11.0.min.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/bootstrap.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/jscroll.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/jquery.form.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/jquery.pjax.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/typeahead.bundle.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/nprogress.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/jquery.noty.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/soundmanager2.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/bar-ui.js'); ?>"></script>
    <script type="text/javascript" src="<?php echo URL::asset('assets/js/app.js?v=2'); ?>"></script>
    <script type="text/javascript">
      $(document).ready(function(){
        rootURL = "<?php echo URL::to('/'); ?>";
      });
    </script>
    <style type="text/css">
    	.side-nav>li.active>a, .navbar-inverse .navbar-nav > li > a:hover, .navbar-inverse .navbar-nav > li > a:focus {
		    border-left-color: <?php echo $settings->theme_color; ?>;
		}
		.fav-link.active {
		  border-bottom: 3px solid <?php echo $settings->theme_color; ?>;
		}
		.create-playlist, .create-playlist:hover, .create-playlist:focus, .album-like.active, .track-like.active {
		    color: <?php echo $settings->theme_color; ?>;
		}
		.navbar-inverse .navbar-toggle .icon-bar, #nprogress .bar, .more-gl.dropdown-menu > li > a:hover {
		    background-color: <?php echo $settings->theme_color; ?>;
		}
		#nprogress .peg {
		  box-shadow: 0 0 10px <?php echo $settings->theme_color; ?>, 0 0 5px<?php echo $settings->theme_color; ?>;
		}
		#nprogress .spinner-icon {
		  border-top-color: <?php echo $settings->theme_color; ?>;
		  border-left-color: <?php echo $settings->theme_color; ?>;
		}
		.pager>li>span, .pager>.active>span, .pager>li>a:hover, .pager>.active>span:hover, .pager>li>span:hover, .pager>.disabled>span, .pager>.disabled>span:hover, .pager>li>a, .profile-header {
            background-color: <?php echo $settings->theme_color; ?>;
        }
        .pager>li>span:hover, .pager>.disabled>span, .pager>.disabled>span:hover, .genre-list > li:last-child .fa{
            color:<?php echo $settings->theme_color; ?>;
        }
        .pager>li>a, .pager > .disabled > span{
            border:1px solid <?php echo $settings->theme_color; ?>;
        }
    </style>
</head>
<body>
<div id="fb-root"></div>
<nav class="navbar navbar-inverse navbar-fixed-top" role="navigation">
	<button data-direction="left" data-target="#slidemenu" class="navbar-toggle" type="button">
        <span class="sr-only">Toggle navigation</span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
        <span class="icon-bar"></span>
	</button>
	<div class="col-sm-9">
		<div class="sm2-bar-ui full-width pull-left">
	        <div class="bd sm2-main-controls">
	        	<div class="sm2-inline-element">
	                <a class="navbar-brand logo hidden-xs pjax" title="<?php echo $settings->website_name; ?>" href="<?php echo URL::to('/'); ?>"><img alt="<?php echo $settings->website_name; ?>" src="<?php echo URL::asset('assets/images/logo.png'); ?>"/></a>
	            </div>
	        	<div class="sm2-inline-element sm2-button-element">
	                <div class="sm2-button-bd">
	                	<a class="sm2-inline-button previous" title="Previous" href="#prev">&lt; previous</a>
	                </div>
	            </div>

	            <div class="sm2-inline-element sm2-button-element">
	                <div class="sm2-button-bd">
	                    <a id="play-pause" class="sm2-inline-button play-pause" href="#play">Play / pause</a>
	                </div>
	            </div>

	            <div class="sm2-inline-element sm2-button-element">
	                <div class="sm2-button-bd">
	                    <a id="play-next" class="sm2-inline-button next" title="Next" href="#next">&gt; next</a>
	                </div>
	            </div>

	            <div class="sm2-inline-element sm2-inline-status">
	                
	                <div class="sm2-progress">
	                    <div class="sm2-row">
	                        <div class="sm2-inline-time">0:00</div>
	                        <div class="sm2-progress-bd">
	                            <div class="sm2-progress-track">
	                            <div class="sm2-progress-bar"></div>
	                                <div class="sm2-progress-ball">
	                                    <div class="icon-overlay"></div>
	                                </div>
	                            </div>
	                        </div>
	                        <div class="sm2-inline-duration">0:00</div>
	                    </div>
	                </div>

	            </div>

	            <div class="sm2-inline-element sm2-button-element sm2-volume">
	                <div class="sm2-button-bd">
	                    <span class="sm2-inline-button sm2-volume-control volume-shade"></span>
	                    <a class="sm2-inline-button sm2-volume-control" href="#volume">volume</a>
	                </div>
	            </div>

	            <div class="sm2-inline-element sm2-button-element sm2-menu">
	                <div class="sm2-button-bd">
	                    <a class="sm2-inline-button menu" href="#menu">menu</a>
	                </div>
	            </div>
	           
	        </div>
	        
	        <div class="bd sm2-playlist-drawer sm2-element" style="height: 0px;">

	            <div class="sm2-inline-texture">
	                <div class="sm2-box-shadow"></div>
	            </div>

	            <!-- playlist content is mirrored here -->
	            <div class="sm2-playlist-wrapper">            
	                <ul class="sm2-playlist-bd">
	                    <li></li>
	                </ul>
	            </div>

	        </div>
	    </div>
	</div>
	<div class="col-sm-3 hidden-xs">
    <form class="navbar-form padding0" role="search" method="get" action="<?php echo URL::to('/'); ?>">
			        <div class="form-group form-addon">
			        	<span class="fa fa-search"></span>
			        	<input type="text" name="q" class="form-control typeahead6 form-addon" placeholder="<?php echo Lang::get('words.search'); ?>">
			        </div>
			    </form>
	</div>
</nav>
<div id="wrapper" class="hidden">
	<nav class="navbar-inverse">
		<ul class="nav navbar-nav side-nav" id="slidemenu">
	        <li <?php if(Request::is('/')): ?> class="active" <?php endif; ?>>
	            <a class="pjax" href="<?php echo URL::to('/'); ?>"><i class="fa fa-2x fa-home"></i> <?php echo Lang::get('words.home'); ?></a>
	        </li>
	        <li <?php if(Request::is('user/playlist')): ?> class="active" <?php endif; ?>>
	            <a <?php if(Auth::guest()): ?> data-target="#signup" data-toggle="modal" <?php else: ?> class="pjax" <?php endif; ?> href="<?php echo URL::to('user/playlist'); ?>"><i class="fa fa-2x fa-music"></i> <?php echo Lang::get('words.playlist'); ?></a>
	        </li>
	        <?php if(!Auth::guest()): ?>
	        	<li <?php if(Request::is('settings')): ?> class="active" <?php endif; ?>>
		            <a class="pjax" href="<?php echo URL::to('user/settings'); ?>"><i class="fa fa-2x fa-gear"></i> <?php echo Lang::get('words.settings'); ?></a>
		        </li>
		        <li>
		            <a class="pjax" href="<?php echo URL::to('user/logout'); ?>"><i class="fa fa-2x fa-power-off"></i> <?php echo Lang::get('words.logout'); ?></a>
		        </li>
		        <?php if(Auth::user()->admin): ?>
			        <li>
			            <a href="<?php echo URL::to('user/admin'); ?>"><i class="fa fa-2x fa-dashboard"></i> <?php echo Lang::get('words.admin'); ?></a>
			        </li>
	        	<?php endif; ?>
	        <?php else: ?>
		        <li>
		            <a data-toggle="modal" data-target="#signup" href="#signup"><i class="fa fa-2x fa-sign-in"></i> <?php echo Lang::get('words.login'); ?></a>
		        </li>
	        <?php endif; ?>
	    </ul>
	    <div class="ad-nav hidden-xs">
	    	<div style="margin:7px auto; width:300px;">
	    		<?php echo $__env->yieldContent('youtube'); ?>
	    		<br />
	    		<?php echo htmlspecialchars_decode($settings->box_ad); ?>

	    	</div>
	    </div>
	</nav>
	<div id="page-wrapper">
		<div class="container-fluid">
			<div class="col-xs-12">
				<form class="navbar-form visible-xs" role="search" method="get" action="<?php echo URL::to('/'); ?>">
			        <div class="form-group form-addon">
			        	<span class="fa fa-search"></span>
			        	<input type="text" name="q" class="form-control form-addon" placeholder="<?php echo Lang::get('words.search'); ?>">
			        </div>
			    </form>
			    <ul class="genre-list">
				<?php foreach($genres as $i => $genre): ?>
					<?php if($i == 0): ?>
			        	<li class="li-show"><a href="<?php echo URL::to($genre->name); ?>" class="pjax <?php if(Request::is('/') || Request::is($genre->name)): ?> active <?php endif; ?>"><?php echo $genre->name; ?></a></li>
			        <?php else: ?>
			        	<li class="li-show"><a href="<?php echo URL::to($genre->name); ?>" class="pjax <?php if(Request::is($genre->name)): ?> active <?php endif; ?>"><?php echo $genre->name; ?></a></li>
			        <?php endif; ?>
			    <?php endforeach; ?>
			        <li class="dropdown" role="presentation">
			            <a class="dropdown-toggle" data-toggle="dropdown" role="button" href=""><?php echo Lang::get('words.more'); ?> <span class="fa fa-caret-down"></span></a>
			            <ul id="more-gl" class="dropdown-menu more-gl" role="menu"></ul>
			        </li>
			        <li class="dropdown" role="presentation">
			            <a class="dropdown-toggle" data-toggle="dropdown" role="button" href=""><span class="fa fa-globe"></span></a>
			            <ul class="dropdown-menu more-gl" role="menu">
			            	<?php foreach($languages as $language => $nativeName): ?>
								<li><a title="<?php echo $nativeName; ?>" href="<?php echo URL::to('/language/'.$language); ?>"><img alt="<?php echo $nativeName; ?>" src="<?php echo URL::asset('assets/flags/'.$language.'.png'); ?>"> <?php echo $nativeName; ?></a></li>
							<?php endforeach; ?>
			            </ul>
			        </li>
			    </ul>
				<?php echo $__env->yieldContent('content'); ?>
				<div class="clearfix"></div>
				<div class="row" id="footer-category">
					<div class="col-sm-9 text-center">
						<div id="footer-links">
							<a class="pjax" title="<?php echo Lang::get('words.terms'); ?>" href="<?php echo URL::to('page/terms'); ?>"><?php echo Lang::get('words.terms'); ?></a>
							<a class="pjax" title="<?php echo Lang::get('words.privacy'); ?>" href="<?php echo URL::to('page/privacy'); ?>"><?php echo Lang::get('words.privacy'); ?></a>
							<a class="pjax" title="<?php echo Lang::get('words.faq'); ?>" href="<?php echo URL::to('page/faq'); ?>"><?php echo Lang::get('words.faq'); ?></a>
						</div>
						<h6 class="text-muted">
							&copy; <?php echo $settings->website_name; ?> <?php echo date('Y'); ?> , <?php echo Lang::get('words.all-rights-reserved'); ?>

						</h6>
					</div>
					<div class="col-sm-3">
						<div class="ft-social">
							<span><?php echo Lang::get('words.follow-us'); ?>:</span>
							<a class="btn btn-circle bg-facebook" title="" href="https://facebook.com/<?php echo $settings->fb_page_id; ?>"><span class="fa fa-facebook"></span></a>
							<a class="btn btn-circle bg-twitter" title="" href="https://twitter.com/<?php echo $settings->twitter_page_id; ?>"><span class="fa fa-twitter"></span></a>
							<a class="btn btn-circle bg-google" title="" href="https://plus.google.com/<?php echo $settings->google_page_id; ?>"><span class="fa fa-google-plus"></span></a>
						</div>
					</div>
					<div class="clearfix"></div>
				</div>
			</div>
		</div>
	</div>
</div>

<?php echo $__env->make('modals.modal-form', array_except(get_defined_vars(), array('__data', '__path')))->render(); ?>
<script type="text/javascript">
 	<?php if(Session::get('message') != '' && Session::get('status') != ''): ?>
        var n = noty({
                text        : '<?php echo Session::get("message"); ?>',
                type        : '<?php echo Session::get("status"); ?>',
                dismissQueue: true,
                layout      : 'bottomRight',
                closeWith   : ['click'],
                theme       : 'relax',
                maxVisible  : 10
            });
        <?php Session::forget('status'); Session::forget('message'); ?>
    <?php endif; ?>
</script>
<?php if(isset($settings->analytics)): ?>
  	<?php echo htmlspecialchars_decode($settings->analytics); ?>

<?php endif; ?>
</body>
</html>