<?php

add_action( 'admin_menu', 'startup_solutions_gettingstarted' );
function startup_solutions_gettingstarted() {
	add_theme_page( esc_html__('About Theme', 'startup-solutions'), esc_html__('Theme Demo Import', 'startup-solutions'), 'edit_theme_options', 'startup-solutions-guide-page', 'startup_solutions_guide');
}

function startup_solutions_admin_theme_style() {
   wp_enqueue_style('startup-solutions-custom-admin-style', esc_url(get_template_directory_uri()) . '/inc/dashboard/get_started_info.css');
   wp_enqueue_script('startup-solutions-tab', esc_url( get_template_directory_uri() ) . '/inc/dashboard/js/get_started_tab.js');

   	// Admin notice code START
	wp_register_script('startup-solutions-notice', esc_url(get_template_directory_uri()) . '/inc/dashboard/js/notice.js', array('jquery'), time(), true);
	wp_enqueue_script('startup-solutions-notice');
	// Admin notice code END
}
add_action('admin_enqueue_scripts', 'startup_solutions_admin_theme_style');

// Notice after Theme Activation
function startup_solutions_activation_notice() {
    global $pagenow;
    if ( is_admin() && $pagenow === 'themes.php' && (!isset($_GET['page']) || $_GET['page'] !== 'startup-solutions-guide-page')
) {
    $meta = get_option( 'startup_solutions_admin_notice' );
    if ( ! $meta ) { ?>
        <div id="startup-solutions-welcome-notice" class="notice notice-success is-dismissible getting_started activation-notice	">
            <div class="notice-info">
                <div class="notice-image">
                    <img style="width: 100%;max-width: 320px;line-height: 40px;display: inline-block;vertical-align: top;" src="<?php echo esc_url( get_stylesheet_directory_uri() . '/screenshot.png' ); ?>" />
                </div>
                <div class="notice-content">
                    <h2><?php esc_html_e( 'Thanks For Installing Startup Solutions, You Rock!', 'startup-solutions' ); ?></h2>
                    <p><?php esc_html_e( 'Take benefit of a variety of features, functionalities, elements, and an exclusive set of customization options to build your own professional store website. Please click the link below for theme setup details.', 'startup-solutions' ); ?></p>
                    <div style="display: grid;">
                        <a class="button notice-btn" href="<?php echo esc_url( admin_url( 'themes.php?page=startup-solutions-guide-page' ) ); ?>">
                            <?php esc_html_e( 'Getting Started', 'startup-solutions' ); ?>
                        </a>
                        <a class="button notice-btn" target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_LIVE_DEMO ); ?>">
                            <?php esc_html_e('Pro Demo', 'startup-solutions'); ?>
                        </a>
                        <a class="button notice-btn" target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_FREE_DOC ); ?>">
                            <?php esc_html_e('Free Doc', 'startup-solutions'); ?>
                        </a>
                        <a class="button notice-btn" target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_BUY_PRO ); ?>">
                            <?php esc_html_e('Upgrade To Pro', 'startup-solutions'); ?>
                        </a>
                    </div>
                </div>
            </div>
        </div>

    <?php }
}
}
add_action( 'admin_notices', 'startup_solutions_activation_notice' );

// Admin notice code START
function startup_solutions_dismissed_notice() {
	update_option( 'startup_solutions_admin_notice', true );
}
add_action( 'wp_ajax_startup_solutions_dismissed_notice', 'startup_solutions_dismissed_notice' );

//After Switch theme function
add_action('after_switch_theme', 'startup_solutions_getstart_setup_options');
function startup_solutions_getstart_setup_options () {
    update_option('startup_solutions_admin_notice', false );
}
// Admin notice code END

/**
 * Theme Info Page
 */
