<?php

//////////////////==========================
// Global Settings
Kirki::add_section( 'chained_global_settings', array(
    'panel'    => 'chained_theme_settings',
    'title'    => __( 'Global', 'chained' ),
    'priority' => 30,
) );
Kirki::add_field( 'theme_settings', [
    'type'     => 'custom',
    'settings' => 'custom_title_woocommerce_general',
    'section'  => 'chained_woocommerce',
    'default'  => '<div style="padding: 6px;text-transform: uppercase;letter-spacing: 1px;font-weight: bold;text-align: center;background-color: #f04e39; color: #fff;">' . esc_html__( 'Global Options', 'chained' ) . '</div>',
    'priority' => 10,
] );
Kirki::add_field( 'theme_settings', [
    'type'        => 'color',
    'settings'    => 'chained_global_accent_color',
    'label'       => esc_html__( 'Accent Color', 'chained' ),
    'description' => esc_html__( 'This is accent color control used for some design elements and hovers', 'chained' ),
    'section'     => 'chained_global_settings',
    'default'     => '#f04e39',
    'output'      => array(
    array(
    'element'  => '
				.masonry .wrapper .masonry-panel__content .post-design-default.entry-card.format-gallery:hover .entry-gallery-navigation button,
				.masonry .wrapper .masonry-panel__content .post-design-papyrus.entry-card:after,
				blockquote cite:before,
				.single-content .single-content-wrapper .single-content-inner .post .entry-header .entry-meta .category-links a,
				.widget-area .widget h4.widget-title:before,
				button:not(.reset):not(.slick-prev):not(.slick-next):hover, .single-content .single-content-wrapper .single-content-inner .comment-respond .comment-form p.form-submit .submit:hover, .single-content .single-content-wrapper .single-content-inner .comments-area .comments-area-title .comments_add-comment:hover,
				.single-content .single-content-wrapper .single-content-inner .post .entry-footer .tags-links > a, .site-header .main-navigation .nav--main li a:before, 
				.masonry .wrapper .masonry-panel__content article .category-links a, button:not(.reset):hover,.masonry #infinite-handle span button:hover, #sb_instagram #sbi_load .sbi_load_btn:hover, #sb_instagram #sbi_load .sbi_load_btn:focus,#sb_instagram #sbi_load .sbi_follow_btn a:hover, #sb_instagram #sbi_load .sbi_follow_btn a:focus,
				.single-content .single-content-wrapper .single-content-inner .post .content-with-socials .sharedaddy .sd-social .sd-title:before, .single-content .single-content-wrapper .single-content-inner .attachment .content-with-socials .sharedaddy .sd-social .sd-title:before, .single-content .single-content-wrapper .single-content-inner .author-info .author-info-inner .author-description .author-name:before,.single-content .single-content-wrapper .single-content-inner .comments-area .comments-area-title h3:before,
				.single-content .single-content-wrapper .single-content-inner .related-posts h3:before,
				.masonry .wrapper .masonry-panel__content article.sticky .sticky-post,
				.masonry .wrapper .masonry-panel__content article.format-quote .category-links a,
				::selection,
				.widget-area .widget.widget_search form button.search-offcanvas,
				input[type=submit]:hover, .site-header .social-navigation .woocommerce-cart-icon .cart-contents-count sup, .home .homepage-hero .featured-1 article .category-links a, .mosaic article .entry-content-inner .title-header .category-links span a, .grid article .category-links a, .site-footer .back-to-top, .woocommerce-product-search button, .edit-link, .woocommerce-cart .cart-wrapper .cart-collaterals .wc-proceed-to-checkout a.button, .woocommerce-checkout .checkout .woocommerce-checkout-review-order #payment .place-order .button, .woocommerce-checkout .woocommerce-form-coupon .form-row-last .button, .widget.woocommerce.widget_price_filter form .price_slider_wrapper .ui-slider .ui-slider-handle, .widget.woocommerce.widget_price_filter form .price_slider_wrapper .ui-slider .ui-slider-range, 
					.woocommerce .onsale, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-default .entry-content-inner .button, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-default .entry-content-inner .added_to_cart, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-card .entry-content-inner .button, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-card .entry-content-inner .added_to_cart, .image-and-content-wrapper .woocommerce-product-gallery .woocommerce-product-gallery__trigger, .woocommerce-notices-wrapper .woocommerce-message .button, .image-and-content-wrapper .summary .cart button, .related .chained-related-products .product .entry-content-inner .button, .related .chained-related-products .product .entry-content-inner .added_to_cart, .widget.woocommerce.widget_top_rated_products ul li:hover a .product-title, .widget.woocommerce.widget_recent_reviews ul li:hover a .product-title, .widget.woocommerce.widget_recently_viewed_products ul li:hover a .product-title, .home .homepage-hero .featured-1 .bg-background-selected, .home .homepage-hero .sticky-post, .shortcode-title span, .woocommerce-show-off-slider .woo-slider-item .woo-slider-item-content a.button
				',
    'property' => 'background-color',
),
    array(
    'element'  => '
				.masonry .wrapper .masonry-panel__content article .entry-content-inner .entry-header .entry-title a:hover, .widget-area .widget a:hover, .single-content .single-content-wrapper .single-content-inner .post .entry-content a:not(.wp-block-button__link):not(.wp-block-file__button), .single-content .single-content-wrapper .single-content-inner .attachment .entry-content a:not(.wp-block-button__link):not(.wp-block-file__button), .site-footer .nav--footer li a:hover,.site-footer .site-info a:hover, .masonry .wrapper .masonry-panel__content .post-design-card.entry-card .entry-content-inner .entry-header .entry-title a:hover, .site-footer .footer-widgets .widget-area .widget a:hover, .widget-area .widget.widget_chained_recentpost_widget .widget-post .post-wrap:hover .title a, .site-footer .footer-menu .nav--footer li a:hover, .woocommerce-cart .cart-wrapper .woocommerce-cart-form table td.actions .button.wc-backward:hover, .woocommerce-checkout .woocommerce-form-coupon-toggle a, .woocommerce-account .woocommerce-MyAccount-content a, .widget.woocommerce.widget_price_filter form .price_slider_wrapper .price_slider_amount .button, .accent, a:hover, a:focus, .masonry .infinite-loader .spinner, .image-and-content-wrapper .summary .stock.out-of-stock',
    'property' => 'color',
),
    array(
    'element'  => '
				.single-content .single-content-wrapper .single-content-inner .post .content-with-socials .sharedaddy .sd-social .sd-content ul li:hover a, .single-content .single-content-wrapper .single-content-inner .attachment .content-with-socials .sharedaddy .sd-social .sd-content ul li:hover a ',
    'property' => 'color',
    'suffix'   => '!important',
),
    array(
    'element'  => '
				.masonry .wrapper .masonry-panel__content .entry-card:not(.post-design-magazine) .entry-meta a.accent-color',
    'property' => 'background',
    'suffix'   => '!important',
),
    array(
    'element'  => '.woocommerce-checkout .woocommerce-form-coupon, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-card .entry-content-inner .button:hover, .woocommerce .products-masonry .product .masonry-panel__content article.post-design-card .entry-content-inner .added_to_cart:hover, .woocommerce-show-off-slider .woo-slider-item .woo-slider-item-content a.button:hover',
    'property' => 'border-color',
),
    array(
    'element'  => '.masonry .pagination .nav-links .current, .woocommerce-pagination ul.page-numbers li .current, .shortcode-title',
    'property' => 'border-bottom-color',
),
    array(
    'element'  => '.wp-block-quote',
    'property' => 'border-left-color',
),
    array(
    'element'  => 'a:hover, .masonry .infinite-loader .spinner,
			.single-content .single-content-wrapper .single-content-inner .comments-area .commentlist .comment .comment-article .media__body .comment-author .comment__links a,
			.single-content .single-content-wrapper .single-content-inner .comment-respond .comment-reply-title small #cancel-comment-reply-link,.masonry .wrapper .masonry-panel__content article .entry-meta .meta-information span a:hover',
    'property' => 'color',
),
    array(
    'element'  => '.site-header .social-navigation .nav--social .menu-item a:hover svg, .masonry .wrapper .masonry-panel__content article.sticky .sticky-post svg,.masonry .wrapper .masonry-panel__content article.format-quote .content-quote .content-quote-wrapper .quote svg, .single-content .single-content-wrapper .single-content-inner .related-posts .related-posts-intro .entry-related-navigation button:hover svg, .single-content .single-content-wrapper .single-content-inner .related-posts .related-posts-intro .entry-related-navigation .comments-area .comments-area-title .comments_add-comment:hover svg, .single-content .single-content-wrapper .single-content-inner .comments-area .comments-area-title .related-posts .related-posts-intro .entry-related-navigation .comments_add-comment:hover svg, .single-content .single-content-wrapper .single-content-inner .related-posts .related-posts-intro .entry-related-navigation .comment-respond .comment-form p.form-submit .submit:hover svg, .single-content .single-content-wrapper .single-content-inner .comment-respond .comment-form p.form-submit .related-posts .related-posts-intro .entry-related-navigation .submit:hover svg',
    'property' => 'fill',
)
),
] );
Kirki::add_field( 'theme_settings', [
    'type'        => 'toggle',
    'settings'    => 'changed_global_enable_breadcrumb',
    'label'       => esc_html__( 'Enable Breadcrumb', 'chained' ),
    'description' => esc_html__( 'This will be shown in single post and page', 'chained' ),
    'section'     => 'chained_global_settings',
    'default'     => '1',
    'priority'    => 10,
] );
Kirki::add_field( 'theme_settings', [
    'type'            => 'typography',
    'settings'        => 'chained_single_breadcrumb_typography',
    'label'           => esc_html__( 'Breadcrumb Appearance', 'chained' ),
    'section'         => 'chained_global_settings',
    'default'         => [
    'font-family'    => 'Roboto Condensed',
    'variant'        => 'normal',
    'font-size'      => '14px',
    'letter-spacing' => '0',
    'color'          => '#121212',
    'text-transform' => 'none',
],
    'priority'        => 10,
    'transport'       => 'auto',
    'output'          => [ [
    'element' => '.breadcrumbs .trail-items .trail-item',
] ],
    'active_callback' => [ [
    'setting'  => 'changed_global_enable_breadcrumb',
    'operator' => '==',
    'value'    => true,
] ],
] );