<?php

/**
 * Branding
 * @category Functions
 * @author Krik
 */

// Custom login style
add_action('login_head', 'krik_login_style');

// Custom admin style
add_action('admin_head', 'krik_admin_style');

// Custom admin logo link
add_filter('login_headerurl', 'krik_login_url');

// Custom admin logo title
add_filter('login_headertitle', 'krik_login_title');

// Custom footer text
add_filter('admin_footer_text', 'krik_admin_footer');

function krik_login_style()
{
	echo '<style type="text/css">
		h1 a {
			background-image: url(' . get_template_directory_uri() . '/static/images/krik.svg) !important;
			background-size: contain !important;
			width: 140px !important;
			height: 25px !important;
			margin: 40px auto !important;
		}
	</style>';
}

function krik_admin_style()
{
	echo '<style>
		.plugin-update-tr { display: none !important; }
		#wpml_als_help_link { display: none; }
		.icl_als_iclflag { display: none; }
	</style>';
}

function krik_login_url()
{
	return 'http://krikstudio.com';
}

function krik_login_title()
{
	return 'Krikstudio';
}

function krik_admin_footer()
{
	return '<a href="http://krikstudio.com" target="_blank" style="text-decoration: none; color: #555d66;">Krikstudio</a> <span class="dashicons dashicons-heart"></span> <a href="http://wordpress.org" target="_blank" style="text-decoration: none; color: #555d66;">WordPress</a>';
}