function startup_solutions_guide() {

	// Theme info
	$startup_solutions_return = add_query_arg( array()) ;
	$startup_solutions_theme = wp_get_theme( 'startup-solutions' ); ?>

	<div class="wrap getting-started">
		<div class="getting-started__header">
		    <div>
                <h2 class="tgmpa-notice-warning"></h2>
            </div>
		</div>
		<div class="tab-sec">
			<div class="tab">
				<button role="tab" class="tablinks home" onclick="startup_solutions_openCity(event, 'bwp_getstart')"><?php esc_html_e( 'Theme Demo Import', 'startup-solutions' ); ?></button>
				<button role="tab" class="tablinks" onclick="startup_solutions_openCity(event, 'bwp_setup')"><?php esc_html_e( 'Free Theme Information', 'startup-solutions' ); ?></button>
				<button role="tab" class="tablinks" onclick="startup_solutions_openCity(event, 'bwp_premium_info')"><?php esc_html_e( 'Premium Theme Information', 'startup-solutions' ); ?></button>
				<a class="tablinks tablinks-demo" role="tab" href="<?php echo esc_url( STARTUP_SOLUTIONS_LIVE_DEMO ); ?>" target="_blank">
					<?php esc_html_e( 'Live Demo', 'startup-solutions' ); ?>
				</a>
				<a class="tablinks tablinks-pro" role="tab" href="<?php echo esc_url( STARTUP_SOLUTIONS_BUY_PRO ); ?>" target="_blank">
					<?php esc_html_e( 'Buy Pro', 'startup-solutions' ); ?>
				</a>
			</div>
			<div  id="bwp_getstart" class="tabcontent">
				<div class="row">
					<div class="col-md-5 intro">
						<div class="pad-box">
							<h2><?php esc_html_e( 'Welcome to Startup Solutions ', 'startup-solutions' ); ?>
							<span><?php esc_html_e( 'Version: ', 'startup-solutions' ); ?><?php echo esc_html($startup_solutions_theme['Version']);?></span>
							</h2>
							<span class="intro__version"><?php esc_html_e( 'Congratulations! You are about to use the most easy to use and flexible WordPress theme.', 'startup-solutions' ); ?>
							</span>
							<div class="powered-by">
								<p><strong><?php esc_html_e( 'Theme created by Buy WP Templates', 'startup-solutions' ); ?></strong></p>
								<p>
									<img class="logo" src="<?php echo esc_url(get_template_directory_uri() . '/inc/dashboard/media/theme-logo.png'); ?>"/>
								</p>
								<div class="demo-content">
									<?php
										/* Demo Import */
										require get_parent_theme_file_path( '/inc/dashboard/demo-content.php' );
									?>
								</div>

								<div id="demo-import-loader">
									<img src="<?php echo esc_url(get_template_directory_uri() . '/inc/dashboard/media/spinner.gif'); ?>" alt="<?php echo esc_attr( 'Loading...', 'startup-solutions'); ?>" />
								</div>
							</div>
						</div>
					</div>
					<div class="col-md-7">
						<div class="install-plugins">
							<img src="<?php echo esc_url(get_template_directory_uri() . '/inc/dashboard/media/responsive1.png'); ?>" alt="<?php echo esc_attr( 'responsive-image', 'startup-solutions'); ?>" />
						</div>
					</div>
				</div>
				<div class="dashboard__blocks">
					<div class="row">
						<div class="col-md-3">
							<h3><?php esc_html_e( 'Get Support','startup-solutions'); ?></h3>
							<ol>
								<li><a target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_FREE_SUPPORT ); ?>"><?php esc_html_e( 'Free Theme Support','startup-solutions'); ?></a></li>
								<li><a target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_PRO_SUPPORT ); ?>"><?php esc_html_e( 'Premium Theme Support','startup-solutions'); ?></a></li>
							</ol>
						</div>
						<div class="col-md-3">
							<h3><?php esc_html_e( 'Getting Started','startup-solutions'); ?></h3>
							<ol>
								<li><?php esc_html_e( 'Start','startup-solutions'); ?> <a target="_blank" href="<?php echo esc_url( admin_url('customize.php') ); ?>"><?php esc_html_e( 'Customizing','startup-solutions'); ?></a> <?php esc_html_e( 'your website.','startup-solutions'); ?> </li>
							</ol>
						</div>
						<div class="col-md-3">
							<h3><?php esc_html_e( 'Help Docs','startup-solutions'); ?></h3>
							<ol>
								<li><a target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_FREE_DOC ); ?>"><?php esc_html_e( 'Free Theme Documentation','startup-solutions'); ?></a></li>
								<li><a target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_PRO_DOC ); ?>"><?php esc_html_e( 'Premium Theme Documentation','startup-solutions'); ?></a></li>
							</ol>
						</div>
						<div class="col-md-3">
							<h3><?php esc_html_e( 'Buy Premium','startup-solutions'); ?></h3>
							<ol>
								<a href="<?php echo esc_url( STARTUP_SOLUTIONS_BUY_PRO ); ?>" target="_blank"><?php esc_html_e('Buy Pro', 'startup-solutions'); ?></a>
							</ol>
						</div>
					</div>
				</div>
			</div>
			<div  id="bwp_setup" class="tabcontent">
				<h2 class="tg-docs-section intruction-title" id="section-4"><?php esc_html_e( '1) Setup Startup Solutions Theme', 'startup-solutions' ); ?></h2>
				<div class="row">
					<div class="theme-instruction-block col-md-7">
						<div class="pad-box">
							<p><?php esc_html_e( 'Startup Solutions is a dynamic and adaptable website template designed to cater to the diverse needs of startups across multiple industries. With its sleek and modern design, it reflects the innovative spirit of entrepreneurship and offers a user-friendly layout for showcasing services, ideas, and products. Perfect for business growth, innovation, venture capital, tech startups, SaaS platforms, digital marketing agencies, product launches, scalable solutions, software development companies, business planning, investment readiness, creative portfolios, and market strategies, this template ensures startups have a strong digital foundation. Its fully responsive design guarantees seamless viewing across desktops, tablets, and mobile devices, ensuring accessibility for all users. Key features include customizable layouts, flexible color schemes, and typography options, enabling businesses to reflect their unique brand identity. Built with Contact Form 7 integration, social media feeds, SEO tools, and e-commerce functionality, it provides powerful resources for customer engagement, lead generation, and online sales management. The template also includes sections for team introductions, case studies, portfolio showcases, client testimonials, success stories, and service highlights, enabling startups to effectively communicate their value proposition. With strategically placed call-to-action elements to boost conversion optimization and user interaction, this template is ideal for industries ranging from technology and finance to creative agencies and digital solutions. Whether it’s for funding pitches, business networking, branding campaigns, landing pages, or building a professional online presence, Startup Solutions delivers an intuitive, polished, and visually appealing platform for growth.', 'startup-solutions' ); ?><p><br>
							<ol>
								<li><?php esc_html_e( 'Start','startup-solutions'); ?> <a target="_blank" href="<?php echo esc_url( admin_url('customize.php') ); ?>"><?php esc_html_e( 'Customizing','startup-solutions'); ?></a> <?php esc_html_e( 'your website.','startup-solutions'); ?> </l>
								<li><?php esc_html_e( 'Startup Solutions','startup-solutions'); ?> <a target="_blank" href="<?php echo esc_url( STARTUP_SOLUTIONS_FREE_DOC ); ?>"><?php esc_html_e( 'Documentation','startup-solutions'); ?></a> </li>
							</ol>
						</div>
					</div>
					<div class="col-md-5">
						<div class="pad-box">
								<img class="logo" src="<?php echo esc_url(get_template_directory_uri() . '/inc/dashboard/media/screenshot.png'); ?>"/>
						</div>
					</div>	
				</div>
			</div>
			<div class="col-md-12 text-block tabcontent"  id="bwp_premium_info">
				<h2 class="dashboard-install-title"><?php esc_html_e( '2) Premium Theme Information.','startup-solutions'); ?></h2>
				<div class="row">
					<div class="col-md-7">
						<img src="<?php echo esc_url(get_template_directory_uri() . '/inc/dashboard/media/responsive.png'); ?>" alt="<?php echo esc_attr( 'responsive-image', 'startup-solutions'); ?>">
						<div class="pad-box">
							<h3><?php esc_html_e( 'Pro Theme Description','startup-solutions'); ?></h3>
							<p class="pad-box-p"><?php esc_html_e( 'Startup Solutions is a dynamic and adaptable WordPress theme designed to cater to the diverse needs of startups across various industries. Boasting a modern and sleek design, the theme presents a contemporary aesthetic that aligns with the innovative spirit of emerging ventures. Central to its appeal is the user-friendly layout, providing an intuitive experience for visitors exploring the startup online presence. Whether accessed on desktops, tablets, or mobile devices, the theme ensures responsiveness, guaranteeing a seamless viewing experience across different screen sizes. Customization lies at the heart of this theme, offering startups the flexibility to personalize aspects such as color schemes and typography, allowing for a unique representation of their brand identity. This adaptability extends to the theme integration with popular plugins, facilitating the incorporation ofessential functionalities like contact forms, social media feeds, and even e-commerce features for startup engaged in online sales. Dedicated sections within the theme provide spaces for startups to highlight their services, introduce team members, and share success stories. Integrated call-to-action elements further enhance user engagement, encouraging visitors to take desired actions that contribute to the startup growth. As startups embark on their journeys, this theme provides a solid foundation for creating a professional and compelling digital presence.', 'startup-solutions' ); ?><p>
						</div>
					</div>
					<div class="col-md-5 install-plugin-right">
						<div class="pad-box">
							<h3><?php esc_html_e( 'Pro Theme Features','startup-solutions'); ?></h3>
							<div class="dashboard-install-benefit">
								<ul>
									<li><?php esc_html_e( 'Theme options using Customizer API','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Responsive design','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Site Icon and Logo option','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Header Images option','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Favicon, Logo, title, and tagline customization','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Advanced Color options and color pallets','startup-solutions'); ?></li>
									<li><?php esc_html_e( '100+ Font Family Options','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Pagination option','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Demo Importer','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Enable-Disable options on All sections','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Main Slider','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Woocommerce Compatible','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Unlimited Slides','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Section to show categories','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Product Listing based on category','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Top Categories Section','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Best Seller Tab','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Testimonial with custom post type','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Promotional Banners','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Partner Listing','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Shortcodes for Testimonials','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Newsletter with the help of contact form 7.','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Well-sanitized as per WordPress standards.','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Responsive layout for all devices','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Typography for the complete website','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Global Color pallete','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Section specific Color pallete','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Fully integrated with Font Awesome Icon','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Instagram Section','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Partner Listing','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Background Image Option','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Custom page templates','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Allow setting site title, tagline, logo','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Left and Right Sidebar','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Sticky post & Comment threads','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Customizable Home Page','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Multiple inner page templates','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Contact Page Template','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Blog Full width and right and left sidebar','startup-solutions'); ?></li>
									<li><?php esc_html_e( 'Recent post widget with images, Related post','startup-solutions'); ?></li>
								</ul>
							</div>
						</div>
					</div>
				</div>
			</div>
		</div>
	</div>

<?php }?>
