array( 'color' => get_theme_mod( 'amy_text_color', '#2c3e50' ), ), '.site-content h1, .site-content h2, .site-content h3, .site-content h4, .site-content h5, .site-content h6, .footer-sidebar h1, .footer-sidebar h2, .footer-sidebar h3, .footer-sidebar h4, .footer-sidebar h5, .footer-sidebar h6, .comments-area .comment-author a, .comments-area .comment-author' => array( 'color' => get_theme_mod( 'amy_headings_color', '#2c3e50' ), ), '.site-title a, .site-title a:hover' => array( 'color' => get_theme_mod( 'amy_site_title_color', '#2c3e50' ), ), '.site-content a, .footer-sidebar a, body.post-type-archive-portfolio .content-area .entry-title a:hover, .comments-area a.comment-reply-link:hover' => array( 'color' => get_theme_mod( 'amy_link_color', '#1e73be' ), ), '.more-link a:hover, .entry-footer .tags-links a:hover' => array( 'border-color' => get_theme_mod( 'amy_link_color', '#1e73be' ), ), 'button, input[type="button"], input[type="reset"], input[type="submit"], .button' => array( 'background-color' => get_theme_mod( 'amy_link_color', '#1e73be' ), ), '.site-content a:hover, .footer-sidebar a:hover' => array( 'color' => get_theme_mod( 'amy_link_hover_color', '#2c3e50' ), ), '.nav-menu a' => array( 'color' => get_theme_mod( 'amy_menu_color', '#999999' ), ), '.nav-menu > li:hover a, .nav-menu a:hover, .nav-menu .current-menu-item > a' => array( 'color' => get_theme_mod( 'amy_menu_color_hover', '#1e73be' ), ), ); $theme_css = ''; foreach ( $custom_css as $property => $css ) { $theme_css .= $property . '{'; foreach ( $css as $key => $value ) { $theme_css .= $key . ':' . $value . ';'; } $theme_css .= '}'; } // Minify a bit $theme_css = str_replace( "\t", '', $theme_css ); $theme_css = str_replace( array( "\n", "\r" ), ' ', $theme_css ); // Add inline style wp_add_inline_style( 'amy-style', $theme_css ); } add_action( 'wp_enqueue_scripts', 'amy_custom_styles' );