diff --git a/wp-content/themes/cosmopet/archive-blog_author.php b/wp-content/themes/cosmopet/archive-blog_author.php new file mode 100644 index 0000000..bfd7e5e --- /dev/null +++ b/wp-content/themes/cosmopet/archive-blog_author.php @@ -0,0 +1,6 @@ + \ No newline at end of file diff --git a/wp-content/themes/cosmopet/comments.php b/wp-content/themes/cosmopet/comments.php new file mode 100644 index 0000000..386d6c1 --- /dev/null +++ b/wp-content/themes/cosmopet/comments.php @@ -0,0 +1,211 @@ + get_the_ID(), + 'status' => 'approve', + 'parent' => $comment_id, + 'order' => 'ASC' + )); + + if ($replies) { + $count += count($replies); + foreach ($replies as $reply) { + $count += count_nested_replies($reply->comment_ID); + } + } + + return $count; +} + +if (post_password_required()) { + return; +} + +if (!is_user_logged_in()) { + ?> +
+

+ , +

+
+ get_the_ID(), + 'status' => 'approve', + 'parent' => 0, + 'order' => 'ASC' +)); + +if ($top_level_comments) { + echo '
'; + + foreach ($top_level_comments as $comment) { + ?> +
+
+ +
+
+ +
+
+

+
+ + + pll__('Ответить'), + 'depth' => 1, + 'max_depth' => get_option('thread_comments_depth'), + 'before' => '', + 'after' => '', + ), $comment->comment_ID, get_the_ID()); + ?> +
+ +
+ comment_ID); + + if (!empty($all_nested_replies)) { + $total_reply_count = count($all_nested_replies); + ?> + + +
+
+ +
+
+ +
+
+

+
+ + + pll__('Ответить'), + 'depth' => 2, + 'max_depth' => get_option('thread_comments_depth'), + 'before' => '', + 'after' => '', + ), $reply->comment_ID, get_the_ID()); + ?> +
+ +
+ '; +} + +function get_all_nested_replies($comment_id) { + $all_replies = array(); + + $direct_replies = get_comments(array( + 'post_id' => get_the_ID(), + 'status' => 'approve', + 'parent' => $comment_id, + 'order' => 'ASC' + )); + + $all_replies = array_merge($all_replies, $direct_replies); + + foreach ($direct_replies as $reply) { + $deeper_replies = get_all_nested_replies_recursive($reply->comment_ID); + $all_replies = array_merge($all_replies, $deeper_replies); + } + + return $all_replies; +} + +function get_all_nested_replies_recursive($comment_id) { + $replies = get_comments(array( + 'post_id' => get_the_ID(), + 'status' => 'approve', + 'parent' => $comment_id, + 'order' => 'ASC' + )); + + $all_replies = $replies; + + foreach ($replies as $reply) { + $deeper_replies = get_all_nested_replies_recursive($reply->comment_ID); + $all_replies = array_merge($all_replies, $deeper_replies); + } + + return $all_replies; +} + +if (is_user_logged_in()) { + $commenter = wp_get_current_commenter(); + $args = array( + 'fields' => array( + 'author' => '', + 'email' => '', + 'url' => '', + 'cookies' => '', + ), + 'comment_field' => '
', + 'title_reply' => pll__('Оставить комментарий'), + 'title_reply_to' => pll__('Ответить %s'), + 'class_submit' => 'comment-submit-btn', + 'submit_button' => '', + 'submit_field' => '
%1$s %2$s
', + 'cancel_reply_link' => pll__('Отменить'), + 'id_form' => 'commentform', + 'id_submit' => 'submit', + 'title_reply_before' => '

', + 'title_reply_after' => '

', + ); + + comment_form($args); +} +?> \ No newline at end of file diff --git a/wp-content/themes/cosmopet/functions.php b/wp-content/themes/cosmopet/functions.php index e3ad1dd..0eab026 100644 --- a/wp-content/themes/cosmopet/functions.php +++ b/wp-content/themes/cosmopet/functions.php @@ -42,6 +42,14 @@ function theme_add_woocommerce_support() add_action('after_setup_theme', 'theme_add_woocommerce_support'); add_theme_support('post-thumbnails'); +add_action('after_setup_theme', function() { + add_theme_support('comments'); + + update_option('default_comment_status', 'open'); +}); + + + //Подруключение всех ajax controller если запрос сделан по ajax @@ -144,7 +152,7 @@ add_action('wp_enqueue_scripts', function() use ($module_name, $module_dir) { $css_files = scandir($css_dir); // Приоритетные файлы - $priority_files = [ + $priority_files = [ 'normalize.css', 'gp-style-core.css', 'gp-style-desktop.css', @@ -415,6 +423,8 @@ requireShortcodes(get_template_directory() . '/modules'); require_once('modules/blog/module-ajax-controller.php'); require_once('modules/forms/module-ajax-controller.php'); +require_once('modules/author/module-ajax-controller.php'); + include_module('forms'); include_module('layout'); @@ -525,12 +535,19 @@ function get_products() { } function get_product_info ($id, $type) { - $product = wc_get_product( $id ); + if (!$id) { + return ''; + } + $product = wc_get_product($id); + if (!$product) { + return ''; + } if ($type == 'price') { return $product->get_price(); } elseif ($type == 'weight') { - return $product->get_weight() . ' кг'; + return $product->get_weight() ? $product->get_weight() . ' кг' : ''; } + return ''; } function get_add_to_cart_button ($id) { @@ -540,6 +557,10 @@ function get_add_to_cart_button ($id) { } function get_collection_siblings ($term) { + if (!$term) { + return []; + } + $args = array( 'posts_per_page' => -1, 'post_type' => 'product', @@ -573,3 +594,342 @@ register_sidebar( array( 'before_title' => '

', 'after_title' => '

', ) ); + + +function add_comment_like() { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + $wpdb->show_errors(); + if (!is_user_logged_in()) { + wp_send_json_error('Необходимо авторизоваться'); + die(); + } + $comment_id = isset($_POST['comment_id']) ? intval($_POST['comment_id']) : 0; + $user_id = get_current_user_id(); + if ($comment_id) { + $comment_exists = get_comment($comment_id); + if (!$comment_exists) { + echo '0'; + die(); + } + $existing_like = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE comment_id = %d AND user_id = %d", + $comment_id, $user_id + )); + if (!$existing_like) { + $result = $wpdb->insert( + $table_name, + array( + 'user_id' => $user_id, + 'comment_id' => $comment_id, + 'date_added' => current_time('mysql') + ), + array('%d', '%d', '%s') + ); + } else { + $result = $wpdb->delete( + $table_name, + array( + 'user_id' => $user_id, + 'comment_id' => $comment_id + ), + array('%d', '%d') + ); + } + $likes = get_comment_likes_count($comment_id); + wp_send_json(array( + 'count' => $likes, + 'is_liked' => !$existing_like + )); + } else { + wp_send_json(array('count' => 0, 'is_liked' => false)); + } + die(); +} +add_action('wp_ajax_add_comment_like', 'add_comment_like'); + +function add_post_like() { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + if (!is_user_logged_in()) { + wp_send_json_error('Необходимо авторизоваться'); + die(); + } + $post_id = isset($_POST['post_id']) ? intval($_POST['post_id']) : 0; + $user_id = get_current_user_id(); + if ($post_id) { + $existing_like = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE post_id = %d AND user_id = %d", + $post_id, $user_id + )); + if (!$existing_like) { + $wpdb->insert( + $table_name, + array( + 'user_id' => $user_id, + 'post_id' => $post_id, + 'date_added' => current_time('mysql') + ), + array('%d', '%d', '%s') + ); + } else { + $wpdb->delete( + $table_name, + array( + 'user_id' => $user_id, + 'post_id' => $post_id + ), + array('%d', '%d') + ); + } + $likes = get_post_likes_count($post_id); + wp_send_json(array( + 'count' => $likes, + 'is_liked' => !$existing_like + )); + } + die(); +} +add_action('wp_ajax_add_post_like', 'add_post_like'); + +function check_user_likes() { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + if (!is_user_logged_in()) { + wp_send_json_error('Необходимо авторизоваться'); + die(); + } + $user_id = get_current_user_id(); + $liked_posts = $wpdb->get_col($wpdb->prepare( + "SELECT post_id FROM $table_name WHERE user_id = %d AND post_id > 0", + $user_id + )); + $liked_comments = $wpdb->get_col($wpdb->prepare( + "SELECT comment_id FROM $table_name WHERE user_id = %d AND comment_id > 0", + $user_id + )); + $response = array( + 'posts' => $liked_posts, + 'comments' => $liked_comments + ); + echo json_encode($response); + die(); +} +add_action('wp_ajax_check_user_likes', 'check_user_likes'); + + + +function get_post_likes_count($post_id) { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + $count = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE post_id = %d", + $post_id + )); + return $count ? $count : 0; +} + +function get_comment_likes_count($comment_id) { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + $count = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE comment_id = %d", + $comment_id + )); + return $count ? $count : 0; +} + +function is_user_liked_post($post_id) { +if (!is_user_logged_in()) { + return false; +} +global $wpdb; +$table_name = $wpdb->prefix . 'cosmopet_likes'; +$user_id = get_current_user_id(); +$result = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE post_id = %d AND user_id = %d", + $post_id, $user_id +)); +return $result > 0; +} + + +function is_user_liked_comment($comment_id) { +if (!is_user_logged_in()) { + return false; +} +global $wpdb; +$table_name = $wpdb->prefix . 'cosmopet_likes'; +$user_id = get_current_user_id(); +$result = $wpdb->get_var($wpdb->prepare( + "SELECT COUNT(*) FROM $table_name WHERE comment_id = %d AND user_id = %d", + $comment_id, $user_id +)); +return $result > 0; +} + + +add_filter('comment_form_logged_in', '__return_empty_string'); + + + // Создание таблицы +function create_likes_table() { + global $wpdb; + $table_name = $wpdb->prefix . 'cosmopet_likes'; + $charset_collate = $wpdb->get_charset_collate(); + $sql = "CREATE TABLE IF NOT EXISTS $table_name ( + id bigint(20) NOT NULL AUTO_INCREMENT, + user_id bigint(20) NOT NULL, + post_id bigint(20) DEFAULT '0', + comment_id bigint(20) DEFAULT '0', + date_added datetime DEFAULT CURRENT_TIMESTAMP, + PRIMARY KEY (id), + KEY post_id (post_id), + KEY comment_id (comment_id), + KEY user_id (user_id), + UNIQUE KEY user_post (user_id, post_id, comment_id) + ) $charset_collate;"; + require_once(ABSPATH . 'wp-admin/includes/upgrade.php'); + dbDelta($sql); +} +add_action('after_switch_theme', 'create_likes_table'); + + + +add_filter('woocommerce_product_data_tabs', function($tabs) { + $tabs['composition_tab'] = array( + 'label' => 'Состав', + 'target' => 'composition_product_data', + 'class' => array('composition_tab'), + 'priority' => 60, + ); + $tabs['feeding_tab'] = array( + 'label' => 'Рекомендации по кормлению', + 'target' => 'feeding_product_data', + 'class' => array('feeding_tab'), + 'priority' => 61, + ); + $tabs['important_tab'] = array( + 'label' => 'Важно', + 'target' => 'important_product_data', + 'class' => array('important_tab'), + 'priority' => 62, + ); + return $tabs; +}); + + +add_action('woocommerce_product_data_panels', function() { + global $post; + $composition = get_post_meta($post->ID, '_composition', true); + echo '
'; + woocommerce_wp_textarea_input([ + 'id' => '_composition', + 'label' => 'Состав', + 'desc_tip' => true, + 'description' => 'Введите состав товара', + 'value' => $composition + ]); + echo '
'; +}); + + +add_action('woocommerce_product_data_panels', function() { + global $post; + $feeding = get_post_meta($post->ID, '_feeding_recommendations', true); + echo '
'; + woocommerce_wp_textarea_input([ + 'id' => '_feeding_recommendations', + 'label' => 'Рекомендации по кормлению', + 'desc_tip' => true, + 'description' => 'Введите рекомендации по кормлению', + 'value' => $feeding + ]); + echo '
'; +}); + + +add_action('woocommerce_product_data_panels', function() { + global $post; + $important = get_post_meta($post->ID, '_important', true); + echo '
'; + woocommerce_wp_textarea_input([ + 'id' => '_important', + 'label' => 'Важно', + 'desc_tip' => true, + 'description' => 'Введите важную информацию', + 'value' => $important + ]); + echo '
'; +}); + +add_action('woocommerce_process_product_meta', function($post_id) { + if (isset($_POST['_composition'])) { + update_post_meta($post_id, '_composition', sanitize_textarea_field($_POST['_composition'])); + } + if (isset($_POST['_feeding_recommendations'])) { + update_post_meta($post_id, '_feeding_recommendations', sanitize_textarea_field($_POST['_feeding_recommendations'])); + } + if (isset($_POST['_important'])) { + update_post_meta($post_id, '_important', sanitize_textarea_field($_POST['_important'])); + } +}); +// Добавление поля для выбора рекомендуемых товаров +function register_recommended_products_acf_field() { + if (function_exists('acf_add_local_field_group')) { + acf_add_local_field_group(array( + 'key' => 'group_recommended_products', + 'title' => 'Рекомендуемые товары', + 'fields' => array( + array( + 'key' => 'field_recommended_products', + 'label' => 'Выберите рекомендуемые товары', + 'name' => 'recommended_products', + 'type' => 'relationship', + 'instructions' => 'Выберите товары, которые будут отображаться в секции "вашему питомцу может понравиться"', + 'required' => 0, + 'conditional_logic' => 0, + 'post_type' => array( + 0 => 'product', + ), + 'filters' => array( + 0 => 'search', + 1 => 'taxonomy', + ), + 'return_format' => 'object', + 'min' => '', + 'max' => 8, + ), + ), + 'location' => array( + array( + array( + 'param' => 'post_type', + 'operator' => '==', + 'value' => 'product', + ), + ), + ), + 'menu_order' => 0, + 'position' => 'normal', + 'style' => 'default', + 'label_placement' => 'top', + 'instruction_placement' => 'label', + 'hide_on_screen' => '', + )); + } +} +add_action('acf/init', 'register_recommended_products_acf_field'); + +add_action('wp_footer', 'remove_view_cart_button_js'); +function remove_view_cart_button_js() { + ?> + + div { + display: flex; + align-items: center; + gap: 4px; + font-size: 14px; + font-weight: 500; + line-height: 16px; + color: var(--interface_hover); +} + +.home-card__content-body__data>div .main-img { + width: 32px; + height: 32px; + border-radius: 50%; + object-fit: cover; +} + +.home-card__content-body__link { + border: 1px solid #000000; + border-radius: 28px; + background: var(--main_white); + position: absolute; + right: 37px; + bottom: 26px; + padding: 8.5px 16px 12.5px; + font-style: 20px; + font-weight: 500; + line-height: 24px; +} +/* Home end */ + + +/* Anons */ +.anons { + background: var(--main_white); + border-radius: 60px; + padding: 51px 0; +} + +.anons-theme__title { + color: var(--main_black); + font-size: 24px; + font-weight: bold; + line-height: 28px; + text-transform: uppercase; + margin-bottom: 20px; +} + +.anons-theme { + margin-bottom: 60px; +} + +.anons-theme ul { + max-width: 1022px; + display: flex; + flex-wrap: wrap; + gap: 12px; +} + +.anons-theme ul a { + font-size: 20px; + font-weight: 600; + line-height: 24px; + color: var(--main_black); + padding: 4px 24px; + border: 1px solid #000; + border-radius: 20px; +} + +.anons-theme ul a:hover, +.anons-theme ul a.active { + background: var(--main_black); + color: var(--main_white); +} + +.anons-best { + margin-bottom: 60px; +} + +.anons-best__title { + font-size: 36px; + line-height: 40px; + font-weight: bold; + color: var(--main_black); + margin-bottom: 20px; +} + +.anons-best__card-wrap { + display: grid; + grid-template-columns: repeat(3, minmax(0, 1fr)); + gap: 24px; +} + +.anons-best__card { + padding-top: 293px; + border-radius: 48px; + overflow: hidden; + position: relative; + z-index: 1; +} + +.anons-best__card.light { + padding-top: 0; + border-radius: 0; +} + +.anons-best__card .main-img { + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 360px; + z-index: -1; +} + +.anons-best__card .main-img img { + width: 100%; + height: 100%; + object-fit: cover; +} + +.anons-best__card.light .main-img { + position: static; + height: 265px; +} +.anons-best__card.light .main-img img { + border-radius: 30px; +} + +.anons-best__card-alerts { + position: absolute; + top: 21px; + left: 17px; + width: calc(100% - 34px); + display: flex; + flex-wrap: wrap; + gap: 7px; + z-index: 1; +} + +.anons-best__card-alerts li { + padding: 6px 8px; + font-size: 16px; + line-height: 20px; + font-weight: 500; + color: var(--background); + background: var(--main_black); + border-radius: 30px; +} + +.anons-best__card-body { + background: var(--accent-1); + padding: 30px 17px 22px; + border-radius: 48px 48px 0 0; + color: var(--main_white); + position: relative; + height: 100%; +} + +.anons-best__card.light .anons-best__card-body { + background: transparent; + color: var(--main_black); + padding: 12px 0 34px; +} + +.anons-best__card-body__title { + font-size: 28px; + font-weight: bold; + line-height: 32px; + text-transform: uppercase; + margin-bottom: 14px; +} + +.anons-best__card.light .anons-best__card-body__title { + font-size: 26px; +} + +.anons-best__card-body__datas { + display: flex; + align-items: center; + flex-wrap: wrap; + gap: 6px 10px; + max-width: 264px; +} + +.anons-best__card.light .anons-best__card-body__datas { + color: var(--placeholder); +} + +.anons-best__card-body__datas p { + font-size: 14px; + line-height: 16px; + font-weight: 500; +} + +.anons-best__card-body__datas ul { + display: flex; + align-items: center; + gap: 10px; +} + +.anons-best__card-body__datas ul li { + display: flex; + align-items: center; + gap: 4px; + font-size: 14px; + line-height: 16px; + font-weight: 500; +} + +.anons-best__card-body__datas ul .logo img { + width: 24px; + height: 24px; + border-radius: 50%; + object-fit: cover; +} + +.anons-article { + margin-bottom: 40px; +} + +.anons-article__title { + font-size: 36px; + line-height: 40px; + font-weight: bold; + color: var(--main_black); + margin-bottom: 20px; +} + +.anons-article__card-wrap { + display: grid; + grid-template-columns: repeat(3, minmax(0, 1fr)); + gap: 40px 25px; +} + +.anons-article__more-link { + display: flex; + align-items: center; + justify-content: center; +} + +.anons-article__more-link a { + background: var(--accent-3); + color: var(--main_white); + border-radius: 20px; + border: 1px solid var(--main_white); + padding: 16px 24px; + font-size: 20px; + font-weight: 600; + line-height: 24px; + text-transform: uppercase; +} +/* Anons end */ + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-mobile.css b/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-mobile.css new file mode 100644 index 0000000..5b3fc9f --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-mobile.css @@ -0,0 +1,120 @@ +/* Стили для мобильных устройств */ +@media only screen and (max-width: 576px) { + .anons-best__title { + font-size: 26px; + line-height: 32px; + margin-bottom: 12px; + } + + .anons-best__card { + padding-top: 205px; + } + + .anons-best__card .main-img { + height: 300px; + } + + .anons-best__card-body { + padding: 20px 17px; + } + + .anons-best__card-body__title { + font-size: 20px; + line-height: 24px; + margin-bottom: 16px; + } + + .anons-best__card.light .main-img { + height: 197px; + } + + .anons-best__card.light .anons-best__card-body__title { + font-size: 20px; + line-height: 24px; + } + + + + .authors { + padding-bottom: 138px; + } + + .authors h2 { + font-size: 32px; + line-height: 38px; + margin-bottom: 15px; + } + + .authors li { + border-radius: 24px; + width: 100%; + } + + .authors a { + padding: 32px 17px 52px; + } + + .authors .main-img { + width: 180px; + height: 180px; + margin-bottom: 20px; + } + + .authors-name { + font-size: 20px; + line-height: 24px; + } + + .authors-type { + font-size: 18px; + line-height: 24px; + margin-bottom: 20px; + } + + .authors p { + font-size: 16px; + line-height: 20px; + } + + .author-head { + padding-bottom: 15px; + } + + .author-head-content { + margin-bottom: 23px; + } + + .author-head .main-img { + width: 100%; + } + + .author-head h2 { + font-size: 32px; + line-height: 38px; + } + + .author-name { + font-size: 20px; + line-height: 24px; + } + + .author-type { + font-size: 18px; + line-height: 24px; + } + + .author-description { + font-size: 18px; + line-height: 24px; + margin-bottom: 24px; + } + + .author-head p { + font-size: 16px; + line-height: 20px; + } +} + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-tablet.css b/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-tablet.css new file mode 100644 index 0000000..00bae10 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/css/gp-style-tablet.css @@ -0,0 +1,44 @@ +/* Стили для планшетов */ +@media only screen and (max-width: 992px) { + + .authors h2 { + font-size: 48px; + margin-bottom: 24px; + } + + .authors li { + border-radius: 32px; + width: calc(50% - 12px); + } + + .authors .main-img { + margin-bottom: 24px; + } + + .author { + padding-bottom: 24px; + } + + .author h2 { + font-size: 48px; + } + + .author-head-content { + flex-direction: column; + align-items: flex-start; + } +} + + + +/* Стили для планшетов */ +@media only screen and (max-width: 992px) { + + .author { + padding: 188px 0 36px; + } + + + + +} diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/arrow-down.svg b/wp-content/themes/cosmopet/modules/author/assets/img/arrow-down.svg new file mode 100644 index 0000000..be8f47a --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/arrow-down.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-1.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-1.png new file mode 100644 index 0000000..5857f04 Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-1.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-2.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-2.png new file mode 100644 index 0000000..125d947 Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-2.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-3.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-3.png new file mode 100644 index 0000000..f5a11c1 Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-3.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-4.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-4.png new file mode 100644 index 0000000..a54bf7c Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-4.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-5.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-5.png new file mode 100644 index 0000000..9685422 Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-5.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/author-main-card.png b/wp-content/themes/cosmopet/modules/author/assets/img/author-main-card.png new file mode 100644 index 0000000..a271f5b Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/author-main-card.png differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/bars.svg b/wp-content/themes/cosmopet/modules/author/assets/img/bars.svg new file mode 100644 index 0000000..0ff9b2e --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/bars.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/basket-icon.svg b/wp-content/themes/cosmopet/modules/author/assets/img/basket-icon.svg new file mode 100644 index 0000000..6ee2bce --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/basket-icon.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/favicon.ico b/wp-content/themes/cosmopet/modules/author/assets/img/favicon.ico new file mode 100644 index 0000000..5517fde Binary files /dev/null and b/wp-content/themes/cosmopet/modules/author/assets/img/favicon.ico differ diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-1.svg b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-1.svg new file mode 100644 index 0000000..8a88433 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-1.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-2.svg b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-2.svg new file mode 100644 index 0000000..b7f36f4 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-2.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-3.svg b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-3.svg new file mode 100644 index 0000000..19e914a --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/footer-network-3.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/header-red.svg b/wp-content/themes/cosmopet/modules/author/assets/img/header-red.svg new file mode 100644 index 0000000..95c7ae6 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/header-red.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/heart-grey.svg b/wp-content/themes/cosmopet/modules/author/assets/img/heart-grey.svg new file mode 100644 index 0000000..81573c3 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/heart-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/heart-white.svg b/wp-content/themes/cosmopet/modules/author/assets/img/heart-white.svg new file mode 100644 index 0000000..7250c70 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/heart-white.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/heart.svg b/wp-content/themes/cosmopet/modules/author/assets/img/heart.svg new file mode 100644 index 0000000..95c2899 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/heart.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/indent-icon-1.svg b/wp-content/themes/cosmopet/modules/author/assets/img/indent-icon-1.svg new file mode 100644 index 0000000..80d233c --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/indent-icon-1.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/logo-green.svg b/wp-content/themes/cosmopet/modules/author/assets/img/logo-green.svg new file mode 100644 index 0000000..4b64e3b --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/logo-green.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/logo.svg b/wp-content/themes/cosmopet/modules/author/assets/img/logo.svg new file mode 100644 index 0000000..d3929b8 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/logo.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/long-arrow.svg b/wp-content/themes/cosmopet/modules/author/assets/img/long-arrow.svg new file mode 100644 index 0000000..6a3baa3 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/long-arrow.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/minus-icon.svg b/wp-content/themes/cosmopet/modules/author/assets/img/minus-icon.svg new file mode 100644 index 0000000..b4d504c --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/minus-icon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/msg-green.svg b/wp-content/themes/cosmopet/modules/author/assets/img/msg-green.svg new file mode 100644 index 0000000..9e521bc --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/msg-green.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/msg-grey.svg b/wp-content/themes/cosmopet/modules/author/assets/img/msg-grey.svg new file mode 100644 index 0000000..b126087 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/msg-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/msg-white.svg b/wp-content/themes/cosmopet/modules/author/assets/img/msg-white.svg new file mode 100644 index 0000000..b920033 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/msg-white.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/msg.svg b/wp-content/themes/cosmopet/modules/author/assets/img/msg.svg new file mode 100644 index 0000000..7471b49 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/msg.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/plus-icon.svg b/wp-content/themes/cosmopet/modules/author/assets/img/plus-icon.svg new file mode 100644 index 0000000..6066429 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/plus-icon.svg @@ -0,0 +1,18 @@ + + + + + + + + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/swp-next.svg b/wp-content/themes/cosmopet/modules/author/assets/img/swp-next.svg new file mode 100644 index 0000000..6393610 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/swp-next.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/swp-prev.svg b/wp-content/themes/cosmopet/modules/author/assets/img/swp-prev.svg new file mode 100644 index 0000000..b886a4f --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/swp-prev.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/img/user-icon.svg b/wp-content/themes/cosmopet/modules/author/assets/img/user-icon.svg new file mode 100644 index 0000000..4b9a9a9 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/img/user-icon.svg @@ -0,0 +1,4 @@ + + + + diff --git a/wp-content/themes/cosmopet/modules/author/assets/js/author-posts-ajax.js b/wp-content/themes/cosmopet/modules/author/assets/js/author-posts-ajax.js new file mode 100644 index 0000000..8fdcaff --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/js/author-posts-ajax.js @@ -0,0 +1,46 @@ +jQuery(document).ready(function ($) { + $('#ajax-load-author').on('submit', function (e) { + e.preventDefault(); + var form = $(this); + var currentPage = parseInt($('#page_num').val()); + var totalPosts = parseInt(form.data('total')); + var postsPerPage = 9; + + console.log('Current page before load:', currentPage); + console.log('Total posts:', totalPosts); + console.log('Posts loaded before request:', postsPerPage); + + var data = { + action: 'get_author_posts', + page_num: currentPage, + author_id: form.data('author') + }; + + console.log('Sending AJAX request with data:', data); + + $.ajax({ + url: '/wp-admin/admin-ajax.php', + type: 'POST', + data: data, + success: function (response) { + console.log('AJAX response received'); + $(".anons-article__card-wrap").append(response); + + $('#page_num').val(currentPage + 1); + console.log('New page number:', currentPage + 1); + + // Считаем общее количество загруженных постов + var currentlyDisplayed = $('.anons-article__card-wrap .anons-best__card').length; + console.log('Actually displayed posts:', currentlyDisplayed); + + if (currentlyDisplayed >= totalPosts) { + console.log('Hiding load more button - all posts loaded'); + form.hide(); + } + }, + error: function (error) { + console.error('AJAX error:', error); + } + }); + }); +}); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/author/assets/js/main.js b/wp-content/themes/cosmopet/modules/author/assets/js/main.js new file mode 100644 index 0000000..0f43b8d --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/assets/js/main.js @@ -0,0 +1,48 @@ +// const homeSwp = new Swiper('.home-swp .swiper', { +// slidesPerView: 1, +// spaceBetween: 0, +// effect: 'fade', +// loop: true, +// navigation: { +// nextEl: '.home-swp__btn-next', +// prevEl: '.home-swp__btn-prev', +// } +// }) + +// const textsSwp = new Swiper('.texts-swp .swiper', { +// slidesPerView: 1, +// spaceBetween: 0, +// loop: true, +// effect: 'fade', +// navigation: { +// nextEl: '.texts-swp__next', +// prevEl: '.texts-swp__prev' +// }, +// pagination: { +// el: ".texts-swp__pagination", +// clickable: true, +// } +// }) + +// comment +// let answerbtns = document.querySelectorAll('.answer-btn'); +// let answerbtnicons = document.querySelectorAll('.answer-btn svg'); +// let answerblocks = document.querySelectorAll('.answer-block'); + +// answerbtns.forEach((answerbtn, index) => { +// answerbtn.addEventListener('click', () => { +// let answerbtnicon = answerbtnicons[index]; +// let answerblock = answerblocks[index]; + +// answerblock.classList.toggle('active'); +// answerbtnicon.classList.toggle('active'); + +// let buttonText = answerbtn.querySelector('span'); +// if (buttonText.textContent === 'Ответ') { +// buttonText.textContent = 'Свернуть'; +// } else { +// buttonText.textContent = 'ответ'; +// } +// }); +// }); +// comment diff --git a/wp-content/themes/cosmopet/modules/author/components/author-archive/component-controller.php b/wp-content/themes/cosmopet/modules/author/components/author-archive/component-controller.php new file mode 100644 index 0000000..92c3a0a --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/components/author-archive/component-controller.php @@ -0,0 +1,54 @@ +publish; +$context['total_pages'] = ceil($context['post_count'] / get_option('posts_per_page')); + +$context['sub_title'] = get_field('sub_title', 383); +$context['sub_text'] = get_field('sub_text', 383); + +$authors = Timber::get_posts([ + 'post_type' => 'blog_author', + 'posts_per_page' => -1, + 'orderby' => 'menu_order', + 'order' => 'ASC', +]); + +$authors_arr = iterator_to_array($authors); +foreach ($authors_arr as $author) { + $author_id = $author->ID; + $query = new WP_Query([ + 'post_type' => 'post', + 'posts_per_page' => -1, + 'meta_query' => [ + [ + 'key' => 'post_author', + 'value' => $author_id, + 'compare' => '=' + ] + ] + ]); + $author->post_count = $query->found_posts; + $author->position = get_field('post', $author_id); + $author->posts = Timber::get_posts([ + 'post_type' => 'post', + 'posts_per_page' => -1, + 'meta_query' => [ + [ + 'key' => 'post_author', + 'value' => $author_id, + 'compare' => '=' + ] + ] + ]); +} +$context['authors'] = $authors_arr; + +Timber::render('blog_author/author-archive.twig', $context); diff --git a/wp-content/themes/cosmopet/modules/author/components/author-single/component-controller.php b/wp-content/themes/cosmopet/modules/author/components/author-single/component-controller.php new file mode 100644 index 0000000..832d82d --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/components/author-single/component-controller.php @@ -0,0 +1,41 @@ +ID; + + +$author->position = get_field('post', $author_id); + +$count_query = new WP_Query([ + 'post_type' => 'post', + 'post_status' => 'publish', + 'posts_per_page' => -1, + 'meta_query' => [ + [ + 'key' => 'post_author', + 'value' => $author_id, + 'compare' => '=' + ] + ] +]); +$author->post_count = $count_query->found_posts; + +$author->posts = Timber::get_posts([ + 'post_type' => 'post', + 'post_status' => 'publish', + 'posts_per_page' => 9, + 'meta_query' => [ + [ + 'key' => 'post_author', + 'value' => $author_id, + 'compare' => '=' + ] + ] +]); + +$context['author'] = $author; +$context['total_pages'] = ceil($author->post_count / 9); + +Timber::render('blog_author/author-single.twig', $context); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/author/module-ajax-controller.php b/wp-content/themes/cosmopet/modules/author/module-ajax-controller.php new file mode 100644 index 0000000..5ed693d --- /dev/null +++ b/wp-content/themes/cosmopet/modules/author/module-ajax-controller.php @@ -0,0 +1,35 @@ + 'post', + 'post_status' => 'publish', + 'posts_per_page' => -1, + 'meta_query' => [ + [ + 'key' => 'post_author', + 'value' => $author_id, + 'compare' => '=' + ] + ] + ]); + + if ($all_posts instanceof \Timber\PostQuery || $all_posts instanceof \Timber\PostCollection) { + $all_posts = $all_posts->get_posts(); + } + + $remaining_posts = array_slice($all_posts, 9); + + $context = Timber::context(); + $context['posts'] = $remaining_posts; + + Timber::render('blog_author/author-posts-list.twig', $context); + wp_die(); +} + +add_action('wp_ajax_get_author_posts', 'get_author_posts'); +add_action('wp_ajax_nopriv_get_author_posts', 'get_author_posts'); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/blog/assets/css/gp-style-desktop.css b/wp-content/themes/cosmopet/modules/blog/assets/css/gp-style-desktop.css index c2d3155..93297df 100644 --- a/wp-content/themes/cosmopet/modules/blog/assets/css/gp-style-desktop.css +++ b/wp-content/themes/cosmopet/modules/blog/assets/css/gp-style-desktop.css @@ -4,4 +4,63 @@ main{ .block-lists_text p { font-size: 18px!important; +} + +.user a{ + display: flex; + align-items: center; + gap: 5px; +} + +.user a{ + display:flex; + gap:5px; +} + +.user img{ + width:30px; + border-radius:100px; +} + +.anons-best__card-body__datas .logo a{ + display: flex; + align-items: center; + gap:5px; + margin-top: 10px; +} + +.comment-submit-btn{ + border: 1px solid #000000; + border-radius: 28px; + background: var(--main_white); + + padding: 8.5px 16px 8.5px; + font-size: 20px; + font-weight: 500; + line-height: 24px; + margin-top: 15px; + transition: all .5s; +} + +.comment-reply-title , .logged-in-as{ + margin: 10px 0; +} + +.comment-block.answer-block.active{ + margin-top: 15px; +} + +.comment-form-comment textarea{ + padding: 28px 48px; + border-radius: 24px; + background: #f5f5f5 !important; +} + +.comment-respond{ + margin-top: 30px; +} + + +.reply-form-container textarea{ + background-color: #fff !important; } \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/blog/assets/js/comments.js b/wp-content/themes/cosmopet/modules/blog/assets/js/comments.js new file mode 100644 index 0000000..baa8004 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/assets/js/comments.js @@ -0,0 +1,198 @@ +// comment +let answerbtns = document.querySelectorAll('.answer-btn'); +let answerbtnicons = document.querySelectorAll('.answer-btn svg'); + +// При загрузке страницы проверяем активные кнопки +document.addEventListener('DOMContentLoaded', function() { + // Для каждой кнопки ответов + answerbtns.forEach((answerbtn) => { + // Находим родительский контейнер, чтобы искать ответы только для этого комментария + const buttonParent = answerbtn.parentElement; + + // Находим все блоки ответов для этого комментария (после текущей кнопки) + const answerBlocks = getRelatedAnswerBlocks(answerbtn); + if (answerBlocks.length === 0) return; + + // Проверяем, должны ли быть ответы развернуты (если у кнопки или любого ответа есть класс active) + const shouldBeActive = answerbtn.querySelector('svg').classList.contains('active') || + Array.from(answerBlocks).some(block => block.classList.contains('active')); + + if (shouldBeActive) { + // Активируем все ответы только для этого комментария + answerBlocks.forEach(block => { + block.classList.add('active'); + }); + + // Обновляем состояние кнопки + answerbtn.querySelector('svg').classList.add('active'); + + // Обновляем текст кнопки + let buttonText = answerbtn.querySelector('span'); + if (buttonText) { + buttonText.textContent = 'Свернуть'; + } + } else { + // Скрываем все ответы + answerBlocks.forEach(block => { + block.classList.remove('active'); + }); + + // Обновляем состояние кнопки + answerbtn.querySelector('svg').classList.remove('active'); + + // Обновляем текст кнопки в зависимости от количества ответов + let buttonText = answerbtn.querySelector('span'); + if (buttonText) { + const count = answerBlocks.length; + buttonText.textContent = count === 1 ? 'ответ' : 'ответа'; + } + } + }); +}); + +// Функция для получения блоков ответов, связанных с данной кнопкой +function getRelatedAnswerBlocks(answerBtn) { + // Получаем следующий блок комментариев (если он есть) + let currentElement = answerBtn; + let answerBlocks = []; + + // Собираем все блоки ответов до следующего основного комментария или кнопки ответов + while ((currentElement = currentElement.nextElementSibling) !== null) { + if (currentElement.classList.contains('comment-block') && !currentElement.classList.contains('answer-block')) { + // Достигли следующего основного комментария, прерываем сбор + break; + } else if (currentElement.classList.contains('answer-btn')) { + // Достигли следующей кнопки ответов, прерываем сбор + break; + } else if (currentElement.classList.contains('answer-block')) { + // Это блок ответа, добавляем в коллекцию + answerBlocks.push(currentElement); + } + } + + return answerBlocks; +} + +// Обработчики нажатия на кнопки ответов +answerbtns.forEach((answerbtn) => { + answerbtn.addEventListener('click', () => { + // Получаем все блоки ответов для этого комментария + const answerBlocks = getRelatedAnswerBlocks(answerbtn); + if (answerBlocks.length === 0) return; + + // Определяем, развернуты ли ответы сейчас + const isCurrentlyActive = answerbtn.querySelector('svg').classList.contains('active'); + + // Переключаем состояние + if (isCurrentlyActive) { + // Скрываем все ответы + answerBlocks.forEach(block => { + block.classList.remove('active'); + }); + + // Обновляем состояние кнопки + answerbtn.querySelector('svg').classList.remove('active'); + + // Обновляем текст кнопки + let buttonText = answerbtn.querySelector('span'); + if (buttonText) { + const count = answerBlocks.length; + buttonText.textContent = count === 1 ? 'ответ' : 'ответа'; + } + } else { + // Показываем все ответы + answerBlocks.forEach(block => { + block.classList.add('active'); + }); + + // Обновляем состояние кнопки + answerbtn.querySelector('svg').classList.add('active'); + + // Обновляем текст кнопки + let buttonText = answerbtn.querySelector('span'); + if (buttonText) { + buttonText.textContent = 'Свернуть'; + } + } + }); +}); + +// Обработка нажатия на кнопку "Ответить" на комментарий +document.addEventListener('DOMContentLoaded', function() { + // Получаем все кнопки "Ответить" на странице + const replyButtons = document.querySelectorAll('.reply-to-comment'); + + // Добавляем обработчик на каждую кнопку + replyButtons.forEach(button => { + button.addEventListener('click', function() { + // Получаем ID комментария, на который отвечаем + const commentId = this.getAttribute('data-comment-id'); + const postId = this.getAttribute('data-post-id'); + const replyToName = this.getAttribute('data-reply-to'); + + // Получаем контейнер для формы ответа + const replyFormContainer = document.getElementById('reply-form-' + commentId); + + // Если форма уже открыта, скрываем её + if (replyFormContainer.style.display !== 'none') { + replyFormContainer.style.display = 'none'; + return; + } + + // Скрываем все открытые формы ответов + document.querySelectorAll('.reply-form-container').forEach(container => { + container.style.display = 'none'; + }); + + // Клонируем основную форму комментариев + const originalForm = document.getElementById('commentform'); + if (originalForm) { + const clonedForm = originalForm.cloneNode(true); + + // Изменяем атрибуты формы для ответа + clonedForm.id = 'commentform-reply-' + commentId; + + // Добавляем скрытое поле с ID родительского комментария + const hiddenInput = document.createElement('input'); + hiddenInput.type = 'hidden'; + hiddenInput.name = 'comment_parent'; + hiddenInput.value = commentId; + clonedForm.appendChild(hiddenInput); + + // Изменяем заголовок формы + const formTitle = clonedForm.querySelector('.comment-reply-title'); + if (formTitle) { + formTitle.textContent = 'Ответить ' + replyToName; + } + + // Добавляем кнопку отмены + const cancelButton = document.createElement('button'); + cancelButton.type = 'button'; + cancelButton.className = 'cancel-reply-btn'; + cancelButton.textContent = 'Отменить'; + cancelButton.addEventListener('click', function() { + replyFormContainer.style.display = 'none'; + }); + + // Добавляем кнопку отмены в форму + const submitContainer = clonedForm.querySelector('.form-submit'); + if (submitContainer) { + submitContainer.appendChild(cancelButton); + } + + // Очищаем контейнер и добавляем клонированную форму + replyFormContainer.innerHTML = ''; + replyFormContainer.appendChild(clonedForm); + + // Показываем форму + replyFormContainer.style.display = 'block'; + + // Фокусируемся на текстовой области + const textarea = clonedForm.querySelector('textarea'); + if (textarea) { + textarea.focus(); + } + } + }); + }); +}); diff --git a/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/header-red.svg b/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/header-red.svg new file mode 100644 index 0000000..95c7ae6 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/header-red.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/msg-green.svg b/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/msg-green.svg new file mode 100644 index 0000000..9e521bc --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/editorial/assets/img/msg-green.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/css/gp-style-desktop.css b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/css/gp-style-desktop.css index 07fda11..c06abc9 100644 --- a/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/css/gp-style-desktop.css +++ b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/css/gp-style-desktop.css @@ -173,4 +173,8 @@ .home-card__content-body__link:hover{ background-color: #000; color: #fff; +} + +.blog-home{ + padding-bottom: 4rem; } \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/heart-grey.svg b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/heart-grey.svg new file mode 100644 index 0000000..81573c3 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/heart-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/msg-grey.svg b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/msg-grey.svg new file mode 100644 index 0000000..b126087 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/featured-slider/assets/img/msg-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/heart-white.svg b/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/heart-white.svg new file mode 100644 index 0000000..7250c70 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/heart-white.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/msg-white.svg b/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/msg-white.svg new file mode 100644 index 0000000..b920033 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/most-read/assets/img/msg-white.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/heart-grey.svg b/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/heart-grey.svg new file mode 100644 index 0000000..81573c3 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/heart-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/msg-grey.svg b/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/msg-grey.svg new file mode 100644 index 0000000..b126087 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/news-list/assets/img/msg-grey.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/blog/components/single/assets/js/comments.js b/wp-content/themes/cosmopet/modules/blog/components/single/assets/js/comments.js new file mode 100644 index 0000000..e69de29 diff --git a/wp-content/themes/cosmopet/modules/blog/components/single/assets/js/post-likes.js b/wp-content/themes/cosmopet/modules/blog/components/single/assets/js/post-likes.js new file mode 100644 index 0000000..f44ec79 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/blog/components/single/assets/js/post-likes.js @@ -0,0 +1,147 @@ +jQuery(document).ready(function ($) { + $(".comment-btn button").on("click", function () { + var postId = $(this).data("post-id"); + var $button = $(this); + + $.ajax({ + url: "/wp-admin/admin-ajax.php", + type: "POST", + data: { + action: "add_post_like", + post_id: postId, + }, + success: function (response) { + if (response.error) { + alert(response.error); + window.location.href = "/wp-login.php"; + return; + } + + $(".comment-btn span").text(response.count); + + if (response.is_liked) { + $button.addClass("active"); + + $button.find("svg path").attr({ + fill: "rgba(255, 0, 0, 0.7)", + stroke: "#ff0000", + }); + } else { + $button.removeClass("active"); + + $button.find("svg path").attr({ + fill: "rgb(18, 18, 18)", + stroke: "#666666", + }); + } + }, + error: function (error) { + if (error.responseJSON && error.responseJSON.data) { + alert(error.responseJSON.data); + window.location.href = "/wp-login.php"; + } + }, + }); + }); + + $(document).on("click", ".comment-like-btn", function () { + var commentId = $(this).data("comment-id"); + var $button = $(this); + + $.ajax({ + url: "/wp-admin/admin-ajax.php", + type: "POST", + data: { + action: "add_comment_like", + comment_id: commentId, + }, + success: function (response) { + if (response.error) { + alert(response.error); + window.location.href = "/wp-login.php"; + return; + } + + if (response.is_liked) { + $button + .empty() + .append( + $( + '' + ) + ) + .append(response.count); + $button.addClass("active"); + } else { + $button + .empty() + .append( + $( + '' + ) + ) + .append(response.count); + $button.removeClass("active"); + } + }, + error: function (error) { + if (error.responseJSON && error.responseJSON.data) { + alert(error.responseJSON.data); + window.location.href = "/wp-login.php"; + } + }, + }); + }); + + function checkLikedPosts() { + if (!document.body.classList.contains("logged-in")) { + return; + } + + $.ajax({ + url: "/wp-admin/admin-ajax.php", + type: "POST", + data: { + action: "check_user_likes", + }, + success: function (response) { + if (response.error) { + return; + } + + try { + var data = JSON.parse(response); + + if (data.posts && data.posts.length > 0) { + for (var i = 0; i < data.posts.length; i++) { + var $button = $('.comment-btn button[data-post-id="' + data.posts[i] + '"]'); + $button.addClass("active"); + $button.find("svg path").attr({ + fill: "rgba(255, 0, 0, 0.7)", + stroke: "#ff0000", + }); + } + } + + if (data.comments && data.comments.length > 0) { + for (var j = 0; j < data.comments.length; j++) { + var $commentButton = $('.comment-like-btn[data-comment-id="' + data.comments[j] + '"]'); + $commentButton.addClass("active"); + + $commentButton.find("svg path").attr({ + fill: "rgba(255, 0, 0, 0.7)", + stroke: "#ff0000", + }); + } + } + } catch (e) {} + }, + error: function (error) {}, + }); + } + + if (document.body.classList.contains("logged-in")) { + checkLikedPosts(); + } + }); + \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/blog/components/single/component-controller.php b/wp-content/themes/cosmopet/modules/blog/components/single/component-controller.php index 4c6c9b5..85e5737 100644 --- a/wp-content/themes/cosmopet/modules/blog/components/single/component-controller.php +++ b/wp-content/themes/cosmopet/modules/blog/components/single/component-controller.php @@ -2,4 +2,6 @@ include_component('blog', 'featured-slider'); $context = Timber::get_context(); +$post = Timber::get_post(); +$context['post'] = $post; Timber::render('blog/blog-single.twig', $context); diff --git a/wp-content/themes/cosmopet/modules/blog/module-controller.php b/wp-content/themes/cosmopet/modules/blog/module-controller.php index cc5f29a..f2629c9 100644 --- a/wp-content/themes/cosmopet/modules/blog/module-controller.php +++ b/wp-content/themes/cosmopet/modules/blog/module-controller.php @@ -2,17 +2,7 @@ class BlogPost extends \Timber\Post { - /** - * Estimates time required to read a post. - * - * The words per minute are based on the English language, which e.g. is much - * faster than German or French. - * - * @link https://www.irisreading.com/average-reading-speed-in-various-languages/ - * - * @return string - */ - + public function reading_time() { $symb_per_minute = 2280; @@ -20,7 +10,6 @@ class BlogPost extends \Timber\Post $symb = strlen(wp_strip_all_tags($this->content())); $minutes = round($symb / $symb_per_minute); - /* translators: %s: Time duration in minute or minutes. */ return sprintf(_n('%s ' . pll__('мин.'), '%s ' . pll__('мин.'), $minutes), (int) $minutes); } public function get_author_name() @@ -35,6 +24,19 @@ class BlogPost extends \Timber\Post $id = get_field('post_author', $this->ID); return get_the_post_thumbnail_url( $id, 'thumbnail' ); } + public function get_author_link() + { + $id = get_field('post_author', $this->ID); + if ($id) { + return get_permalink($id); + } + return false; + } + + public function get_comments_number() + { + return get_comments_number($this->ID); + } } add_filter('timber/post/classmap', function ($classmap) { @@ -43,4 +45,43 @@ add_filter('timber/post/classmap', function ($classmap) { ]; return array_merge($classmap, $custom_classmap); -}); \ No newline at end of file +}); + +function enable_comments_for_posts() { + + update_option('default_comment_status', 'open'); + + $posts = get_posts([ + 'post_type' => 'post', + 'numberposts' => -1, + 'post_status' => 'publish' + ]); + + foreach ($posts as $post) { + if (!comments_open($post->ID)) { + + update_post_meta($post->ID, 'comment_status', 'open'); + } + } +} +add_action('after_setup_theme', 'enable_comments_for_posts'); + +function enqueue_comment_scripts() { + if (is_singular() && comments_open()) { + + wp_enqueue_script('comment-reply'); + + wp_enqueue_script( + 'blog-comments-js', + get_template_directory_uri() . '/modules/blog/assets/js/comments.js', + array('jquery', 'comment-reply'), + filemtime(get_template_directory() . '/modules/blog/assets/js/comments.js'), + true + ); + + wp_localize_script('blog-comments-js', 'ajax_object', array( + 'ajax_url' => admin_url('admin-ajax.php') + )); + } +} +add_action('wp_enqueue_scripts', 'enqueue_comment_scripts'); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/forms/components/discount/assets/css/discount-form.css b/wp-content/themes/cosmopet/modules/forms/components/discount/assets/css/discount-form.css new file mode 100644 index 0000000..568a6d4 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/forms/components/discount/assets/css/discount-form.css @@ -0,0 +1,4004 @@ + + +/* .sellers_card .sellers_card-img { + width: auto!important; + height: 330px; +} */ + + +/* Home start */ +.home{ + position: relative; + /* GP | fix */ + background: var(--radial); +} +.home .container{ + padding: 157px 30px 245px; + position: relative; +} +@media (min-width: 1281px){ + .home .container{ + + max-width: 1350px !important; + } + +} + +@media (min-width: 1600px){ + .home .container{ + + max-width: 1440px !important; + } + +} +.home .home_dog{ + position: absolute; + bottom: 200px; + right: 8px; + opacity: .5; + z-index: 0; +} +.home_block-dog{ + width: 100%; + display: none; + margin: 0 auto; + opacity: .5; +} +.home .home_line2, +.home .home_line{ + position: absolute; + top: 70px; + left: 0; + width: 100%; + z-index: 1; + scale: 1.01; +} +.home .home_line2{ + display: none; + /* top: 37px; + left: -24px; */ + left: -2%; + top: 7%; + width: 108%; + z-index: 0; +} +.home .home_block{ + position: relative; + z-index: 1; + display: flex; + flex-direction: column; + gap: 32px; +} +.home_block .home_title{ + font-size: 82px; + line-height: 98.4px; + color: var(--creme-white, #F4F1F0); + text-transform: uppercase; +} +/* Home end */ + +/* Abour start */ +.about{ + box-shadow: 6px 9px 20px 0px #00000026; + background: var(--creme-white, #F4F1F0); + border-radius: 60px; + position: relative; + z-index: 2; + margin-top: -114px; + padding: 46px 0px 97px; +} +.about .about_block{ + display: flex; + flex-direction: column; + gap: 0; +} +.about .about_info-wrap{ + display: flex; + align-items: center; + gap: 70px; +} +.about_block .about_info{ + display: flex; + flex-direction: column; + gap: 25px; +} +.about_info-wrap .about_img{ + width: 40%; +} +.about_img .entoprotein-img{ + display: none; +} +.about_info-wrap .about_img img{ + width: 100%; + height: 720px; +} + +.about_info .about_title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + color: var(--grey-black, #121212); + text-transform: uppercase; +} +.about_info .about_text{ + font-size: 24px; + line-height: 28.8px; + letter-spacing: -0.01em; + color: var(--grey-black, #121212); +} + + +.about_block .about_cards{ + display: grid; + grid-template-columns: 31.5% 31.5% 31.5%; + gap: 58px 26px; +} +.about_cards .about_card{ + display: flex; + flex-direction: column; + gap: 24px; +} +.about_card .about_card-gif{ + width: 168px; + height: 168px; +} + +.about_card .about_card-info{ + display: flex; + flex-direction: column; + gap: 20px; +} +.about_card .about_card-title{ + font-size: 24px; + font-weight: 700; + line-height: 28.8px; + color: var(--grey-black, #121212); + text-transform: uppercase; +} +.about_card .about_card-text{ + font-size: 20px; + line-height: 24px; + color: var(--grey-black, #121212); + max-width: 278px; +} +.about_cards .about_company{ + position: relative; + padding: 25px 12px 30px 30px; + background: #F4F1F0; + border-radius: 60px; + display: flex; + flex-direction: column; + gap: 16px; +} +.about_cards .about_company::after{ + content: ''; + display: block; + position: absolute; + width: calc(100% + 4px); + height: calc(100% + 4px); + background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); + border-radius: 60px; + top: -2px; + left: -2px; + z-index: -1; +} +.about_company .about_company-text{ + font-size: 20px; + line-height: 24px; + font-weight: 500; + color: var(--grey-black, #121212); +} +.about_company .about_company-logo{ + display: grid; + grid-template-columns: 29% 65%; + gap: 20px 10px; +} +.about_company .about_company-logo img{ + width: 100%; +} +.about_company .about_company-logo img:nth-child(4){ + height: 80px; +} + + +.about_slider{ + padding-top: 110px; +} +.about_slider .slider-container { + position: relative; + /* max-width: 636px; */ + height: 300px; + display: flex; + justify-content: center; + align-items: center; + margin: 0 auto; +} + +.about_slider .slide { + position: relative; + background: #FFF; + border-radius: 60px; + /* width: 429px; + height: 546px; */ + display: flex; + flex-direction: column; + align-items: center; + gap: 45px; + padding: 35px 50px 25px 50px; + opacity: 1; + z-index: 1; +} +.about_slider .carousel .carousel-item{ + width: 429px; + height: 546px; + padding: 35px 50px 25px 50px; + padding: 50px 53px; + display: flex; + flex-direction: column; + align-items: center; + justify-content: center; + /* background: var(--creme-white, #F4F1F0); */ + background: #ffffff30; + backdrop-filter: blur(6px); + z-index: 1; + box-shadow: -2px 5px 22.9px 0px rgba(0, 0, 0, 0.25); +} + +.about_slider .carousel .carousel-item.active { + backdrop-filter: blur(6px); + z-index: 3; +} +.about_slider .carousel .carousel-item::after { + content: ''; + background-image: url(../img/border.png); + background-size: cover; + /* background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); */ + display: block; + position: absolute; + width: calc(100% + 4px); + height: calc(100% + 4px); + border-radius: 60px; + top: -2px; + left: -2px; + z-index: -2; + transform: translateZ(-1px); +} +.about_slider .carousel .carousel-item img{ + width: auto; +} + +.about_slider .slide_info{ + display: flex; + flex-direction: column; + gap: 15px; +} +.about_slider .slide--prev, +.about_slider .slide--next{ + z-index: 2; + opacity: 0.75; +} + +.about_slider .prev, .about_slider .next { + position: absolute; + top: 50%; + transform: translateY(-50%); + cursor: pointer; + z-index: 99; + background-color: unset; +} + +.about_slider .prev { + left: 29vw; +} + +.about_slider .next { + right: 29vw; +} + +.about_slider .slide_title{ + text-transform: uppercase; + font-size: 24px; + font-weight: 700; + line-height: 28.8px; + color: var(--grey-black, #121212); +} +.about_slider .slide_text{ + font-size: 20px; + font-weight: 500; + line-height: 24px; + color: var(--grey-black, #121212); +} +/* About end */ + +.section_wrap{ + margin-top: -70px; + padding: 178px 0 90px; + /* GP | fix */ + +} +/* Sellers start */ +.sellers{ + padding-bottom: 113px; + +} +.sellers .seller_block{ + display: flex; + flex-direction: column; +} +.seller_block .sellers_top{ + display: flex; + align-items: center; + justify-content: space-between; + gap: 30px; + margin-bottom: 34px; +} +.sellers_top .sellers_title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + color: var(--creme-white, #F4F1F0); + text-transform: uppercase; +} + +.sellers_slider .swiper{ + /* padding-left: 10%; + padding-right: 20px; */ + display: flex; + align-items: center; + /* width: 1000px; */ + height: 540px; + margin: auto; + overflow: hidden; +} +.seller_name { + text-transform:lowercase; + color:var(--grey-black, #121212); + font-size: 20px; + font-weight: 400; + line-height: 24px; + text-align: left; + /* min-width: 280px; */ +} +.seller_price { +font-size: 20px; +font-weight: bold; +line-height: 30px; +text-align: left; +margin-bottom: 8px; +margin-top: 8px; +} + +.seller_full { + display: flex; + flex-direction: row; + justify-content: start; + margin-top: 48px; +} +.seller_full-link { +color:#121212; +font-size: 20px; +font-weight: bold; +line-height: 24px; +text-align: left; +text-decoration: none; +padding: 0px 0px 4px 0px; +gap: 8px; +border-bottom: 2px solid var(--interface-main_black, rgba(18, 18, 18, 1)) +} +.swiper .swiper-wrapper{ + display: flex; + height: unset; +} +.sellers .sellers_card{ + min-height: 490px; + display: flex; + flex-direction: column; + justify-content: space-between; + gap: 11px; + align-items: center; + padding: 16px; + /* border: 2px solid var(--creme-white, #F4F1F0); */ + border-radius: 24px; + background: rgba(255, 255, 255, 0.5); +} + +.sellers_card .sellers_card-text{ + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + color: var(--grey-black, #121212); + +} +/* Sellers end */ + + +/* Reviews start */ +.reviews{ + position: relative; + padding: 112px 0px 56px; + background: var(--creme-white, #F4F1F0); + border-radius: 60px 60px 0 0; +} +.reviews .reviews_person{ + position: absolute; + right: -80px; + top: 0; +} +.reviews_person-mob{ + display: none; +} +.reviews .reviews_title{ + color: var(--grey-black, #121212); + font-family: "Craftwork Grotest"; + font-size: 79px; + font-style: normal; + font-weight: 700; + line-height: normal; + text-transform: uppercase; + position: relative; + z-index: 1; +} +.reviews .reviews_block{ + margin-top: 35px; +} +.reviews_block .reviews_items{ + position: relative; + z-index: 1; + display: flex; + flex-wrap: wrap; + gap: 23px; + align-items: center; +} + +.reviews_items .reviews_item{ + position: relative; + display: flex; + flex-direction: column; + gap: 7px; + background: #F4F1F0; + padding: 23px; + border-radius: 60px; + width: 100%; + height: fit-content; + z-index: 1; +} +/* Пустой блок, чтоб на десктопе в первой строке справой стороны не загораживать картинку */ +.reviews_items .reviews_item.reviews_item--empty{ + background: none; +} +@media screen and (max-width: 480px) { + .reviews_items .reviews_item.reviews_item--empty { + display: none; + } +} + +.reviews_item .reviews_item-top{ + display: flex; + align-items: center; + gap: 8px; +} +.reviews_item .reviews_item-top img{ + width: 78px; +} +.reviews_item .reviews_item-top b{ + text-transform: uppercase; + display: block; + font-size: 24px; + font-weight: 700; + line-height: 28.8px; + color: var(--grey-black, #121212); +} +.reviews_item .reviews_item-top span{ + margin: 14px 0; + width: 100%; + display: block; + font-size: 12px; + font-weight: 500; + line-height: 14.4px; + color: var(--grey-black, #121212); +} +.reviews_item .reviews_item-text{ + font-size: 20px; + font-weight: 500; + line-height: 24px; + color: var(--grey-black, #121212); +} +.reviews_items .reviews_item1, +.reviews_items .reviews_item6{ + position: relative; + /* transform: rotate(-2.35deg); */ + transform-style: preserve-3d; +} +/* GP | fix */ +.reviews_items .reviews_item1::after, +.reviews_items .reviews_item6::after{ + content: ''; + display: block; + position: absolute; + width: calc(100% + 4px); + height: calc(100% + 4px); + background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); + border-radius: 60px; + top: -2px; + left: -2px; + z-index: -1; + transform: translateZ(-1px); +} + +.reviews_items .reviews_item6{ + transform: rotate(-7deg); +} + +.reviews_items .reviews_item3{ + transform: rotate(-5deg); +} +.reviews_items .reviews_item5, +.reviews_items .reviews_item4{ + background: radial-gradient(1073.72% 191.15% at -371.63% -32.65%, #0F5881 0%, #1EA49C 36.98%, #76CE75 66.67%, #ECF39F 91.15%); + /* transform: rotate(4deg); + margin-top: 25px; */ +} + +.reviews_items .reviews_item2{ + background: var(--grey-black, #121212); + /* transform: rotate(5deg); + margin: 30px 0 0 20px; */ +} +.reviews_items .reviews_item4{ + /* transform: rotate(8deg); + margin: -30px 0 0 20%; */ +} + +.reviews_item2 .reviews_item-top b, +.reviews_item2 .reviews_item-top span, +.reviews_item2 .reviews_item-text, +.reviews_item3 .reviews_item-top b, +.reviews_item3 .reviews_item-top span, +.reviews_item3 .reviews_item-text, +.reviews_item4 .reviews_item-top b, +.reviews_item4 .reviews_item-top span, +.reviews_item4 .reviews_item-text, +.reviews_item5 .reviews_item-top b, +.reviews_item5 .reviews_item-top span, +.reviews_item5 .reviews_item-text{ + color: #F4F1F0; +} +.reviews_item2 .reviews_item-text, +.reviews_item3 .reviews_item-text, +.reviews_item4 .reviews_item-text, +.reviews_item5 .reviews_item-text{ + font-weight: 400; +} + + +/* Reviews end */ + +/* About us start */ +.about_us{ + padding-bottom: 54px; + background-color: #F4F1F0; + margin-top: -1px; +} +.about_us .about_us-title{ + font-size: 82px; + line-height: 98.4px; + text-transform: uppercase; + color: var(--grey-black, #121212); +} +.about_us .about_us-block{ + display: flex; + flex-direction: column; + gap: 15px; + margin-top: 25px; +} +.about_us-block .about_us-cards{ + display: grid; + align-items: start; + grid-template-columns: 59% 39.2%; + gap: 15px; +} +.about_us-block .about_us-card{ + position: relative; + border-radius: 60px; + overflow: hidden; + height: 324px; + width: 100%; + overflow: unset; +} +.about_us-block .about_us-card::after{ + content: ''; + display: block; + position: absolute; + width: calc(100% + 4px); + height: calc(100% + 4px); + background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); + border-radius: 60px; + top: -2px; + left: -2px; + z-index: 0; +} +.about_us-card .about_us-card-img{ + border-radius: 60px; + height: 100%; + width: 100%; + object-fit: cover; + position: relative; + z-index: 1; +} +.about_us-card .card_date{ + z-index: 1; + position: absolute; + top: 27px; + right: 35px; + background: #FFFFFF; + border-radius: 62px; + padding: 5px 15px 4px 17px; + font-size: 24px; + font-weight: 400; + line-height: 28.8px; + color: var(--grey-black, #121212); +} +/* GP | fix */ + + +.about_us-card .about_us-card-info { + position: absolute; + padding: 10% 33px 21px ; + width: 100%; + z-index: 1; + display: flex; + flex-direction: column; + gap: 14px; + left: 0px; + bottom: 0; + border-radius: 0 0 60px 60px; + background: linear-gradient(0deg, #F4F1F0 45%, rgba(244, 241, 240, 0) 100%); +} + +.about_us-card-info.card-info--half-gradient { + background: unset; +} + +.about_us-card .about_us-card-info h2{ + /* max-width: 440px; */ + font-size: 24px; + line-height: 32px; + text-transform: uppercase; + color: var(--grey-black, #121212); +} +.about_us-card .about_us-card-info span{ + display: block; + font-weight: 400; + +} +.about_us-card .about_us-card-info span a{ + text-decoration: underline; + font-size: 24px; + line-height: 28.8px; + color: var(--grey-black, #121212); +} +/* About us end */ + +/* Truth start */ +.truth{ + border-radius: 0 0 60px 60px; + background: var(--creme-white, #F4F1F0); + padding-bottom: 119px; + margin-top: -1px; +} +.truth .truth_top{ + position: relative; + display: flex; + align-items: center; + justify-content: space-between; +} +.truth .truth_title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + text-align: end; + text-transform: uppercase; + width: 723px; +} +.truth .truth_title span{ + color: #76CE75; + +} +.truth_top .gift_img{ + margin-left: -180px; +} +.truth_top .gift_line-img{ + position: absolute; + display: none; + bottom: 150px; + right: 0; + width: 245px; +} +.truth_content { + position: relative; + display: none; +} + +.truth_content::after{ + content: ''; + display: block; + position: absolute; + width: calc(100% + 4px); + height: calc(100% + 4px); + background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); + border-radius: 60px; + top: -2px; + left: -2px; + z-index: 0; +} +.truth_content.active { + display: block; +} +.truth .truth_block{ + position: relative; + z-index: 1; + display: flex; + flex-direction: column; + width: 100%; + height: 480px; + overflow: hidden; + background: var(--creme-white, #F4F1F0); + border-radius: 60px; + box-shadow: 0px 3px 13.5px 0px #00000040; + padding: 25px 34px 0px 63px; +} +.truth .truth_success, +.truth .truth_error { + display: none; +} +.truth .truth_success.show, +.truth .truth_error.show { + display: flex; +} + +.truth_block .truth_line{ + display: flex; + align-items: center; + justify-content: center; + gap: 24px; + margin-bottom: 24px; +} +.truth_block .truth_line span{ + border: 1px solid var(--grey-black, #121212); + opacity: .6; + width: 73px; + border-radius: 10px; +} +.truth_block .truth_line span.active{ + opacity: 1; +} +.truth_block .truth_block-title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + color: var(--grey-black, #121212); + margin-bottom: 33px; + text-transform: uppercase; +} +.truth_content-end .truth_block-title, +.truth_success .truth_block-title{ + background: -webkit-radial-gradient(#0F5881 0%, #1EA49C 36.98%, #76CE75 66.67%, #ECF39F 91.15%); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} +.truth_error .truth_block-title{ + background: -webkit-radial-gradient(#F21E6A 0%, #FF6543 112.38%); + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} +.truth_block .truth_block-text{ + position: relative; + z-index: 1; + display: flex; + align-items: start; + gap: 26px; +} +.truth_block .truth_end-text{ + display: flex; + flex-direction: column; + gap: 21px; +} +.truth_block .truth_block-text p{ + font-size: 24px; + font-weight: 700; + line-height: 28.8px; + max-width: 559px; +} +.truth_block .truth_block-text p span{ + font-weight: 500; +} +.truth_default .truth_block-text p{ + text-transform: uppercase; +} +.truth_error .truth_block-text p, +.truth_success .truth_block-text p { + max-width: 592px; + font-size: 20px; + line-height: 24px; + font-weight: 500; +} +.truth_block .truth_info{ + position: absolute; + width: 91%; + bottom: 0; + display: flex; + align-items: end; + justify-content: space-between; + margin-top: -100px; + z-index: 0; +} +.truth_content-end .truth_info{ + display: flex; + align-items: center; + justify-content: end; +} +.truth_block .truth_links{ + display: flex; + align-items: center; + gap: 15px; + padding-bottom: 56px; +} +.truth_error .truth_links, +.truth_success .truth_links{ + gap: 20px; +} +.truth_block .truth_result{ + display: flex; + align-items: center; + gap: 23px; +} +.truth_block .truth_result img{ + width: 100%; +} +.truth_block .truth_link{ + width: 141px; + height: 50px; + display: flex; + align-items: center; + justify-content: center; + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + text-align: center; + color: var(--grey-black, #121212); + border: 2px solid var(--grey-black, #121212); + border-radius: 48px; +} + +.truth_content-end .truth_info img{ + margin-right: -34px; +} +.truth_content-end .truth_block .truth_link{ + width: 221px; +} + +.truth_content-end .truth_xn{ + position: relative; + width: 270px; + height: 158px; + background-image: url(../img/xn-border.svg); + background-repeat: no-repeat; + background-size: 100% 100%; + display: flex; + align-items: center; + justify-content: center; +} + +.truth_points { + font-size: 450%; + font-weight: 700; +} + +/* Truth end */ + + +/* Blog start */ +.blog{ + padding-top: 89px; +} +.blog .blog_block{ + display: flex; + flex-direction: column; + gap: 15px; +} +.blog_block .blog_top{ + display: flex; + align-items: center; + justify-content: space-between; + gap: 30px; +} +.blog_block .blog_title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + color: var(--creme-white, #F4F1F0); + text-transform: uppercase; +} +.blog_block .blog_text{ + font-size: 24px; + line-height: 28.8px; + color: var(--creme-white, #F4F1F0); +} +.blog .blog_slider{ + margin-top: 30px; +} +.blog_slider .swiper{ + padding-left: 9%; + padding-right: 20px; +} +.blog_slider .blog_card { + display: flex; + flex-direction: column; + border-radius: 60px; + transition: .3s ease all; + height: auto; +} +.blog_slider .blog_card:hover{ + border-color: #121212; + overflow: initial; +} + +/* .blog_slider .blog_card:hover .card-line-img{ + opacity: 1; +} */ + +.blog_slider .blog_card:hover .blog_card-text, +.blog_slider .blog_card:hover .blog_card-title{ + color: #F4F1F0; +} + +.blog_card .blog_card-img{ + object-fit: cover; + border: 2px solid var(--creme-white, #F4F1F0); + border-width: 2px 2px 0 2px; + width: 100%; + height: 40%; + border-radius: 60px 60px 0 0; +} +.blog_card .card-line-img{ + opacity: 0; + transition: .3s ease all; +} +.blog_card .blog_card-info-wrap{ + border: 2px solid var(--creme-white, #F4F1F0); + width: 100%; + height: 60%; + display: flex; + background: linear-gradient(355.81deg, #F4F1F0 5.04%, rgba(244, 241, 240, 0.3) 87.4%); + border-radius: 0 0 60px 60px; + padding: 25px 25px 30px 30px; +} +.blog_slider .blog_card:hover .blog_card-info-wrap{ + background: var(--grey-black, #121212); + /* padding-right: 15px; */ +} +.blog_card .blog_card-info{ + display: flex; + flex-direction: column; + margin-top: -2px; + gap: 16px; + +} +.blog_card .blog_card-title{ + /* font-size: 36px; */ + font-size: 2.1vw; + font-weight: 700; + line-height: 43.2px; + color: var(--grey-black, #121212); + text-transform: uppercase; + transition: .3s ease all; +} +.blog_card .blog_card-text{ + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + color: var(--grey-black, #121212); + transition: .3s ease all; +} +/* Blog end */ + +.marketplace{ + margin-top: 5rem; +} +/* Discount start */ +.discount{ + padding-top: 50px; + padding-bottom: 50px; +} +.discount .discount_block{ + display: flex; + flex-direction: column; +} +.discount .discount_top{ + position: relative; + margin-bottom: 50px; +} +.discount_top .discount_title{ + font-size: 82px; + font-weight: 700; + line-height: 98.4px; + color: var(--creme-white, #F4F1F0); + text-transform: uppercase; +} +.discount_top .discount_top-imgs{ + position: absolute; + top: 55px; + right: -80px; +} +.discount_block .discount_form{ + position: relative; + z-index: 1; + display: flex; + align-items: center; + gap: 16px; + margin-bottom: 6px; +} +.discount_form .discount_form-btn { + background: inherit; + min-height: unset; +} +.discount_form .discount_form-btn:hover{ + background: #121212; + border-color: #121212; + color: #3ab18f; +} +.discount_form .discount_form-inp{ + width: 280px; + height: 50px; + border: 2px solid var(--creme-white, #F4F1F0); + padding: 10px 18px; + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + color: var(--creme-white, #F4F1F0); + border-radius: 28px; + opacity: .6; +} +.discount_form .discount_form-inp::placeholder{ + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + color: var(--creme-white, #F4F1F0); +} +.discount_form .discount_form-btn { + text-transform: lowercase; +} +.discount_block .discount_form-text{ + font-size: 14px; + line-height: 16.8px; + color: var(--creme-white, #F4F1F0); + opacity: .6; + max-width: 778px; + margin-bottom: 27px; +} +.discount_block .discount_text{ + font-size: 20px; + line-height: 24px; + color: var(--creme-white, #F4F1F0); +} + +.discount_block .discount_cosmodog{ + position: relative; + width: 100%; + height: 626px; + border-radius: 60px; + border: 2px solid var(--creme-white, #F4F1F0); + display: flex; + align-items: end; + justify-content: center; + overflow: hidden; + cursor: pointer; +} +.discount_cosmodog .discount_cosmodog-img{ + + width: 100%; + height: 100%; + object-fit: cover; + +} + +.discount_cosmodog__slider{ + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; +} +.discount_cosmodog .discount_cosmodog-img.active{ + opacity: 1; +} +.discount_cosmodog:hover .discount_cosmodog-img:nth-child(2) { + opacity: 1; +} +.discount_cosmodog .discount_cosmodog_info{ + position: relative; + z-index: 1; + padding: 33px; + display: flex; + flex-direction: column; + align-items: center; + justify-content: end; + background: linear-gradient(0deg, #F4F1F0 56%, rgba(244, 241, 240, 0) 100%); + width: 100%; + height: 219px; +} +.discount_cosmodog .discount_cosmodog-title{ + font-size: 40px; + font-weight: 700; + line-height: 48px; + text-align: center; + color: var(--grey-black, #121212); + text-transform: uppercase; +} +.discount_cosmodog .discount_cosmodog-text{ + font-size: 24px; + font-weight: 500; + line-height: 28.8px; + text-align: center; +} + +/* Discount end */ + +.gp_tags { + border: 1px solid #121212; + border-radius: 48px; + padding:3px 6px 3px 6px; + margin-right: 6px; + margin-bottom: 6px; + font-size: 16px; + line-height: 16px; + height: 27px; + text-transform: lowercase; +} +.gp_tags:last-child { + margin-right: 0; +} +.tags_block { + display: flex; + flex-direction: row; + justify-content:start; + flex-wrap: wrap; + width: 100%; +} + +.seller_buy { + text-transform: capitalize; + width: 100%; + height: 48px; + padding: 12px 24px 12px 24px; + gap: 8px; + border-radius: 20px; + color:#fff; + background: var(--interface-main_black, #121212); +} +.seller_link { + width: 100%; +} +.truth-form{ + display: flex; + gap: 10px; +} +.truth-form button{ + flex-shrink: 0; +} +input.truth-input{ + width: 200px; + height: 50px; + border-color: #121212 !important; + border-radius: 48px; + border: 2px solid #121212; + flex-shrink: 1; + margin-right: 12px; + padding: 20px; + font-size: 18px; +} +@media (max-width: 776px) { + .truth-form{ + flex-direction: column; + margin-bottom: 30px; +} +.truth-form button{ + width: 100%; + text-align: center; + justify-content: center; +} +input.truth-input{ + width: 100%; +} +} + +.smi-card-wrapper{ + border-radius: 60px; + background: linear-gradient(21.69deg, #F44242 23.69%, #569EF0 66.57%); + border-radius: 60px; + padding: 2px; + width: 100%; + height: 484px; +} +.smiSlider{ + margin-top: 3rem; +} +.smi-card{ + display: flex; + flex-direction: column; + justify-content: flex-end; + width: 100%; + height: 480px; + border-radius: 60px; + position: relative; + overflow: hidden; + padding: 28px 35px; + color: #121212; + +} +.smi-card::before{ + background: linear-gradient(to top, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 100%); +content: ''; +height: 100%; +width: 100%; +position: absolute; +bottom: 0; +left: 0; +z-index: 2; +} +.smi-card-img{ + position: absolute; + top: 0; + left: 0; + width: 100%; + height: 100%; + object-fit: cover; +} +.smi-card-date, .smi-card-title, .smi-card-label{ + position: relative; + z-index: 2; +} +.smi-card-label{ + display: flex; + border: 1px solid #121212; + border-radius: 28px; + padding: 4px 15px; + align-items: center; + font-weight: 500; + font-size: 16px; + gap: 6px; + background-color: #fff; + width: max-content; +} +.smi-card-label p{ + margin-bottom: 0; +} +.smi-card-title{ + font-weight: 700; +font-size: 22px; +text-transform: uppercase; line-height: 120%; +margin-bottom: 7px; +margin-top: 10px; +} +.smi-card-date{ + font-weight: 500; +font-size: 12px; +} +.smiSlider.swiper{ + overflow: visible; + } + .about_us{ + width: 100%; + overflow: hidden; + } + .smi-card-label img{ + max-height: 25px; + width: auto; + } + .smi-card-label{ + height: 35px; + } +@media (max-width: 640px) { + .smi-card{ + padding: 16px; + height: 420px; + border-radius: 30px; + } + .smi-card-title{ + font-size: 18px; + } + .smi-card-wrapper{ + height: 424px; + border-radius: 30px; + } + +} + +.slider-arrows{ + position: relative; + /* top: 50%; + left: 50%; + transform: translate(-52.5%, -50%); + width: 78%; */ + display: flex; + justify-content: space-between; + z-index: 40; + pointer-events: none; +} +@media (max-width: 640px) { + .slider-arrows{ + display: none; + } + .sellers_slider .swiper{ +width: 330px; + } +} +.blogSlider .slider-arrows{ + position: absolute; + top: 50%; + left: 50%; + transform: translate(-55%, -50%); + width: 76.5%; + display: flex; + justify-content: space-between; + z-index: 40; + pointer-events: none; +} +.smiSlider .slider-arrows { + position: absolute; + top: 50%; + left: 50%; + transform: translate(-47%, -50%); + width: 112%; + display: flex; + justify-content: space-between; + z-index: 40; + pointer-events: none; + +} +.slider-arrow{ + background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg width='56' height='56' viewBox='0 0 56 56' fill='none' xmlns='http://www.w3.org/2000/svg'%3e%3crect x='0.5' y='0.5' width='55' height='55' rx='19.5' fill='white'/%3e%3crect x='0.5' y='0.5' width='55' height='55' rx='19.5' stroke='%23121212'/%3e%3cpath d='M37 28.3633H20.5' stroke='%23121212' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3cpath d='M37 28.3633L30.636 34.7272' stroke='%23121212' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3cpath d='M37 28.3633L30.636 21.9993' stroke='%23121212' stroke-width='1.5' stroke-linecap='round' stroke-linejoin='round'/%3e%3c/svg%3e "); + height: 56px; + width: 56px; + background-size: contain; + pointer-events: all; + +} +.slider-arrow[disabled]{ + visibility: none; +} +.slider-arrow-prev{ + transform: scaleX(-1); + margin-right: 24px; +} + +.header-lang{ + font-size: 16px; + font-weight: 500; + line-height: normal; + text-transform: uppercase; + color: var(--creme-white); + border-radius: 45px; + border: 1px solid var(--creme-white); + opacity: 0.6; + appearance: none; + background-color: transparent; + background-image: url(../img/i-arr_down.svg); + background-position: center right 10px; + background-repeat: no-repeat; + background-size: 16px; + padding: 11px 36px 11px 23px; + cursor: pointer; + outline: none; + position: relative; + z-index: 10; + } + + .header-lang ul{ + border: 1px solid #f3f1f0; + border-radius: 20px; + width: 100%; + padding-top: 11px; + padding-bottom: 11px; + padding-left: 23px; + padding-right: 23px; + background: #57da7d; + text-align: center; + opacity: 1; + left: 0; + bottom: -30px; + transform: translateY(100%); + + position: absolute; + display: none; + } + + .header-lang ul li a{ + font-weight: 500; + font-size: 16px; + text-transform: uppercase; + color: var(--creme-white); + } + + .category-back{ + width: 124px; + color: #121212; +height: 28px;border: 1px solid #121212; +border-radius: 65px; +background-color: transparent; +font-weight: 500; +font-size: 16px; +display: flex; +align-items:center; +justify-content: center; +margin-bottom:1.5rem; +margin-top: 14px; +} +.category-back::before{ + background-image: url("data:image/svg+xml,%3Csvg width='10' height='15' viewBox='0 0 10 15' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M9 1L2 7.5L9 14' stroke='%23121212' stroke-width='2' /%3E%3C/svg%3E"); + content: ''; + width: 10px; + height: 15px; + flex-shrink: 0; + margin-right: 8px; +} +.category-back:hover{ + color: #121212; +} + +.main-page-wrapper{ + margin-top: 0 !important; +} + +.header_icon{ + flex-shrink: 0; +} + +[class*="wd-section-stretch"] { + position: relative; + min-width: 100vw !important; + width: 100vw; + left: calc(50% - 50vw)!important; +} + +.btn{ + padding: 0 30px; +} + +.header_icon{ + position: relative; +} + +.basket-btn__counter{ + position: absolute; + top: 0; + right: 0; + border-radius: 100%; +background: #76ce75; +height: 17px; +width: 17px; +font-weight: 700; +font-size: 10px; +text-align: center; +color: var(--creme-white); +display: flex; +align-items: center; +justify-content: center; +} + + +@media (max-width: 575px) { + .wpcf7-form-control-wrap{ + width: 100%; + } +} + +.seller_bt{ + display: flex; + align-items: center; + gap: 12px; +} + +/* discount sale */ + +.discount__sale { + padding: 69px 0 80px; + border-radius: 60px; + background: var(--creme-white, #F4F1F0); + box-shadow: 6px 9px 20px 0px rgba(0, 0, 0, 0.15); +} + +.discount__sale .discount_title { + color: var(--interface-main_black, #121212); + font-family: "Craftwork Grotest"; + font-size: 82px; + font-style: normal; + font-weight: 700; + line-height: normal; + text-transform: uppercase; +} + +.discount__sale .discount_title span { + background: var(--Accent-1, radial-gradient(200.43% 141.42% at 100% 0%, #76CE75 90%, #BBE38D 100%)); + background-clip: text; + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} + +.discount__sale .discount_form { + display: flex; +} + +.discount__sale .discount_form .discount_form-inp { + color: var(--interface-main_black, #121212); + border: 2px solid var(--interface-main_black, #121212); +} + +.discount__sale .discount_form .discount_form-btn { + color: var(--interface-main_black, #121212); + border: 2px solid var(--interface-main_black, #121212); +} + +.discount__sale .discount_form .discount_form-btn:hover { + color: #FFF; +} + +.discount__sale .discount_form-text { + color: var(--interface-main_black, #121212); + font-family: "Craftwork Grotest"; + font-size: 14px; + font-style: normal; + font-weight: 500; + line-height: normal; + opacity: .6; + max-width: 750px; + margin-top: 6px; +} + +.discount__sale .discount_text { + margin-top: 27px; + color: var(--interface-main_black, #121212); + font-family: "Craftwork Grotest"; + font-size: 20px; + font-style: normal; + font-weight: 500; + line-height: normal; +} + +.discount__sale .discount_form .discount_form-inp::placeholder { + color: var(--interface-main_black, #121212); +} + +@media screen and (max-width: 576px) { + .discount__sale { + padding: 37px 0; + } + + .dicsount__body { + display: flex; + flex-direction: column; + margin-top: 26%; + } + + .discount__sale .discount_form { + flex-direction: column; + gap: 21px; + } + + .discount__sale .discount_top .discount_top-imgs .dicount_dog-img { + height: 356.534px; + width: 100%; + object-fit: contain; + object-position: right; + } + + .discount__sale .dicsount__body > { + order: 2; + } + + .discount__sale .discount_text { + order: 1; + margin-top: 0; + font-size: 18px; + } + + .discount__sale .discount_form-text { + order: 3; + font-size: 12px; + margin-top: 20px; + } + + .discount__sale .wpcf7 { + order: 2; + margin-top: 30px; + } + + .discount__sale .discount_form .discount_form-btn, + .discount__sale .discount_form .discount_form-inp { + text-align: center; + padding: 10px 10px 11px 10px; + font-size: 24px; + height: 50px; + justify-content: center; + } + + .discount__sale .discount_form .discount_form-inp::placeholder { + font-size: 24px; + } + + .discount__sale .discount_top .discount_top-imgs { + transform: unset; + } + + .discount__sale .discount_top .discount_top-imgs { + margin-top: -24px; + right: 15px; + width: calc(100% + 30px); + margin-bottom: -20%; + } +} + +.blog_card-title { + font-size: 28px; + font-style: normal; + font-weight: 700; + line-height: 32px; +} + +.blog__card-btn { + margin-top: 24px; + color: #000; + font-family: "Craftwork Grotest"; + font-size: 12px; + font-style: normal; + font-weight: 500; + line-height: normal; + padding: 6px 15px 10px 15px; + max-width: max-content; + display: block; + margin-left: auto; + border-radius: 28px; + border: 1px solid #000; + background: var(--wh, #FFF); + transition: all .24s; +} + + +.blog_slider .blog_card:hover .blog__card-btn { + border-radius: 28px; + border: 1px solid var(--interface-main_white, #FFF); + background: transparent; + color: var(--interface-main_white, #FFF); + transition: all .24s; +} + +.blog__row { + display: flex; + justify-content: space-between; + align-items: center; +} + +.blog__row .blog_text { + max-width: 627px; +} + +.truth_top { + position: relative; +} + +.truth_top picture img { + width: 315.563px; + height: 308.2px; + position: absolute; + right: 0; + top: -110px; +} + +.truth .truth_title { + text-align: left; + width: 100%; + font-size: 74px; + font-style: normal; + font-weight: 700; + line-height: normal; + margin-bottom: 62px; +} + +.truth_block .truth_end-text strong { + font-weight: 900; +} + +.truth__end-promo { + color: var(--grey-black, #121212); + font-family: "Craftwork Grotest"; + font-size: 24px; + font-style: normal; + font-weight: 900; + line-height: normal; + text-transform: uppercase; +} + +.truth__end-btns { + margin-top: 10px; + display: flex; + gap: 12px; +} + +.truth__end-btn { + padding: 10px 10px 11px 10px; + font-family: "Craftwork Grotest"; + font-size: 24px; + font-style: normal; + font-weight: 500; + line-height: normal; + border-radius: 48px; + max-width: 210px; + width: 100%; + text-align: center; + transition: all .3s; + text-transform: none; +} + +.truth__end-btn.--white { + color: var(--grey-black, #121212); + border: 2px solid var(--grey-black, #121212); + background-color: transparent; +} + +.truth__end-btn.--white:hover { + background: #121212; + color: #FFF; + transition: all .3s; +} + +.truth__end-btn.--black { + background: var(--interface-main_black, #121212); + color: var(--interface-main_white, #FFF); + border: 2px solid transparent; +} + +.truth__end-btn.--black span { + position: relative; + padding-right: 16px; +} + +.truth__end-btn.--black span::after { + content: ''; + position: absolute; + right: 0; + top: 50%; + transform: translateY(-50%); + width: 13px; + height: 13px; + background-size: 100%; + background-repeat: no-repeat; + transition: all .3s; + background-position: center; + background-image: url('data:image/svg+xml,'); +} + +.truth__end-btn.--black:hover { + background: transparent; + color: #121212; + border-color: #000; + transition: all .3s; +} + +.truth__end-btn.--black:hover span::after { + transition: all .3s; + background-image: url('data:image/svg+xml,'); +} + +@media screen and (max-width: 576px) { + .truth_top picture img { + position: relative; + top: unset; + right: unset; + left: 0; + width: 294.209px; + height: 198.713px; + } + + .truth .truth_title { + text-align: right; + } + + .truth__end-btns { + flex-direction: column; + } + + .truth__end-btn { + max-width: 100%; + } + + .truth .truth_title { + margin-bottom: 0; + } +} + +.home__block { + max-width: 50%; +} + +.home__title { + color: var(--interface-background, #F2F2F2); + font-family: "Craftwork Grotest"; + font-size: 48px; + font-style: normal; + font-weight: 700; + line-height: 56px; /* 116.667% */ + text-transform: uppercase; +} + +@media (min-width: 1600px){ + .home__title { + + font-size: 64px; + line-height: 120%; + } +} +.home__subtitle { + color: var(--interface-background, #F2F2F2); + font-family: "Craftwork Grotest"; + margin-top: 32px; + font-size: 20px; + font-style: normal; + font-weight: 500; + line-height: 24px; /* 120% */ +} + +.home__btn { + border-radius: 20px; + background: var(--interface-main_white, #FFF); + padding: 12px 24px; + color: var(--interface-main_black, #121212); + font-family: "Craftwork Grotest"; + font-size: 20px; + font-style: normal; + font-weight: 600; + line-height: 24px; /* 120% */ + display: block; + margin-top: 32px; + max-width: 290px; + text-align: center; + width: 100%; + border: 2px solid transparent; +} + +.home__btn span { + position: relative; + padding-right: 20px; +} + +.home__btn span::after { + content: ''; + width: 13px; + height: 13px; + background-size: 100%; + background-repeat: no-repeat; + background-position: center; + position: absolute; + right: 0; + top: 50%; + transform: translateY(-50%); + background-image: url('data:image/svg+xml,'); +} + +.home__btn:hover { + border-color: #FFF; + background: transparent; + color: #FFF; +} + +.home__btn:hover span::after { + background-image: url('data:image/svg+xml,'); +} + +.home__pagination { + margin-top: 120px; +} + +.home__pagination .swiper-pagination-bullet { + width: 39.278px; + height: 6px; + border-radius: 54px; + opacity: 0.5; + background: var(--interface-main_white, #FFF); +} + +.home__pagination .swiper-pagination-bullet-active { + opacity: 1; +} + +.home__item img { + position: absolute; + right: -142px; + top: -110px; + height: auto; + width: 70%; + max-width: 600px; +} + +@media (min-width: 1420px) { + .home__item img { + position: absolute; + right: -142px; + top: -110px; + height: auto; + width: 70%; + max-width: 800px; + } +} + +.home__swiper, +.home__swiper .swiper-wrapper { + height: auto; +} + +.blog .blog_slider { + margin-top: 128px; +} + +.cosmopet-x { + padding: 36px 0 0 0; + width: 100%; + overflow: hidden; +} + +.cosmopet-x__swiper, +.cosmopet-x__swiper .swiper-wrapper { + height: auto; +} + +.cosmopet-x__title { + color: var(--creme-white, #F4F1F0); + font-family: "Craftwork Grotest"; + font-size: 82px; + font-style: normal; + font-weight: 700; + line-height: normal; + text-transform: uppercase; +} + +.cosmopet-x__swiper { + margin-top: 52px; + position: relative; +} + +.cosmopet-x__item { + position: relative; + width: 100%; + height: 484px; +} + +.cosmopet-x__item::before { + content: ''; + position: absolute; + left: 0; + top: 0; + height: 100%; + z-index: 1; + width: 100%; + border-radius: 60px; + border: 2px solid var(--creme-white, #F4F1F0); + background: linear-gradient(180deg, rgba(255, 255, 255, 0.83) 0%, rgba(255, 255, 255, 0.00) 25.17%, rgba(255, 255, 255, 0.00) 65%, rgba(255, 255, 255, 0.83) 80%); +} + +.cosmopet-x__bg { + position: absolute; + top: 0; + left: 0; + height: 100%; + width: 100%; + object-fit: cover; + object-position: center; + border-radius: 60px; +} + +.cosmopet-x__body { + position: absolute; + z-index: 2; + bottom: 0; + left: 0; + width: 100%; + padding: 36px 35px; +} + +.cosmopet-x__heading { + color: var(--grey-black, #121212); + font-family: "Craftwork Grotest"; + font-size: 22px; + font-style: normal; + font-weight: 700; + line-height: normal; + text-transform: uppercase; +} + +.cosmopet-x__btn { + display: block; + max-width: max-content; + margin-top: 7px; + color: #000; + font-family: "Craftwork Grotest"; + font-size: 12px; + font-style: normal; + font-weight: 500; + line-height: normal; + padding: 6px 15px 10px 15px; + border-radius: 28px; + border: 1px solid #000; + background: var(--wh, #FFF); +} + +.cosmopet-x__top { + position: absolute; + height: auto; + width: 60%; + top: 43px; + left: 50%; + transform: translateX(-50%); + z-index: 2; +} + +.cosmopet-x .slider-arrows { + top: 50%; + transform: translateY(-50%); + position: absolute; + width: 100%; +} + +.cosmopet-x .slider-arrows .cosmopet-prev { + left: -30px; +} + +.cosmopet-x .slider-arrows .cosmopet-next { + right: -30px; +} + +.slider-arrow { + background-image: url('data:image/svg+xml,')!important; +} + +.discount_top { + position: relative; +} + +.dicsount__body { + margin-top: 39px; +} + +.reviews_items .reviews_item { + flex: 0 0 calc(50% - 23px); + min-height: 334px; +} + +.reviews__left { + flex: 0 0 50%; + display: flex; + flex-direction: column; + gap: 23px; +} + +.reviews_item-top + span { + color: var(--creme-white, #F4F1F0); + font-family: "Craftwork Grotest"; + font-size: 12px; + font-style: normal; + font-weight: 500; + line-height: normal; +} + +.reviews_item1 .reviews_item-top + span { + color: var(--interface-main_black, #121212); +} + +.reviews .container { + position: relative; +} + +.truth { + padding-top: 180px; +} + +.blogosphere{ + padding-bottom: 6vh; +} + +.blogosphere__item { + position: relative; + /* width: 100%; */ + /* width: auto; + height: 33vh; */ + /* padding-bottom: 177.6061776061776%; */ + height: 60vh; + width: 36vh; +} + +.blogosphere__item .blogosphere__preview { + position: relative; + height: 60vh; + width: 36vh; + object-fit: cover; + /* height: 100%; + width: 100%; */ + /* position: absolute; + top: 0; + left: 0; + height: 100%; + width: 100%; + object-fit: cover; + object-position: center; */ + border-radius: 33.6px; + box-shadow: 0px 4px 14.4px 0px rgba(0, 0, 0, 0.33); +} + +.blogosphere__content { + position: absolute; + /* width: 25vw; */ + width: 100%; + padding: 10px 15px; + display: flex; + align-items: center; + gap: 10px; + z-index: 1; +} + +.blogosphere__avatar +{ + position: relative; + width: 39.2px; + height: 39.2px; + flex-shrink: 0; + box-shadow: unset; + border: 1.4px solid #FFF; + border-radius: 100%; + flex-shrink: 0; +} + +.blogosphere__name { + color: #FFF; + font-family: "Craftwork Grotest"; + font-size: 16.8px; + font-style: normal; + font-weight: 700; + line-height: 22.4px; /* 133.333% */ +} + +.blogosphere__swiper.swiper { + position: relative; +} + +.blogosphere__swiper .carousel .carousel-item{ + width: auto; + height: auto; +} + +.blogosphere__swiper .slider-arrows { + position: absolute; + top: 50%; + transform: translate(-50%, -50%); + max-width: 421px; + width: 100%; + left: 50%; + pointer-events: none; +} + +.blogosphere { + padding-top: 60px; +} + +.blogosphere__top { + display: flex; + align-items: center; + gap: 30px; +} + +.blogosphere__title { + background-size: 100%; + background-repeat: no-repeat; + background-position: center; + width: 692.514px; + height: 71.298px; + background-image: url('data:image/svg+xml,'); +} + +.blogosphere__circle { + flex-shrink: 0; +} + +.marketplace__swiper, .marketplace__swiper .swiper-wrapper { + height: auto; +} + +.marketplace__swiper .swiper-slide { + max-width: max-content; +} + +.marketplace__title { + color: var(--grey-black, #121212); + font-family: "Craftwork Grotest"; + font-size: 36px; + font-style: normal; + font-weight: 700; + line-height: 40px; /* 111.111% */ + text-transform: uppercase; +} + +.marketplace__swiper { + margin-top: 50px; + margin-left: -70px; + margin-right: -70px; +} + +.marketplace { + position: relative; +} + +.marketplace:after { + content: ''; + position: absolute; + right: 0; + bottom: 0; + width: 222px; + height: 671px; + background: linear-gradient(270deg, #F6F4F3 0%, rgba(242, 242, 242, 0.00) 100%); + z-index: 1; +} + +.blog_card .blog__card-wrapper .blog_card-img { + width: 100%; + height: 100%; + position: absolute; +} + +.blog__card-wrapper { + position: relative; + width: 100%; + padding-bottom: 61.31687242798354%; +} + +.discount__sale .discount_form .discount_form-inp { + opacity: 1; +} + +.discount__sale .discount_form .discount_form-inp::placeholder { + opacity: .6; +} + +.discount__sale .discount_title span { + background: var(--Accent-1, radial-gradient(200.43% 141.42% at 100% 0%, #188892 0%, #1EA49C 45%, #76CE75 90%, #BBE38D 100%)); + background-clip: text; + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} + +.blog_link.main_link:hover span { + background: var(--Accent-1, radial-gradient(200.43% 141.42% at 100% 0%, #188892 0%, #1EA49C 45%, #76CE75 90%, #BBE38D 100%)); + background-clip: text; + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; +} + +@media screen and (max-width: 991px) { + .reviews__left { + width: 100%; + } +} + +@media screen and (max-width: 768px) { + .home__item img { + position: relative; + right: unset; + top: unset; + width: 100%; + height: auto; + } + + .home__item { + display: flex; + flex-direction: column-reverse; + } + + .home__block { + max-width: 100%; + margin-top: 12px; + } + + .home__title { + font-size: 32px; + font-style: normal; + font-weight: 700; + line-height: 38px; /* 118.75% */ + letter-spacing: -0.32px; + text-transform: uppercase; + } + + .home__subtitle { + margin-top: 16px; + } + + .home__btn { + margin-top: 16px; + max-width: 100%; + } + + .home__pagination { + margin-top: 12px; + text-align: center; + } + + .blog .blog_slider { + margin-top: 28px; + } + + .cosmopet-x__title { + font-size: 32px; + line-height: 38px; /* 118.75% */ + } + + .cosmopet-x__item { + height: 0; + padding-bottom: 151.25%; + } + + .cosmopet-x .slider-arrows { + display: flex; + } + + .cosmopet-x__swiper { + margin-top: 23px; + } + + .slider-arrows .cosmopet-prev { + left: -16px; + } + + .slider-arrows .cosmopet-next { + right: -16px; + } + + .reviews .reviews_title { + text-align: left!important; + font-size: 32px!important; + line-height: 38px!important; /* 118.75% */ + letter-spacing: -0.32px!important; + text-transform: uppercase!important; + margin: 0!important; + } + + .reviews_item .reviews_item-top { + justify-content: space-between; + } + + .reviews__left { + width: 100%; + } + + .reviews_items .reviews_item { + transform: unset!important; + } + + .reviews_items .reviews_item { + width: 100%!important; + } + + .reviews_items .reviews_person-mob { + display: none; + } + + .reviews_item .reviews_item-text { + font-size: 16px!important; + font-style: normal!important; + font-weight: 500!important; + line-height: 20px!important; + } + + .reviews_item .reviews_item-top b { + font-size: 19px!important; + font-style: normal!important; + font-weight: 700!important; + line-height: 24px!important; /* 120% */ + text-transform: uppercase!important; + } + + .reviews_item .reviews_item-text { + max-width: 100%!important; + } + + .truth { + padding-top: 78px; + } + + .blogosphere__circle { + display: none; + } + + .blogosphere__swiper.swiper { + margin-left: -15px; + width: calc(100% + 30px); + } + + .marketplace__title { + font-size: 32px; + line-height: 38px; /* 118.75% */ + letter-spacing: -0.32px; + } + + .marketplace__swiper { + margin-top: 24px; + margin-left: 0px; + margin-right: 0px; + } + + .smiSlider .slider-arrows { + transform: translate(-50%, -50%)!important; + width: 106%!important; + } + + .truth .truth_title span { + background: var(--Accent-1, radial-gradient(200.43% 141.42% at 100% 0%, #188892 0%, #1EA49C 45%, #76CE75 90%, #BBE38D 100%)); + background-clip: text; + -webkit-background-clip: text; + -webkit-text-fill-color: transparent; + color: none; + } + + .truth { + padding-top: 20px!important; + } + + .truth_content-wrap { + padding: 0 30px; + } +} + +@media screen and (max-width: 540px) { + .marketplace:after { + display: none; + } + + .truth .truth_content .truth_block, .truth .truth_content-end .truth_block { + height: auto!important; + } + + .truth .truth_block { + padding: 25px 15px 26px 15px!important; + } + + .blog_block .blog_text { + max-width: 100%!important; + font-size: 18px!important; + font-style: normal!important; + font-weight: 500!important; + line-height: 24px!important; + } + + .home { + background: var(--radial); + } + + .blogosphere__swiper .slider-arrows { + display: flex; + padding: 0 4.5px; + } + + .truth_block .truth_links { + padding-bottom: 0!important; + } + + .reviews_items .reviews_item { + padding: 32px 20px 35px 24px!important; + border-radius: 3.75rem!important; + } + + .reviews_items .reviews_item::after { + border-radius: 3.75rem!important; + } + + .blogosphere__top { + margin-bottom: -55px; + } + + .truth_block .truth_block-text { + min-height: unset!important; + } + + .discount { + margin-top: -50px; + } + + .sellers { + padding-top: 35px; + } + + .blogSlider .slider-arrows { + display: none!important; + } + + .blog_slider { + padding-bottom: 0!important; + } + + .cosmopet-x .slider-arrows .cosmopet-prev { + left: -10px; + } + + .cosmopet-x .slider-arrows .cosmopet-next { + right: -10px; + } + + .sellers { + padding-bottom: 120px!important; + } + + .discount__sale { + border-radius: 24px; + } + + .discount_form .discount_form-btn { + opacity: 1!important; + } + + .blogosphere { + padding-top: 40px; + } + + .reviews { + padding: 56px 0 62px!important; + } + + .reviews_item-top + span { + line-height: 15px; + } + + .reviews_block .reviews_items { + margin-left: 0!important; + } + + .reviews_item-name { + max-width: 70%; + } + + .reviews_item .reviews_item-top img { + width: 72px!important; + height: 72px!important; + } + + .reviews__left { + gap: 10px; + } +} + +.blogSlider .swiper-slide { + height: auto; +} + +.blogSlider .swiper-slide .blog_card { + height: 100%; +} + +.blogSlider .swiper-slide .blog_card .blog_card-info-wrap { + height: 100%; +} + +.blog_slider { + padding-bottom: 92px; +} + +.blog_card .blog_card-info { + justify-content: space-between; +} + +.blog_card-text { + flex: auto; +} + + +.carousel-item.active { + /* pointer-events: none; */ +} + +.sec-bf{ + position: relative; + z-index: 3; +} + +.copied{ + position: absolute; + top: -14px; + border-radius: 20px; + font-size: 13px; + right: -20px; + background: #fff; + padding: 5px; + opacity: 0; + pointer-events: none; + color: #000; +} + +.truth__end-btn.active .copied{ + opacity: 1; +} + +.home { + overflow: hidden; +} + + +.reviews_block { + position: relative; +} + +.reviews_items.--visible { + display: flex; + flex-wrap: wrap; + gap: 20px; +} + +.reviews_row { + flex: 1 1 100%; + display: flex; +} + +.reviews_row--left { + justify-content: flex-start; +} + +.reviews_row--right { + justify-content: flex-end; +} + +.reviews_item { + width: 50%; + /* Каждый блок занимает половину ширины */ +} + +.reviews_item-swiper { + width: 100%; +} + +.reviews_item-img { + border-radius: 50%; +} + +.reviews_item-top { + display: flex; + justify-content: space-between; + padding-bottom: 10px; +} + +.reviews_item-text { + margin-top: 10px; +} + +.reviews_item.reviews_item1 { + flex: 1 1 50%; + max-width: 50%; +} + +.reviews_item.reviews_item2, +.reviews_item.reviews_item4 { + flex: 1 1 calc(50% - 20px); + max-width: 50%; +} + +.reviews_item.reviews_item2 { + position: absolute; + max-width: 500px; + height: 360px; + right: -4%; + bottom: 25%; +} + +.reviews .reviews_person { + position: absolute; + right: -100px; + top: -20%; +} + +@media (max-width: 768px) { + .reviews_row { + justify-content: center !important; + /* На мобильных устройствах центрируем */ + } + + .reviews_item { + width: 100%; + /* На мобильных устройствах блоки на всю ширину */ + } + + .reviews_person { + position: static; + margin: 20px auto; + max-width: 150px; + } + + .reviews_item.reviews_item1 { + flex: 1 1 50%; + max-width: 100%; + } + + .reviews_item.reviews_item2, + .reviews_item.reviews_item4 { + flex: 1 1 calc(50% - 20px); + max-width: 100%; + } + + .reviews_item.reviews_item2 { + position: unset; + max-width: 500px; + height: 360px; + right: -4%; + bottom: 25%; + } + + .reviews .reviews_person { + position: absolute; + right: -100px; + top: -20%; + } + + .reviews_row { + justify-content: center !important; + display: contents; + } +} + + +.no-scroll { + overflow: hidden; +} +.img--mobile{ + display: none; +} +@media only screen and (max-width: 1170px) { + .about_block .about_cards { + grid-template-columns: 48.5% 48.5%; + gap: 30px 20px; + } + .about_cards .about_company{ + max-width: 380px; + } + + .sellers_slider .swiper { + padding-left: 0; + padding-right: 0; + } + .blog_slider .swiper { + padding-left: 30px; + padding-right: 30px; + } + + .truth_block .truth_block-title, + .truth .truth_title { + font-size: 60px; + line-height: 70px; + width: 100%; + } + .discount_top .discount_title { + font-size: 60px; + max-width: 550px; + line-height: 65px; + } + .discount_top .discount_top-imgs { + position: absolute; + top: 20px; + right: -50px; + } + .discount_top .discount_top-imgs .dicount_dog-img { + width: 400px; + } + + .reviews_block .reviews_items{ + margin-left: -30px; + } + +} +@media only screen and (min-width: 600px){ +.swiper-slide-active .sellers_card { + + transform: scale(1.05); /* Увеличение на 1.2 */ + transition: transform 0.3s ease; + background: #fff; +} +} +@media only screen and (max-width: 950px){ + .about_us .about_us-title, + .sellers_top .sellers_title, + .about_info .about_title, + .home_block .home_title { + font-size: 65px; + line-height: 78px; + } + .about .about_block { + gap: 0; + } + .about_block .about_info-wrap{ + gap: 30px; + } + .about_info .about_text { + font-size: 20px; + line-height: 24px; + } + + .about_info-wrap .about_img img { + width: 230px; + height: 560px; + } + + .blog_card .blog_card-info-wrap { + width: 108%; + } + .sellers_top .slider-arrows { + display: none; +} + .seller_block .sellers_top { + align-items: start; + flex-direction: column; + gap: 10px; + } + .sellers_card .sellers_card-img { + /* width: 100%; */ + } + .sellers_card .sellers_card-text{ + text-align: center; + } + .about_us-block .about_us-cards { + grid-template-columns: 48% 48%; + gap: 17px; + } + + .truth_block .truth_block-text p{ + max-width: 400px; + } + .truth_top .gift_img { + margin-left: -120px; + width: 400px; + } + + .reviews_block .reviews_items{ + flex-direction: column; + margin-left: 0; + gap: 0; + align-items: center; + } + .reviews .reviews_title{ + text-align: center; + } + .reviews .reviews_person{ + display: none; + } + .reviews_person-mob{ + display: flex; + order: 3; + object-fit: contain; + margin-top: -80px; + z-index: -2; + } + .reviews_items .reviews_item{ + border-radius: 25px; + padding: 10px 14px; + } + .reviews_items .reviews_item::after{ + border-radius: 25px; + } + .reviews_items .reviews_item1{ + order: 1; + } + .reviews_items .reviews_item2{ + order: 2; + transform: rotate(7deg); + padding: 13px; + margin-top: 10px; + z-index: -1; + margin-left: -4px; + } + .reviews_items .reviews_item6{ + order: 4; + transform: rotate(2deg); + margin-top: -80px; + } + .reviews_items .reviews_item3{ + order: 6; + transform: rotate(2.18deg); + margin-top: 5px; + z-index: -2; + } + .reviews_items .reviews_item4{ + order: 5; + transform: rotate(-1.7deg); + margin-top: 0px; + z-index: -1; + } + .reviews_items .reviews_item5{ + order: 7; + transform: rotate(-3.14deg); + margin-top: -3px; + z-index: -3; + } + + .reviews_item .reviews_item-top b { + font-size: 20px; + line-height: 22px; + } + .reviews_item .reviews_item-text { + font-size: 12px; + line-height: 14.4px; + max-width: 228px; + } +} + +@media only screen and (max-width: 776px){ + .home_dog + { + display: none; + } + .sellers_slider .swiper { + width: 568px; + } + .sellers_card .sellers_card-img { + height: 260px; + } + .slider-arrows { + display: none; + } + .home_block-dog{ + display: flex; + margin-top: 20px; + } + .home .container { + padding: 68px 30px 180px; + } + + .blog_block .blog_title, + .about_info .about_title{ + font-size: 44px; + line-height: 50px; + } + .about_info-wrap .about_img { + max-width: 200px; + } + .about_card .about_card-title { + font-size: 20px; + line-height: 24px; + } + .blog_block .blog_text, + .about_card .about_card-text { + font-size: 16px; + line-height: 18px; + } + .about_card .about_card-info { + gap: 2px; + } + .about_us-card .about_us-card-info h2 { + font-size: 12px; + line-height: 16px; + font-weight: 700; + } + .about_us-card .about_us-card-info span { + font-size: 12px; + line-height: 14px; + } + .about_us-block .about_us-card { + border-radius: 25px; + height: 181px; + } + .about_us-card .about_us-card-info{ + gap: 4px; + padding: 55px 20px 40px; + } + .about_us-cards .about_us-card .about_us-card-info { + height: 131px; + } + .about_us-card .card_date { + top: auto; + right: auto; + bottom: 16px; + left: 20px; + right: 0; + z-index: 2; + padding: 0; + border-radius: 0; + height: fit-content; + width: fit-content; + font-size: 12px; + line-height: 14.4px; + background: transparent; + font-weight: 700; + } + + /* start: QUIZ - max-width: 776px */ + .truth_content-end .truth_block .truth_info { + margin-top: 0px; + } + .truth .truth_top { + flex-direction: column-reverse; + } + .truth_top .gift_line-img{ + display: flex; + } + .truth .truth_title{ + max-width: 500px; + margin-left: auto; + } + .truth_top .gift_img { + transform: rotate(-45deg); + margin-right: auto; + margin-left: -50px; + } + .truth_block .truth_info { + position: relative; + width: 100%; + margin-top: 0; + align-items: center; + flex-direction: column-reverse; + } + .truth_content::after{ + border-radius: 25px; + } + .truth_block .truth_links { + flex-direction: column; + gap: 12px; + padding-bottom: 26px; + width: 100%; + } + .truth_block .truth_link { + width: 100%; + height: 50px; + align-items: center; + justify-content: start; + padding: 8px 20px; + } + + .truth .truth_block { + border-radius: 25px; + height: auto; + padding: 25px 15px 0px 15px; + } + .truth_content-end .truth_block .truth_info{ + flex-direction: column; + } + .truth_content-end .truth_block .truth_links{ + padding-top: 30px; + } + .truth_content-end .truth_block .truth_link{ + width: 100%; + } + .truth_content-end .truth_block .truth_block-text{ + flex-direction: column; + } + .truth_content-end .truth_block .truth_block-text p{ + max-width: 230px; + } + .truth_content-end .truth_xn{ + width: 90px; + height: 58px; + } + .truth_content-end .truth_info img { + width: auto !important; + height: 26vh !important; + object-fit: cover; + position: absolute; + bottom: -21vh; + left: -62px; + } + .truth_content-end .truth_block .truth_link { + width: 100%; + background: #FFF; + } + .truth_content-end .truth_block .truth_end-text{ + width: 100%; + } + + /* end: QUIZ - max-width: 776px */ + + /* start: Наш блог - max-width: 776px*/ + .blog_card .blog_card-title { + font-size: 20px; + line-height: 25.4px; + } + .blog_card .blog_card-text { + font-size: 16px; + line-height: 18.4px; + } + .blog_card .blog_card-info{ + gap: 9px; + } + .blog_slider .blog_card { + border-radius: 30px; + } + .blog_card .blog_card-info-wrap{ + width: 100%; + border-radius: 0; + padding: 12px 14px 16px 16px; + } + .blog_slider .blog_card:hover .blog_card-info-wrap{ + padding-right: 14px; + } + .blog_slider .blog_card:hover { + overflow: hidden; + } + .blog_card .card-line-img{ + display: none; + } + .blog_card .blog_card-img{ + border-radius: 30px 30px 0 0; + } + /* end: Наш блог - max-width: 776px */ + + /* start: Узнайте о нас больше и получите скидку! - max-width: 776px */ + .discount .discount_top{ + margin-bottom: 148px; + order: 1; + } + .discount_block .discount_text{ + order: 2; + margin-bottom: 20px; + } + .discount_block .discount_form{ + order: 3; + margin-bottom: 20px; + } + .discount_block .discount_form-text{ + order: 4; + margin-bottom: 0; + } + .discount_block .discount_cosmodog{ + order: 5; + } + .discount_top .discount_title { + font-size: 48px; + line-height: 52px; + } + .discount_top .discount_top-imgs { + right: -165px; + top: 100px; + } + .discount_top .discount_top-imgs img{ + width: 314px; + } + + .discount_block .discount_form{ + flex-direction: column; + gap: 8px; + width: 100%; + } + .discount_form .discount-line{ + display: none; + } + .discount_form .discount_form-btn, + .discount_form .discount_form-inp{ + width: 100%; + } + /* end: Узнайте о нас больше и получите скидку! - max-width: 776px */ + + .post-single-page .article-body-container{ + padding-bottom: 100px; + } +} + +/* GP | Mobile */ +@media only screen and (max-width: 576px) { + + /*Слайдер*/ + .about .container-fluid { + padding-right: 0; + padding-left: 0; + } + + /*Бестселлеры*/ + .sellers .sellers_card { + background: #fff; + } + .sellers_slider { + height: 530px; + } + .gp_tags { + border: 1px solid #121212; + border-radius: 48px; + padding:2px 4px 2px 4px; + font-size: 14px; + line-height: 18px; + height: 24px; + } + /* .tags_block { + width: 200px; + } */ + .sellers_slider .swiper { + display: flex; + align-items: stretch; + width: 320px; + height: inherit; + } + .seller_name { +font-size: 20px; +font-weight: 500; +line-height: 24px; +text-align: left; + } + .seller_price { + font-size: 20px; + font-weight: bold; + line-height: 30px; + text-align: left; + margin-bottom: 8px; + margin-top: 8px; + } + /* start: Scrollbar */ + body::-webkit-scrollbar { + width: .2rem; + /* background: #fff0; */ + background: linear-gradient(#0F5881, #76CE75, #ECF39F); + } + + body::-webkit-scrollbar-thumb { + border-radius: 4px; + background: rgba(128, 128, 128, 0.9); + } + /* end: Scrollbar */ + + /* start: ОБЩИЕ */ + .img--desktop { + display: none; + } + + .img--mobile { + display: block; + } + /* end: ОБЩИЕ */ + + .main_link { + font-size: 12px; + line-height: 14.4px; + width: 129px; + height: 29px; + padding: 7px; + } + + + .home .home_line2 { + display: flex; + } + + .home .home_line { + display: none; + } + + .home .home_block { + gap: 8px; + } + + .home_block .home_title { + font-size: 26px; + line-height: 34px; + width: 80vw; + } + + .about { + border-radius: 25px; + padding-bottom: 0; + } + + .about > .container { + width: 100%; + margin-right: auto; + margin-left: auto; + } + + .about .about_info-wrap{ + flex-direction: column; + } + + .about_info-wrap .about_img{ + max-width: unset; + width: 100vw; + } + .about_info-wrap .about_img img{ + height: auto; + width: 100%; + } + + .about_cards .about_card { + gap: 0; + } + + .about_cards .about_card-right { + align-items: end; + text-align: end; + } + + .about_card-right .about_card-text { + margin-left: auto; + } + + .about_card .about_card-gif1, + .about_card .about_card-gif4 { + width: 87px; + height: 87px; + } + + .about_card .about_card-gif2 { + width: 99px; + height: 99px; + } + + .about_card .about_card-gif3 { + width: 117px; + height: 102px; + } + + .about_company { + margin-top: 4vh; + } + + .about_company .about_company-logo img { + height: 33px; + } + + .about_company .about_company-logo img:nth-child(1), + .about_company .about_company-logo img:nth-child(3), + .about_company .about_company-logo img:nth-child(4) { + height: 33px; + } + + .about_company .about_company-logo { + display: flex; + gap: 0px 5px; + margin-top: 2%; + justify-content: space-around; + } + + .about_company .about_company-text { + font-size: 12px; + line-height: 14.4px; + } + + .about_cards .about_company { + padding: 15px 16px 18px 16px; + gap: 5px; + border-radius: 25px; + } + + .about_cards .about_company::after { + border-radius: 25px; + } + + .about_company .about_company-logo img { + width: auto; + } + + .about_block .about_cards { + grid-template-columns: 100%; + gap: 10px; + } + + .about_us-cards .about_us-card .about_us-card-info { + height: 151px; + } + + .truth_block .truth_block-text p, + .about_card .about_card-title { + font-size: 12px; + line-height: 18.2px; + } + + .discount_block .discount_text, + .blog_card .blog_card-text, + .blog_block .blog_text, + .truth_block .truth_link, + .sellers_card .sellers_card-text, + .about_card .about_card-text { + font-size: 12px; + line-height: 14.2px; + } + + .about_card .about_card-gif { + margin-bottom: -17px; + } + + .about_slider { + padding: 0; + } + + .about_slider .carousel { + height: 55vh; + min-height: 55vh; + } + + .about .about_block { + gap: 55px; + } + + .about_slider .slide { + padding: 10px 39px; + width: 280px; + height: 280px; + border-radius: 100%; + gap: 12px; + } + + .about_slider .carousel .carousel-item { + padding: 10px 39px; + width: 290px; + height: 290px; + border-radius: 100%; + } + + .about_slider .carousel .carousel-item::after { + background-image: url(../img/border-mobile.png); + border-radius: 100%; + } + + .about_slider .prev { + left: 10vw; + } + + .about_slider .next { + right: 10vw; + } + + .about_slider .slide.active { + transform: translate(0, -20px); + } + + .about_slider .slide img { + width: 113px; + height: 113px; + } + + .about_slider .slide_info { + gap: 6px; + } + + .about_slider .slide_text, + .about_slider .slide_title { + font-size: 12px; + line-height: 14.4px; + text-align: center; + } + + .about_us-block .about_us-card::after, + .about_us-card .about_us-card-img { + border-radius: 25px; + } + + .about_us-card .about_us-card-info { + border-radius: 0 0 25px 25px; + } + + .discount_top .discount_title, + .blog_block .blog_title, + .truth_block .truth_block-title, + .about_us .about_us-title, + .sellers_top .sellers_title { + font-size: 30px; + line-height: 36px; + } + + .sellers_card .sellers_card-img { + width: 100%; + height: 290px; + object-fit: contain; + } + + .sellers .sellers_card { + border-radius: 24px; + height: 520px; + padding:31px 16px 31px 16px; + } + .sellers .swiper-slide{ + max-height: 35vh; + } + + .section_wrap { + padding: 110px 0 52px; + } + + .sellers { + position: relative; + padding-bottom: 87px; + } + + .sellers .sellers_link { + position: absolute; + bottom: 24px; + right: 22px; + } + + .seller_block .sellers_top { + gap: 0; + margin-bottom: 15px; + } + + .reviews { + padding: 90px 0px 36px; + border-radius: 25px 25px 0 0; + } + + /* QUIZ */ + .truth { + border-radius: 0 0 25px 25px; + padding-bottom: 47px; + } + + .truth .truth_content .truth_block, + .truth .truth_content-end .truth_block + { + height: 70vh; + } + + .truth .truth_title { + font-size: 30px; + line-height: 36px; + max-width: 260px; + } + + .truth_top .gift_img { + margin-left: -24px; + width: 160px; + } + + .truth_top .gift_line-img { + bottom: 44px; + width: auto; + } + + .truth_block .truth_block-text img { + width: 29px; + } + + .truth_block .truth_block-title { + max-width: 171px; + margin-bottom: 7px; + } + + .truth_block .truth_line { + gap: 16px; + margin-bottom: 10px; + } + + .truth_block .truth_line span { + width: 34px; + } + + .truth_block .truth_link { + height: 29px; + border-width: 2px; + } + + .truth_content-end .truth_info img { + width: 100%; + } + + .truth_block .truth_info img { + height: 170px; + width: auto; + } + + .truth_links .truth_result { + display: none; + } + + .truth_block .truth_block-text { + gap: 11px; + } + + .truth .truth_block { + height: 470px; + } + + .truth_block .truth_links { + width: 100%; + margin-right: 0; + } + .truth_error .truth_block-text, + .truth_success .truth_block-text + { + margin-bottom: 25%; + } + + /* 381 string in adaptive */ + .truth_content-end .truth_info img { + /* width: auto !important; + object-fit: cover; + position: absolute; + left: -62px; */ + height: 30vh !important; + bottom: 0; + left: unset; + right: 0; + } + + /* QUIZ - конец */ + + + /* Наш блог */ + .blog { + position: relative; + padding-top: 63px; + padding-bottom: 90px; + } + + .blog .blog_link { + position: absolute; + bottom: 35px; + right: 30px; + } + + .blog_card .blog_card-img { + height: 120px; + object-fit: cover; + } + + .blog_card .blog_card-title { + font-size: 12px; + line-height: 16px; + } + + .blog_block .blog_text { + max-width: 230px; + } + + .blog_slider .swiper { + padding-left: 15px; + padding-right: 15px; + } + /* Наш блог - конец */ + + + /* Узнайте о нас больше и получите скидку! */ + .discount { + padding: 0px 0 43px; + } + + .discount_block .discount_text { + max-width: 260px; + } + + .discount_top .discount_top-imgs { + right: -136px; + top: 87px; + } + + .discount_top .discount_top-imgs .dicount_dog-img { + width: 314px; + width: 110vw; + } + + .discount_form .discount_form-inp { + height: 29px; + padding: 6px 13px; + font-size: 12px; + line-height: 14.4px; + } + + .discount_form .discount_form-inp::placeholder { + font-size: 12px; + line-height: 14.4px; + } + + .discount_form .discount_form-btn { + justify-content: start; + padding: 5px 15px; + background: var(--creme-white, #F4F1F0); + color: #62c57e; + opacity: 0.6; + } + .discount_form img{ + display: none; + } + .discount_form span{ + width: 100%; + } + + .discount_block .discount_cosmodog { + border-radius: 25px; + height: 415px; + } + + .discount_cosmodog .discount_cosmodog_info { + height: 245px; + gap: 14px; + padding: 10px 19px; + } + + .discount_cosmodog .discount_cosmodog-title { + text-align: start; + font-size: 26px; + line-height: 31.2px; + max-width: 202px; + margin-right: auto; + } + + .discount_cosmodog .discount_cosmodog-text { + font-size: 12px; + line-height: 14.4px; + max-width: 231px; + text-align: start; + margin-right: auto; + } + + .discount_top .discount_top-imgs { + right: -20%; + top: 0; + transform: scale(1.8); + z-index: 0; + margin-bottom: -91%; + margin-top: 20%; + position: relative; + } + + .discount_block .wpcf7 { + order: 3; + } + + /* Узнайте о нас больше и получите скидку! - конец */ + + /* start: Отзывы ветеринаров */ + .reviews .reviews_title { + font-size: 26px; + line-height: 31px; + max-width: 278px; + margin: 0 auto; + } + + .reviews .reviews_block { + margin-top: 20px; + } + + .reviews_block .reviews_items { + flex-wrap: unset; + gap: 10px; + } + + .reviews_items .reviews_item { + width: 80vw; + gap: 10px; + } + + .reviews_items .reviews_item2 { + margin-top: -0px; + } + + .reviews_items .reviews_item1 { + transform: rotate(-5.35deg); + } + + .reviews_items .reviews_item3 { + margin-top: 3px; + } + + .reviews_items .reviews_item4 { + margin: unset; + } + + .reviews_items .reviews_person-mob { + margin-bottom: -10%; + } + + .reviews_item .reviews_item-name { + display: flex; + flex-direction: column; + gap: 20px; + } + + .reviews_item .reviews_item-top b { + font-size: 12px; + line-height: 16px; + text-transform: uppercase; + } + + .reviews_item .reviews_item-top span { + max-width: 134px; + } + + /* end: Отзывы ветеринаров */ + + /* start: О НАС ПИШУТ СМИ*/ + .about_us-card .about_us-card-info span a { + font-size: 14px; + } + + .about_us-block .about_us-cards { + grid-template-columns: 1fr; + } + + .about_us-card .card_date { + right: 20px; + left: unset; + } + + .about_us-cards .about_us-card-info { + height: 130px; + } + + .about_us-card .about_us-card-info { + padding: 55px 20px 20px; + } + + .about_us-card-info.card-info--half-gradient { + background: linear-gradient(0deg, #F4F1F0 45%, rgba(244, 241, 240, 0) 100%); + } + + .truth_content-end .truth_block .truth_end-text, + .truth_content-end .truth_block .truth_block-text { + position: static; + } + + .truth_content-end .truth_block .truth_link { + border-width: 2px; + position: static; + bottom: 28px; + right: 0; + width: 100%; + margin-bottom: 76px; + z-index: 2; + } + + .truth_content-end .truth_info { + bottom: 0; + left: 0; + position: absolute; + } + + /* end: О НАС ПИШУТ СМИ */ + + /* start: Проверьте свои знания и получите подарок! */ + .truth_top .gift_img { + width: 64vw; + margin: unset; + transform: translateX(-22%) rotate(-45deg); + } + + .truth_top .gift_line-img { + top: 40%; + } + + .truth .truth_block { + padding: 25px; + } + + .truth_block .truth_line { + gap: 10%; + } + + .truth_block .truth_block-text { + min-height: 20%; + } + + .truth_points { + font-size: 30px; + } + + /* end: О НАС ПИШУТ СМИ */ + + + /* start: Наш блог */ + .blog_slider .blog_card { + height: 290px; + } + + .blog_card .blog_card-img { + border-color: #121212; + } + + .blog_card .blog_card-info-wrap { + border-radius: 0 0 30px 30px; + border-color: #121212; + } + + .blog_slider .blog_card:hover .blog_card-info-wrap{ + border-radius: 0 0 30px 30px; + width: 100%; + } + /* end: Наш блог */ + + + + /* start: Футер */ + .footer_form .footer_form-title h2, + .footer_box .footer_box-title { + font-size: 12px; + line-height: 16.2px; + font-weight: 700; + } + + .footer_box .footer_box-link { + font-size: 12px; + line-height: 16.2px; + } + + .footer_form .footer_form-textarea textarea, + .footer_form .footer_form-inp input { + height: 28px; + border: 1px solid var(--grey-black, #121212); + padding: 5px 18px; + font-size: 12px; + line-height: 14.4px; + opacity: .5; + } + + .footer_form .footer_block .footer_bottom a, + .footer_form .footer_form-inp input::placeholder { + font-size: 12px; + line-height: 14.4px; + } + + .footer_form .footer_form-textarea textarea { + height: 123px; + min-height: unset; + padding: 7px 18px; + border-radius: 17px !important; + } + + .footer_form .footer_form-textarea { + display: flex; + flex-direction: column; + gap: 13px; + } + + .footer_form-textarea .footer_form-btn { + position: static; + width: 100%; + min-height: unset; + } + + .footer_block .footer_social { + gap: 14px; + } + + .footer_block .footer_bottom a:nth-child(2) { + display: none; + } + + .footer_form .footer_form-inp { + flex-direction: column; + } + + .footer .footer_box{ + display: grid; + grid-template-columns: repeat(2, 1fr); + grid-template-rows: repeat(2, 1fr); + row-gap: 14px; + column-gap: 0; + } + .footer .footer_box .footer_line-mob + { + grid-area: 1 / 2 / 3 / 3; + height: 100%; + padding-top: 4px; + } + .footer .footer_box .footer_line-mob1{ + margin-left: -30%; + } + .footer .footer_box .footer_box-title{ + grid-area: 1 / 1 / 1 / 1; + } + .footer .footer_box .footer_box-link{ + grid-area: 2 / 1 / 2 / 1; + } + .footer_box .footer_line-mob{ + display: block; + } + .footer_block .footer_bottom a{ + font-size: 12px; + line-height: 18px; + } + /* end: Футер */ +} + +@media only screen and (max-width: 350px) { + .reviews_block .reviews_items { + margin-left: -20px; + } +} + +.btn--black-hover:hover { + background: #121212 !important; + color: #F4F1F0 !important; + transition: .3s +} + +.btn--black-hover { + transition: .3s +} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/forms/components/discount/component-controller.php b/wp-content/themes/cosmopet/modules/forms/components/discount/component-controller.php new file mode 100644 index 0000000..e69de29 diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-core.css b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-core.css new file mode 100644 index 0000000..992adcc --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-core.css @@ -0,0 +1,552 @@ +*{ + margin: 0; + padding: 0; + box-sizing: border-box; +} + +/* Переменные, шрифты, UI kit */ + +/* +700 - Bold +600 - SemiBold / Demi +500 - Medium +400 - Regular +*/ + +a{ + cursor: pointer; +} + +/* Craftwork Grotesk */ +@font-face { + font-family: "Craftwork Grotesk"; + src: local("Craftwork Grotesk Bold"), + url("../fonts/craftwork/CraftworkGrotesk-SemiBold.woff2") format("woff2"), + url("../fonts/craftwork/CraftworkGrotesk-Bold.woff") format("woff"), + url("../fonts/craftwork/craftwork-grotesk-bold.ttf") format("ttf"); + font-weight: 700; +} +@font-face { + font-family: "Craftwork Grotesk"; + src: local("Craftwork Grotesk SemiBold"), + url("../fonts/craftwork/CraftworkGrotesk-SemiBold.woff2") format("woff2"), + url("../fonts/craftwork/CraftworkGrotesk-SemiBold.woff") format("woff"), + url("../fonts/craftwork/craftwork-grotesk-semi-bold.ttf") format("ttf"); + font-weight: 600; +} +@font-face { + font-family: "Craftwork Grotesk"; + src: local("Craftwork Grotesk Medium"), + url("../fonts/craftwork/CraftworkGrotesk-Medium.woff2") format("woff2"), + url("../fonts/craftwork/CraftworkGrotesk-Medium.woff") format("woff"), + url("../fonts/craftwork/craftwork-grotesk-medium.ttf") format("ttf"); + font-weight: 500; +} +@font-face { + font-family: "Craftwork Grotesk"; + src: local("Craftwork Grotesk Regular"), + url("../fonts/craftwork/CraftworkGrotesk-Regular.woff2") format("woff2"), + url("../fonts/craftwork/CraftworkGrotesk-Regular.woff") format("woff"), + url("../fonts/craftwork/craftwork-grotesk-regular.ttf") format("ttf"); + font-weight: 400; +} +/* Craftwork Grotesk */ + +/* din 2014 */ +@font-face { + font-family: "DIN 2014 Rounded"; + src: local("DIN 2014 Rounded Demi"), + url("../fonts/din-2014/din-2014-rounded-demi.woff2") format("woff2"), + url("../fonts/din-2014/din-2014-rounded-demi.woff") format("woff"), + url("../fonts/din-2014/din-2014-rounded-demi.ttf") format("ttf"); + font-weight: 600; +} +@font-face { + font-family: "DIN 2014 Rounded"; + src: local("DIN 2014 Rounded Regular"), + url("../fonts/din-2014/din-2014-rounded-regular.woff2") format("woff2"), + url("../fonts/din-2014/din-2014-rounded-regular.woff") format("woff"), + url("../fonts/din-2014/din-2014-rounded-regular.ttf") format("ttf"); + font-weight: 400; +} +/* din 2014 */ + +/* roboto */ +@font-face { + font-family: "Roboto"; + src: local("Roboto Medium"), + url("../fonts/roboto/Roboto-Medium.woff2") format("woff2"), + url("../fonts/roboto/Roboto-Medium.woff") format("woff"), + url("../fonts/roboto/roboto-medium.ttf") format("ttf"); + font-weight: 500; +} +@font-face { + font-family: "Roboto"; + src: local("Roboto Regular"), + url("../fonts/roboto/Roboto-Regular.woff2") format("woff2"), + url("../fonts/roboto/Roboto-Regular.woff") format("woff"), + url("../fonts/roboto/roboto-medium.ttf") format("ttf"); + font-weight: 400; +} +/* roboto */ + +/* Глобальные переменные: */ + +:root { + /* fonts */ + --font-family: "Craftwork Grotesk", sans-serif; + --second-family: "DIN 2014 Rounded", sans-serif; + --third-family: "Roboto", sans-serif; + + /* color */ + /* text */ + --text-white: #fff; + --text-black: #121212; + --text-dark: #2b2b3b; + --text-grey: #999; + --text-red: #fa0505; + --text-green: #2ED15D; + --text-0: #000; + --text-3: #333; + --text-6: #666; + --text-9: #999; + + /* background */ + --background-white: #fff; + --background-black: #121212; + --background-grey: #f2f2f2; + --background-green: #2ED15D; + --background-green-white: #f4fff0; + --background-9: #999; + + + /* gradient */ + --gradient-blue: radial-gradient(346.57% 244.17% at 149.73% -58.39%, rgb(15, 88, 129) 0%, rgb(30, 164, 156) 51.21689438819885%, rgb(118, 206, 117) 80.70731163024902%, rgb(236, 243, 159) 91.14583134651184%); + --gradient-turquoise: radial-gradient(346.57% 244.17% at 149.73% -58.39%, rgb(117, 196, 240) 0%, rgb(126, 231, 225) 51.21689438819885%, rgb(181, 228, 180) 80.70731163024902%, rgb(237, 244, 164) 91.14583134651184%); + --gradient-red: linear-gradient(22deg, #f44242 0%, #569ef0 100%); +} + + +/* общие */ +button{ + cursor: pointer; +} + +.wrapper{ + margin: 0 auto; + + max-width: 1600px; +} + +/* компоненты */ + +/* lang*/ +/* lang */ + + +/* mini-profile */ +/* mini-profile */ + + +/* main-menu */ +/* main-menu */ + + +/* form */ +/* .form-input-radio__ */ +/* form */ + + +/* social media */ +/* social media */ + + +/* breadcrumbs */ +.breadcrumbs{ + margin: 24px; + + display: flex; + align-items: center; +} +.breadcrumbs__item{ + display: block; + + padding: 0px 16px; + + + font-weight: 700; + font-size: 16px; + line-height: 125%; + color: var(--text-6); + + text-decoration: none; + + position: relative; +} +.breadcrumbs__item:first-child{ + padding-left: 0; +} +/* breadcrumbs */ + +/* compound */ +.compound{ + margin: -5px; + + min-height: 33.95px; + + display: flex; + align-items: start; +} +.compound__item{ + margin: 5px; + + padding: 4px 8px; + + + font-weight: 700; + font-size: 12px; + line-height: 133%; + color: var(--text-black); + + border-radius: 16px; + background-color: var(--background-white); + + display: block; + text-decoration: none; +} +.compound__item:first-child{ + margin-left: 0; +} +/* compound */ + +/* button */ +.button{ + + font-weight: 600; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + border-radius: 20px; + + cursor: pointer; +} +.button--100-perc{ + width: 100%; +} +.button--white{ + padding: 11px 24px; + + text-align: center; + + background-color: var(--background-white); + border: 1px solid var(--background-black); + + transition: opacity .2s ease-out; +} +.button--white:hover{ + opacity: .8; +} +.button--gradient{ + background: var(--gradient-turquoise); + border: none; + + transition: opacity .2s ease-out; +} +.button--gradient:hover{ + opacity: .8; +} +.button--high{ + height: 56px; + + padding: 16px 24px 24px 24px; + + font-weight: 700; + text-align: center; + + position: relative; +} +.button--red-48-px{ + border-radius: 48px; +} +.to-know{ + /* width: 100%; */ + + padding: 12px 24px 7px 24px; + + display: flex; + justify-content: center; + + border: none; + + transition: opacity .2s ease-out; + text-decoration: none; +} + +.to-know:hover{ + opacity: .8; +} +.to-know p{ + padding-bottom: 4px; + + + font-weight: 700; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + border-bottom: 1px var(--text-black) solid; + + cursor: pointer; +} +.back{ + margin-top: 16px; + margin-left: 16px; + + padding: 8px; + padding-left: 32px; + + background: none; + border: none; + + + font-weight: 600; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + text-decoration: none; + + position: relative; +} +.back::before{ + content: ''; + + position: absolute; + top: 8px; + left: 0; + + margin-right: 8px; + + width: 24px; + height: 24px; + + background-image: url(../img/svg/main/arrow-back.svg); +} + +.back::after{ + content: ''; + + position: absolute; + bottom: 6px; + left: 0; + + width: calc(100% - 8px); + height: 1px; + + background: var(--text-black); +} +/* button */ + +/* select */ +.select{ + max-width: 144px; + + position: relative; +} +.select__state{ + width: 100%; + + padding: 11px 47px 11px 13px; + + /* pointer-events:none; */ + + border: 1px solid var(--background-black); + border-radius: 20px; + + + font-weight: 400; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + cursor: pointer; + + position: relative; + + transition: opacity .2s ease-out; +} +.select:hover .select__state{ + opacity: .8; +} +.select::after{ + content: ''; + + position: absolute; + top: 20.5px; + right: 21.5px; + + width: 17px; + height: 10px; + + background-image: url(../img/svg/main/arrow-black.svg); + background-repeat: no-repeat; + background-size: contain; + + pointer-events: none; +} +.state__block{ + position: absolute; + top: 48px; + left: 0; + + width: 100%; + + height: 0; + overflow: hidden; + + transition: height .2s ease-out; +} +.state__content{ + padding: 8px; + + border-radius: 6px; + box-shadow: 0 2px 10px 0 rgba(0, 0, 0, 0.1), 0 0 2px 0 rgba(0, 0, 0, 0.2); + background-color: var(--background-white); + + list-style-type: none; +} +.state__content li{ + margin-top: 8px; +} +.state__content li:first-child{ + margin-top: 0; +} +.state__button{ + width: 100%; + + padding: 4px 32px 4px 4px; + + background: none; + border: none; + + + font-weight: 400; + font-size: 20px; + line-height: 120%; + color: var(--text-dark); + text-align: start; + + border-radius: 6px; + + transition: background-color .2s ease-out; + + position: relative; +} +.state__button:hover{ + background-color: var(--background-grey); +} + +/* select */ + +/* counter */ +.counter{ + display: flex; + align-items: center; +} +.counter__input{ + width: 48px; + + + font-weight: 600; + font-size: 20px; + line-height: 120%; + text-align: center; + color: var(--text-black); + + pointer-events: none; + + background: none; + border: none; +} +.counter__button{ + width: 48px; + height: 48px; + + display: flex; + justify-content: center; + align-items: center; + + border: 1px solid var(--text-3); + border-radius: 24px; + + background: var(--background-white); + + transition: opacity .2s ease-out; +} +.counter__button:hover{ + opacity: .8; +} +/* counter */ + +/* modal */ +/* modal */ + +/* toggle */ +.toggle{ + padding-top: 26px; + padding-bottom: 25px; + + border-bottom: 1px solid var(--text-3); + + position: relative; +} +.toggle::after{ + content: ''; + + position: absolute; + top: 24px; + right: 0; + + width: 24px; + aspect-ratio: 1; + + background-image: url(../img/svg/main/black-x.svg); + transform: rotate(45deg); + transition: transform .2s; + pointer-events: none; +} +.toggle__title{ + padding-right: 30px; + + + font-weight: 700; + font-size: 16px; + line-height: 125%; + color: var(--text-black); + + cursor: pointer; +} +.toggle__block-content{ + height: 0; + overflow: hidden; + + transition: height .2s ease-out; +} +.toggle__content{ + padding-top: 24px; +} +.toggle__text{ + + font-weight: 400; + font-size: 20px; + line-height: 120%; + color: var(--text-black); +} +/* toggle */ + +/* checkbox */ +/* checkbox */ + +/* radio */ +/* radio */ \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-desktop.css b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-desktop.css new file mode 100644 index 0000000..8ac9011 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-desktop.css @@ -0,0 +1,722 @@ +/* Основные стили для компьютера */ + +/* header start */ + +.detail-block-form__item a{ + display: block; +} + +.detail-block-form__items{ + margin-top: 12px; +} + +.detail-block-form__item a { + margin: 8px; +} +/* header end */ + +/* product */ + .product__item{ + margin: 12px; + + width: calc(25% - 24px); + + display: flex; + flex-direction: column; + justify-content: space-between; + + background-color: var(--background-grey); + border-radius: 24px; + + overflow: hidden; + + position: relative; + } + .product__item::before{ + content: ''; + + position: absolute; + top: 0; + left: 0; + + width: calc(100% - 2px); + height: calc(100% - 2px); + + border: 1px solid #000; + border-radius: 24px; + + pointer-events: none; + transition: opacity .2s ease-out; + + opacity: 0; + } + .product__item:hover::before{ + opacity: 1; + } + .product-item__label{ + position: absolute; + top: 16px; + left: 16px; + + margin: -2px; + + display: flex; + align-items: center; + + z-index: 10; + } + .product-item-label__tag{ + margin: 2px; + + padding: 4px 8px; + + + font-weight: 700; + font-size: 12px; + line-height: 133%; + color: #f4f1f0; + + border-radius: 16px; + display: block; + + text-decoration: none; + } + .product-item-label__tag--new{ + background: var(--gradient-blue); + } + .product-item-label__tag--sale{ + background: var(--gradient-red); + } + .product-item-label__tag--black{ + background: var(--background-black); + color: var(--text-white); + } + .product-item-label__tag--title{ + padding: 4px 2px; + + font-size: 16px; + line-height: 125%; + color: var(--text-black); + + display: flex; + align-items: center; + } + .product-item__product-card{ + height: 274px; + + display: flex; + justify-content: center; + align-items: center; + } + .product-item__images{ + height: 242px; + object-fit: contain; + } + .product-item__content-card{ + padding: 15.5px; + } + .product-item__title{ + margin-top: 8px; + + + font-weight: 500; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + text-decoration: none; + display: block; + } + .product-item__title:first-child{ + margin-top: 0; + } + .product-item__price{ + margin-top: 8px; + + display: flex; + align-items: center; + } + .product-item__price p{ + + font-weight: 700; + font-size: 20px; + line-height: 200%; + text-transform: uppercase; + color: var(--text-black); + } + .product-item__price p::after{ + content: '₽'; + padding-left: 5px; + } + .product-item__bye{ + margin-top: 8px; + } + .product-item__overlay{ + position: absolute; + top: 100%; + left: 0; + + width: 100%; + height: 100%; + + padding: 24px; + + display: flex; + flex-direction: column; + justify-content: space-between; + + border-radius: 24px; + backdrop-filter: blur(25px); + background-color: rgba(242, 242, 242, 0.8); + + z-index: 10; + + transition: top .4s ease-out; + } + .product-item-overlay__header{} + .product-item-overlay__tags{ + margin: 4px -6px -6px -6px; + + + font-weight: 500; + font-size: 12px; + line-height: 133%; + color: var(--text-3); + + display: flex; + flex-wrap: wrap; + + list-style-type: none; + } + .product-item-overlay__tags li{ + margin: 4px 6px; + + position: relative; + } + .product-item-overlay__tags li:nth-child(n+1)::after{ + content: ''; + + position: absolute; + top: 6px; + right: -8px; + + width: 4px; + aspect-ratio: 1; + + background-color: var(--text-3); + border-radius: 50%; + } + .product-item-overlay__tags li:last-child::after, + .product-item-overlay__tags li:last-child::before{ + display: none; + } + .product-item-overlay__price{ + margin-top: 32px; + + + font-weight: 700; + font-size: 24px; + line-height: 100%; + text-transform: uppercase; + text-align: right; + color: var(--text-black); + } + .product-item-overlay__price::after{ + content: '₽'; + } + .product-item-overlay__block-button{ + margin-top: 32px; + } + .product-item-overlay__button{ + margin-top: 16px; + } + .product-item-overlay__button:first-child{ + margin-top: 0; + } + .product-item-overlay__input-block{ + + } + .product-item-overlay__field{ + margin-top: 24px; + + display: flex; + justify-content: space-between; + align-items: center; + } + .product-item-overlay__field:first-child{ + margin-top: 0; + } + .product-item-overlay-field__title{ + + font-weight: 700; + font-size: 16px; + line-height: 125%; + color: var(--text-0); + } + .product-item__form{ + + } +/* product */ + +/* modal */ +/* .modal__button .to-know{ + display: none; +} */ +/* modal */ + +/* footer */ +/* footer */ + +/* detail */ +.detail{ + margin: 48px 24px 24px 24px; + + display: flex; + align-items: start; + flex-wrap: wrap; +} +.detail__images{ + margin: -12px; + width: calc(50% - 24px); + + display: flex; + flex-wrap: wrap; +} +.detail__image{ + margin: 12px; + + border-radius: 24px; + + display: flex; + align-items: center; + justify-content: center; + + background: var(--background-grey); + cursor: pointer; +} +.detail__content{ + margin-left: 48px; + width: calc(50% - 24px); + +} +.detail__label{ + margin: -2px; + display: flex; + align-items: center; +} +.detail__label .product-item-label__tag:last-child{ + margin-left: auto; +} +.detail__label .product-item-label__tag:first-child{ + margin-left: 0; +} +.detail__title{ + margin-top: 8px; + + + font-weight: 700; + font-size: 36px; + line-height: 111%; + text-transform: uppercase; + color: var(--text-black); +} +.detail__block-price{ + margin-top: 24px; + + display: flex; + align-items: center; +} +.detail-block-price__price{ + + font-weight: 700; + font-size: 36px; + line-height: 111%; + text-transform: uppercase; +} +.detail-block-price__price::after{ + content: '₽'; +} +.detail-block-price__sale{ + margin-left: 22px; + + display: flex; + align-items: center; +} +.detail-block-price-sale__text{ + + font-weight: 700; + font-size: 20px; + line-height: 120%; + text-transform: uppercase; + text-decoration: line-through; + color: var(--text-6); +} +.detail-block-price-sale__text::after{ + content: '₽'; +} +.detail-block-price-sale__perc{ + margin-left: 9px; + + + font-weight: 500; + font-size: 12px; + line-height: 133%; + color: var(--text-red); +} +.detail-block-price-sale__perc::before{ + content: '-'; +} +.detail-block-price-sale__perc::after{ + content: '%'; +} +.detail-block__form{ + margin-top: 48px; + + display: flex; + flex-direction: column; +} +.detail-block-form__item{ + margin-top: 24px; + + min-width: 345.89px; + + display: flex; + align-items: center; + flex-wrap: wrap; +} +.detail-block-form__item--radio{ + margin: 16px -8px -8px -8px; +} +.detail-block-form__item:first-child{ + margin-top: 0; +} +.detail-block-form__submit{ + min-width: 345.89px; +} +.detail__warning{ + padding: 3px; + + border-radius: 24px; + + background: var(--gradient-turquoise); +} +.detail-warning__content{ + padding: 26px; + + border-radius: 22px; + + background: var(--background-white); +} +.detail-warning__title{ + + font-weight: 700; + font-size: 24px; + line-height: 100%; + text-transform: uppercase; + color: var(--text-black); +} +.detail-warning__text{ + margin-top: 16px; + + + font-weight: 400; + font-size: 20px; + line-height: 120%; + color: var(--text-black); +} +.detail__toggle{ + margin-top: 48px; + margin-bottom: 48px; +} +.detail__wrapper-catalot{ + margin-top: 64px; + + width: calc(100% + 16px); + + overflow: hidden; + + position: relative; +} +.detail__catalot{ + +} +.detail-catalot__header{ + padding-right: 16px; + + display: flex; + justify-content: space-between; + align-items: center; +} +.detail-catalot__control{ + display: flex; + align-items: center; +} +.detail-catalot-control__button{ + margin-left: 24px; + + width: 48px; + aspect-ratio: 1; + + border-radius: 50%; + border: 1px solid var(--background-black); + background: none; + + display: flex; + justify-content: center; + align-items: center; +} +.detail-catalot__title{ + + font-weight: 700; + font-size: 24px; + line-height: 100%; + text-transform: uppercase; + text-align: start; + color: var(--text-0); +} +.detail-catalot__content{ + margin: 12px -12px -12px -12px; + + width: 100%; + + display: flex; +} +.detail__catalot .product__item{ + width: calc(100% - 24px); +} +.detail__images-phone{ + display: none; +} +.back-detail{ + display: none; +} +.toggle__table{ + margin-top: 32px; + + display: flex; + flex-wrap: wrap; +} +.toggle__table:first-child{ + margin-top: 0; +} +.toggle__table--three .toggle-table__block:nth-child(1){ + width: 40%; +} +.toggle__table--three .toggle-table__block:nth-child(2){ + width: 40%; +} +.toggle__table--three .toggle-table__block:nth-child(3){ + width: 20%; +} +.toggle__table--two .toggle-table__block{ + width: calc(50% - 20px); +} +.toggle__table--two .toggle-table__block:nth-child(even){ + margin-left: 40px; +} +.toggle-table__block{ + +} +.toggle-table__item{ + margin-top: 8px; + + width: 100%; + + display: flex; + justify-content: space-between; +} +.toggle-table__item p{ + display: block; + + + font-weight: 400; + font-size: 20px; + line-height: 120%; + color: var(--text-black); + + flex-shrink: 0; +} +.toggle-table__item .warning{ + width: 100%; +} +.toggle-table__item .warning p{ + + font-weight: 600; + font-size: 20px; + line-height: 120%; + text-align: center; +} +.toggle-table__title{ + margin-bottom: 16px; + + + font-weight: 700; + font-size: 16px; + line-height: 125%; + color: var(--text-black); +} +.toggle-table__title--center{ + text-align: center; +} +.toggle-table-item__line{ + margin: 23px 8px 0 8px; + + width: 100%; + + height: 1px; + background: linear-gradient(to right, transparent 50%, #fff 50%), linear-gradient(to right, #333, #333); + background-size: 4px 2px, 100% 2px; + + opacity: .6; +} + +.radio-button{ +} +.radio-button__input{ + display: none; +} +/* detail */ + +/* gallery */ +.gallery{ + position: fixed; + top: 0; + right: 0; + bottom: 0; + left: 0; + + padding: 24px; + + display: flex; + align-items: center; + + background: var(--background-white); + + pointer-events: none; + opacity: 0; + transition: opacity .2s ease-out; + + z-index: 300; +} +.gallery__close{ + position: absolute; + top: 24px; + right: 24px; + + z-index: 10; +} +.gallery__pagination{ + margin: -12px; +} +.gallery-pagination__item{ + margin: 12px; + + width: 134px; + height: 136px; + + display: flex; + justify-content: center; + align-items: center; + + border: none; + border-radius: 16px; + background: var(--background-grey); +} +.gallery-pagination__item img{ + width: 90%; + max-height: 90%; + + object-fit: contain; +} +.gallery__slider{ + margin-left: 48px; + + padding: 100px; +} +.gallery__slider{ + width: 100%; +} +.gallery__slider .swiper-pagination{ + display: none; +} +.gallery__slider .swiper-button-next::after, +.gallery__slider .swiper-button-prev::after{ + display: none; +} +.gallery-button{ + width: 48px; + height: 48px; + + display: flex; + justify-content: center; + align-items: center; + + border: 1px solid var(--background-black); + border-radius: 20px; + + background: none; +} +.gallery__slider .swiper-slide{ + display: flex; + justify-content: center; + align-items: center; +} +.gallery__block{ + width: 600px; + height: 774px; + + display: flex; + justify-content: center; + align-items: center; + + background: var(--background-grey); + border-radius: 24px; +} +.gallery__block img{ + width: 90%; + max-height: 90%; + + object-fit: contain; +} +.gallery__wrapper{ + margin: 0 auto; + max-width: 1600px; + + display: flex; + align-items: center; +} +/* .swiper { + width: 600px; + height: 300px; +} */ + +/* gallery */ + + +/* cabinet */ +/* .cabinet-card-no-orders__ */ +/* cabinet */ + +@media only screen and (max-width: 1600px) { + +.wrapper{ + max-width: 1280px; +} + +.product__item{ + margin: 12px; + + width: calc(33.3% - 24px); +} + +.gallery__wrapper{ + max-width: 1280px; +} +} + +@media only screen and (max-width: 1365px) { + .gallery__wrapper{ + max-width: 100%; + } + +} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-mobile.css b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-mobile.css new file mode 100644 index 0000000..cc6600d --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-mobile.css @@ -0,0 +1,38 @@ +/* Стили для мобильных устройств */ +@media only screen and (max-width: 720px) { +/* product */ +.product__item{ + width: calc(100% - 24px); +} +/* product */ + +} +/* detail */ +.toggle__table--two .toggle-table__block{ + width: 100%; +} +.toggle__table--two .toggle-table__block:nth-child(even){ + margin-top: 32px; + margin-left: 0; +} +.toggle__table--three .toggle-table__block:nth-child(1){ + width: 31%; +} +/* detail */ + +@media only screen and (max-width: 576px) { +/* header */ + +/* header */ + +/* product */ +.product__header{ + flex-direction: column; + align-items: start; +} +.product__header .button{ + margin-top: 48px; +} +/* product */ + +} diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-tablet.css b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-tablet.css new file mode 100644 index 0000000..e59949c --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/css/gp-style-tablet.css @@ -0,0 +1,348 @@ +/* Стили для планшетов */ +@media only screen and (max-width: 1200px) { +/* header */ +main{ + padding-top: 64px; +} +.main-menu{ + display: none; +} +.header__open-menu{ + display: block; +} +.lang{ + display: none; +} +.header__logo{ + width: 136px; + height: 29px; +} +.header__content{ + height: auto; + + padding: 8px 16px; +} +.mini-profile__item:nth-child(2){ + margin-left: 0; +} +.header::after{ + left: 0; + + width: 100%; +} +.header__pc-menu{ + display: none; +} +.header__phone-menu{ + display: block; +} +.header__menu-block{ + top: 56px; +} +.header__content::after{ + left: 0; + right: 0; + width: 100%; +} +/* header */ + +/* footer */ +.footer{ + margin-top: 0; + + padding: 24px 16px; +} +/* footer */ + +/* breadcrumbs */ +.breadcrumbs{ + display: none; +} +/* breadcrumbs */ + +/* product */ +.product{ + padding: 12px; + padding-top: 20px; +} +.product__title{ + font-weight: 700; + font-size: 26px; + line-height: 123%; + text-transform: uppercase; +} +.to-know p { + font-size: 18px; +} +.toggle-table__title{ + font-weight: 700; + font-size: 12px; + line-height: 133%; +} +.toggle-table__item p{ + font-weight: 500; + font-size: 12px; + line-height: 133%; +} +.toggle-table-item__line{ + margin-top: 12px; +} +.detail{ + margin: 24px 16px; +} +.back-detail{ + display: inline; +} +.detail-catalot__title{ + font-size: 22px; +} +.product__footer--error{ + margin: 48px 0px 24px; +} +/* product */ + +/* modal */ +.modal{ + padding: 0; +} +.modal__text{ + padding-right: 0; +} +.form__button-pc{ + display: none; +} +.form__button-mobile{ + display: block; +} +.modal-form{ + /* min-height: 100%; + width: 100%; + + border-radius: 0; + border: none; */ +} +.modal__notification{ + margin: 24px; +} +.form-input-phone__list{ + left: 0; +} + +.modal-form-content__line--two{ + flex-wrap: wrap; +} +.modal-form-content__line--two .modal-form-content-line__element{ + margin-top: 24px; + + width: 100%; +} +.modal-form-content__line--two .modal-form-content-line__element:first-child{ + margin-top: 0; +} +.modal-map{ + width: 100%; + + flex-direction: column; + + border-radius: 0; +} +.modal-map__left, .modal-map__right{ + width: 100%; +} +.modal-map__map iframe { + width: 100%; + height: 528px; +} +.modal-map-form__button{ + display: none; +} +.modal-map-form__sub-button{ + margin-top: 64px; + + padding: 0 24px; + + display: flex; + } +/* modal */ + +/* cabinet */ +.cabinet{ + flex-direction: column; + + position: relative; +} +.cabinet__control{ + display: flex; + + position: relative; +} +.cabinet__orders, .cabinet__profile{ + width: calc(100% - 48px); +} +.cabinet__orders, .cabinet__profile{ + position: absolute; + opacity: 0; + + transition: opacity .2s ease-out; +} +.cabinet-content{ + pointer-events:none; +} +.cabinet__orders.active, .cabinet__profile.active{ + opacity: 1; +} +.cabinet__orders.hide, .cabinet__profile.hide{ + position: static; + display: block; + pointer-events:auto; + + width: 100%; +} +.cabinet__subscription-pc{ + display: none; +} +.cabinet__subscription-mobile{ + display: block; + + margin: 24px 24px 0 24px; +} +.cabinet__orders .cabinet-card:nth-child(2){ + margin-top: 0; + } + .cabinet__orders--no-cab .cabinet-card:nth-child(2){ + margin-top: 32px; + } +/* cabinet */ +} + +@media only screen and (max-width: 980px) { +/* product */ +.product__item{ + width: calc(50% - 24px); +} +/* product */ + + +/* detail */ +.detail{ + flex-direction: column; +} +.detail__images{ + display: none; +} +.detail__content{ + width: 100%; +} +.detail__content{ + margin-left: 0; +} + +.detail__images-phone{ + display: block; + + margin-top: 48px; + margin-bottom: 48px; + + position: relative; + + overflow: hidden; +} +.detail__images-phone .swiper-slide{ + display: flex; + justify-content: center; +} +.detail-images-phone__image-block{ + width: 100%; + aspect-ratio: 1; + max-width: 500px; + + display: flex; + justify-content: center; + align-items: center; + + background: var(--background-grey); + border-radius: 16px; +} + +.detail__images-phone .swiper-pagination-bullet{ + width: 8px; + height: 8px; + + border-radius: 50%; + + border: 1px solid #666; + background-color: #666; + + opacity: 1; +} +.detail__images-phone .swiper-pagination-bullet.swiper-pagination-bullet-active{ + background-color: var(--background-white); +} + +.detail__images-phone .swiper-pagination{ + margin-bottom: 19px; +} +.detail__title{ + font-size: 26px; + line-height: 123%; +} +.gallery__slider .swiper-pagination { + display: block; +} +.gallery__pagination{ + display: none; +} + +.gallery__slider .swiper-pagination-bullet{ + width: 8px; + height: 8px; + border-radius: 50%; + border: 1px solid #666; + background-color: #666; + opacity: 1; +} +.gallery__wrapper .gallery-button{ + display: none; +} + +.gallery__slider .swiper-pagination-bullet.swiper-pagination-bullet-active{ + background-color: var(--background-white); +} + +.gallery__slider{ + margin-left:0; + padding: 0px 0px 50px 0px; + /* padding: 40px; */ +} +.gallery__block { + width: 100%; + aspect-ratio: 1; + height: auto; +} +/* detail */ +} + +@media only screen and (max-width: 750px) { +/* cabinet */ +.cabinet-card-order__open-detail{ + margin-top: 144px; +} +.cabinet-card-order__detail-short{ + right: auto; + left: 0; + bottom: 48px; +} +.cabinet-card-order-detail-short__item{ + margin-left: -27px; +} +.cabinet-card-order-detail-short__item:first-child{ + margin-left: 0; +} +.cabinet-card__order.active .cabinet-card-order__open-detail{ + margin-top: 24px; +} +.cabinet-card-order__link{ + margin-top: 144px; +} +/* cabinet */ +} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-breadcrumbs.svg b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-breadcrumbs.svg new file mode 100644 index 0000000..f1f9618 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-breadcrumbs.svg @@ -0,0 +1,3 @@ + + + diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-left.svg b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-left.svg new file mode 100644 index 0000000..465c268 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-left.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-right.svg b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-right.svg new file mode 100644 index 0000000..8952470 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/arrow-right.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/black-x.svg b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/black-x.svg new file mode 100644 index 0000000..cb3041d --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/img/svg/main/black-x.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-main.js b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-main.js new file mode 100644 index 0000000..a1bc687 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-main.js @@ -0,0 +1,348 @@ +'use strict'; + +// header +toggleOpenX('.lang', '.lang__open', '.lang__list', '.lang__content', false); +toggleHeader('#pc-menu','.header__menu-block','.header__pc-menu', '.white', 'white'); +toggleHeader('#phone-menu','.header__menu-block','.header__phone-menu', '.white', 'white'); +// header + +// modal +modalOpen('.button--filter', '.modal__filter'); +modalOpen('.basket-open', '.modal__basket'); +modalOpen('.open-to-know', '.modal__to-know'); +modalClose('.modal__close'); + +let modal = document.querySelector('.modal'); + +modal.onclick = function (event) { + let target = event.target; + + if (target.classList.contains('modal')) { + let aside = target.querySelector('.modal__aside'), + modalItem = target.querySelector('.modal__item.active'); + + aside.style.width = '0px'; + setTimeout(() => { + modalItem.style.cssText = ''; + modalItem.classList.remove('active'); + target.classList.remove('active'); + }, 300); + } +} + +// modal + +// toggle +toggleOpenX('.toggle', '.toggle__title', '.toggle__content', '.toggle__block-content', true); +// toggle + +// // radio-button +// let radioButtons = document.querySelectorAll('.radio-button'); + +// radioButtons.forEach(radioBlock => { +// let buttons = radioBlock.querySelectorAll('.button'); + +// buttons.forEach(button => { +// let input = radioBlock.querySelector('.radio-button__input'); + +// button.onclick = function (e) { +// e.preventDefault(); + +// buttons.forEach(thisButton => { +// if (thisButton.classList.contains('active')) { +// thisButton.classList.remove('active') +// } +// }) + +// let text = button.textContent.trim(); + +// button.classList.toggle('active'); + +// input.value = text; +// } +// }) +// }) +// // radio-button + +// overlay +let products = document.querySelectorAll('.product__item'); + +products.forEach(productItem => { + let button = productItem.querySelector('.open-overlay'), + overlay = productItem.querySelector('.product-item__overlay'); + + + if (button) { + button.onclick = function (e) { + document.querySelectorAll('.product__item').forEach(e => { + if (e.classList.contains('active')) { + e.classList.remove('active'); + } + }); + document.querySelectorAll('.product-item__overlay').forEach(e => { + if (e.classList.contains('active')) { + e.classList.remove('active'); + } + }); + + productItem.classList.toggle('active'); + overlay.classList.toggle('active'); + } + } + +}) +// overlay + + +// select +toggleOpenX('.select', '.select__state' , '.state__content', '.state__block', true); + +let selects = document.querySelectorAll('.select'); + +selects.forEach(select => { + let state = select.querySelector('.select__state'), + content = select.querySelector('.state__block'), + buttons = select.querySelectorAll('.state__button'); + + buttons.forEach(e => { + let button = e; + + e.onclick = function (event) { + event.preventDefault(); + + buttons.forEach(element => { + if (element.classList.contains('active')) { + element.classList.remove('active'); + } + }) + + let text = e.textContent.trim(); + state.value = text; + + button.classList.add('active'); + content.style.height = 0; + select.classList.remove('active'); + } + }) +}) +// select + +// counter +let counters = document.querySelectorAll('.counter'); + +counters.forEach(e => { + let minus = e.querySelector('.minus'), + plus = e.querySelector('.plus'), + input = e.querySelector('.counter__input'); + + minus.onclick = function (e) { + e.preventDefault(); + + let number = input.value; + + if (number >= 2){ + input.value = Number(number) - 1; + } + } + + plus.onclick = function (e) { + e.preventDefault(); + + let number = input.value; + + if (number <= 99) { + input.value = Number(number) + 1; + } + } +}) +// counter + +// checkbox +let checkbox = document.querySelectorAll('.checkbox'); + +checkbox.forEach(e => { + e.onclick = function (event) { + let input = e.querySelector('.checkbox__input'); + + if (!e.classList.contains('active')) { + input.checked = 1; + }else{ + input.checked = 0; + } + e.classList.toggle('active'); + } +}) +// checkbox + + +// function +function modalOpen(buttonElement, contentElement){ + let modal = document.querySelector('.modal'), + aside = document.querySelector('.modal__aside'), + elements = document.querySelectorAll(buttonElement), + device = window.screen.width; + + elements.forEach(e => { + let thisContentElement = document.querySelector(contentElement); + + e.onclick = function () { + modal.classList.add('active'); + thisContentElement.classList.add('active'); + + let width = thisContentElement.clientWidth; + + setTimeout(() => { + if (device <= 720) { + aside.style.width = `${device}px`; + thisContentElement.style.opacity = 1; + thisContentElement.style.filter = 'blur(0px)'; + }else{ + aside.style.width = `${width}px`; + thisContentElement.style.opacity = 1; + thisContentElement.style.filter = 'blur(0px)'; + } + }, 10); + } + }) +} + +function modalClose(buttonElement) { + let modal = document.querySelector('.modal'), + aside = document.querySelector('.modal__aside'), + asideItems = document.querySelectorAll('.modal__item'), + elements = document.querySelectorAll(buttonElement); + + elements.forEach(e => { + e.onclick = function () { + aside.style.width = '0px'; + + asideItems.forEach(e => { + if (e.classList.contains('active')) { + e.style.filter = 'blur(10px)'; + } + }); + + setTimeout(() => { + asideItems.forEach(e => { + if (e.classList.contains('active')) { + e.classList.remove('active'); + } + }); + + modal.classList.remove('active'); + }, 300); + } + }) +} + +function toggleOpenX(mainElement, buttonElement ,heightElement, contentElement, close) { + let elements = document.querySelectorAll(mainElement); + + elements.forEach(e => { + let thisMainElement = e, + thisButtonElement = e.querySelector(buttonElement), + thisHeightElement = e.querySelector(heightElement), + thisContentElement = e.querySelector(contentElement); + + thisButtonElement.onclick = function (e) { + let height = thisHeightElement.clientHeight; + + if (close == true && !thisMainElement.classList.contains('active')) { + elements.forEach(e => { + if (e.classList.contains('active')) { + e.classList.remove('active'); + e.querySelector(contentElement).style.height = null + } + }) + } + + if (!thisMainElement.classList.contains('active')) { + thisContentElement.style.height = `${height}px`; + thisMainElement.classList.add('active'); + }else{ + thisContentElement.style.height = null; + thisMainElement.classList.remove('active'); + } + } + + }); +} + +function toggleHeader(button, content, blockheight, removeBlock, removeClass) { + let thisButton = document.querySelector(button), + thisContent = document.querySelector(content), + thisRemoveBlock = document.querySelector(removeBlock) || '', + thisBlockheight = document.querySelector(blockheight); + + thisButton.onclick = function () { + let height = thisBlockheight.clientHeight; + + if (!thisContent.classList .contains('open')) { + thisContent.style.height = `${height}px`; + thisContent.classList .add('open'); + + if (removeBlock) { + thisRemoveBlock.classList.remove(removeClass); + } + }else{ + thisContent.style.height = null; + thisContent.classList .remove('open'); + + if (removeBlock) { + if (window.scrollY <= 25) { + thisRemoveBlock.classList.add(removeClass); + } + } + } + } +} +// function + +// resize +window.addEventListener('resize', (e) => { + let width = window.screen.width; + + // media + modalOpen('.button--filter', '.modal__filter'); + modalOpen('.basket-open', '.modal__basket'); + modalOpen('.open-to-know', '.modal__to-know'); + modalClose('.modal__close'); + + let modalItem = document.querySelectorAll('.modal__item'); + + // if (width <= 720) { + modalItem.forEach(modal => { + if (modal.classList.contains('active')) { + let aside = document.querySelector('.modal__aside'); + + if (width <= 720) { + aside.style.width = `${width}px` + }else{ + let openAside = document.querySelector('.modal__item.active'), + newWidth = openAside.clientWidth; + + aside.style.width = `${newWidth}px` + } + } + }) + // } +}); +// resize + +// scroll + + +if (document.querySelector('.header').classList.contains('white')) { + window.addEventListener("scroll", function (e) { + let header = document.querySelector('.header'); + let scroll = window.scrollY; + + if (scroll >= 25) { + header.classList.remove('white') + }else{ + header.classList.add('white') + } + + }); +} +// scroll diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-product.js b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-product.js new file mode 100644 index 0000000..2508270 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/gp-product.js @@ -0,0 +1,110 @@ +'use strict'; + +// slider gallery modal +const gallery = new Swiper('.gallery__slider', { + spaceBetween: 100, + + pagination: { + el: '.swiper-pagination', + }, + + navigation: { + nextEl: '.swiper-button-next', + prevEl: '.swiper-button-prev', + }, + + scrollbar: { + el: '.swiper-scrollbar', + }, +}); + +let paginationButtons = document.querySelectorAll('.gallery-pagination__item'); + +paginationButtons.forEach(button => { + let index = button.dataset.countImg; + + button.onclick = function () { + gallery.slideTo(index); + } +}) + +// open gallery +let detailImage= document.querySelectorAll('.detail__image'); +detailImage.forEach(button => { + let index = button.dataset.countImg; + + button.onclick = function () { + gallery.slideTo(index); + + document.querySelector('.gallery').classList.add('active'); + } +}) + +// close gallery + +document.querySelector('.gallery__close').onclick = function () { + document.querySelector('.gallery').classList.remove('active'); +} +// slider gallery modal + +// slider gallery main phone + +// createGalleryPhone('.detail__images', '.detail-images__wrapper', '.detail__image', 980); + +const detailPhone = new Swiper('.detail__images-phone', { + spaceBetween: 100, + + pagination: { + el: '.swiper-pagination', + }, + + navigation: { + nextEl: '.swiper-button-next', + prevEl: '.swiper-button-prev', + }, + + scrollbar: { + el: '.swiper-scrollbar', + }, +}); + +let detailImagesPhones = document.querySelectorAll('.detail-images-phone__image-block'); + +detailImagesPhones.forEach(button => { + button.onclick = function (e) { + let index = button.dataset.countImg; + + gallery.slideTo(index); + + document.querySelector('.gallery').classList.add('active'); + } +}) + +// slider gallery main phone + +// detail catalog +const detailCatalot = new Swiper('.detail__catalot', { + // Navigation arrows + navigation: { + nextEl: '.detail-catalot-control__button.next', + prevEl: '.detail-catalot-control__button.prev', + }, + breakpoints: { + 1600: { + slidesPerView: 4, + }, + 1200: { + slidesPerView: 3, + }, + 780: { + slidesPerView: 2, + }, + 100: { + slidesPerView: 1.1, + spaceBetween: 20 + }, + } + + +}); +// detail catalog \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/tabs.js b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/tabs.js new file mode 100644 index 0000000..10c8130 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/tabs.js @@ -0,0 +1,67 @@ +const rootSelectorTabs = '[data-js-tabs]'; + +class Tabs{ + // элементы для поиска + selectors = { + root: rootSelectorTabs, + button: '[data-js-tabs-button]', + content: '[data-js-tabs-content]', + } + // класс отображения состояния + stateClasses = { + isActive: 'active', + } + + constructor(rootElement){ + this.rootElement = rootElement; + this.buttonElements = this.rootElement.querySelectorAll(this.selectors.button); + this.contentElements = this.rootElement.querySelectorAll(this.selectors.content); + this.state = { + activeMenuIndex: [...this.buttonElements] + .findIndex((buttonElement) => buttonElement.classList.contains(this.stateClasses.isActive)), + }; + this.limitTabsIndex = this.buttonElements.length - 1; + this.bindEvents(); + } + + updateUI(){ + const { activeMenuIndex } = this.state; + + this.buttonElements.forEach((buttonElement, index) => { + const isActive = index === activeMenuIndex; + + buttonElement.classList.toggle(this.stateClasses.isActive, isActive); + }) + + this.contentElements.forEach((contentElement, index) => { + const isActive = index === activeMenuIndex; + + contentElement.classList.toggle(this.stateClasses.isActive, isActive); + }) + } + + onButtonClick(buttonIndex){ + this.state.activeMenuIndex = buttonIndex; + this.updateUI(); + } + + bindEvents(){ + this.buttonElements.forEach((buttonElement, index) => { + buttonElement.addEventListener('click', () => this.onButtonClick(index)) + }) + } +} + +class TabsCollection { + constructor(){ + this.init(); + } + + init(){ + document.querySelectorAll(rootSelectorTabs).forEach((element) => { + new Tabs(element); + }); + } +} + +export default TabsCollection; \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/toggle.js b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/toggle.js new file mode 100644 index 0000000..bb162e9 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/assets/js/toggle.js @@ -0,0 +1,89 @@ +const rootSelectorToggles = '[data-js-toggle]'; + +class Toggle{ + // элементы для поиска + selectors = { + root: rootSelectorToggles, + button: '[data-js-toggle-button]', + wrapper: '[data-js-toggle-wrapper]', + content: '[data-js-toggle-content]', + } + // класс отображения состояния + stateClasses = { + isActive: 'active', + } + + constructor(rootElement){ + this.rootElement = rootElement; + this.buttonElements = this.rootElement.querySelectorAll(this.selectors.button); + this.wrapperElements = this.rootElement.querySelectorAll(this.selectors.wrapper); + this.contentElements = this.rootElement.querySelectorAll(this.selectors.content); + this.state = { + activeToggleIndex: [...this.buttonElements] + .findIndex((buttonElement) => buttonElement.classList.contains(this.stateClasses.isActive)), + }; + this.bindEvents(); + } + + updateUI(newHeight){ + const { activeToggleIndex } = this.state; + + this.buttonElements.forEach((buttonElement, index) => { + const isActive = index === activeToggleIndex; + + buttonElement.classList.toggle(this.stateClasses.isActive, isActive); + }) + + this.wrapperElements.forEach((wrapperElement, index) => { + const isActive = index === activeToggleIndex, + newHeight = this.contentElements[index].offsetHeight; + + wrapperElement.classList.toggle(this.stateClasses.isActive, isActive); + + if (isActive) { + wrapperElement.style.height = `${newHeight}px`; + + setTimeout(() => { + if (wrapperElement.classList.contains('active')) { + wrapperElement.style.height = `auto`; + } + }, 300); + }else{ + wrapperElement.style.height = `${newHeight}px`; + + setTimeout(() => { + if (!wrapperElement.classList.contains('active')) { + wrapperElement.style.height = `${0}px`; + } + }, 10); + } + }) + + } + + onButtonClick(buttonIndex){ + this.state.activeToggleIndex = (buttonIndex === this.state.activeToggleIndex) ? -1 : buttonIndex; + + this.updateUI(); + } + + bindEvents(){ + this.buttonElements.forEach((buttonElement, index) => { + buttonElement.addEventListener('click', () => this.onButtonClick(index)) + }) + } +} + +class TogglesCollection{ + constructor(){ + this.init(); + } + + init(){ + document.querySelectorAll(rootSelectorToggles).forEach((element) => { + new Toggle(element); + }); + } +} + +export default TogglesCollection; \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/component-controller.php b/wp-content/themes/cosmopet/modules/shop/components/single-product/component-controller.php new file mode 100644 index 0000000..e5aca87 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/component-controller.php @@ -0,0 +1,74 @@ +get_attributes(); + + if (!empty($product_attributes)) { + foreach ($product_attributes as $taxonomy => $attribute) { + if ($attribute->is_taxonomy()) { + $terms = wc_get_product_terms($product_id, $taxonomy, ['fields' => 'all']); + if (!empty($terms)) { + $attr_values = []; + foreach ($terms as $term) { + $attr_values[] = [ + 'name' => $term->name, + 'slug' => $term->slug, + 'term_id' => $term->term_id, + 'link' => get_term_link($term->term_id, $taxonomy), + ]; + } + $attributes[wc_attribute_label($taxonomy)] = $attr_values; + } + } else { + $attributes[wc_attribute_label($taxonomy)] = $attribute->get_options(); + } + } + } + + $context['product_attributes'] = $attributes; + + if ($product->is_type('variable')) { + $available_variations = $product->get_available_variations(); + $variations_data = []; + + foreach ($available_variations as $variation) { + $variation_id = $variation['variation_id']; + $variation_obj = wc_get_product($variation_id); + + $variations_data[] = [ + 'variation_id' => $variation_id, + 'price' => $variation_obj->get_price(), + 'regular_price' => $variation_obj->get_regular_price(), + 'sale_price' => $variation_obj->get_sale_price(), + 'attributes' => $variation['attributes'] + ]; + } + + $context['variations'] = $variations_data; + } + + $meta_fields = [ + 'composition' => get_post_meta($product_id, '_composition', true), + 'feeding_recommendations' => get_post_meta($product_id, '_feeding_recommendations', true), + 'feeding_recommendations_table' => get_field('feeding_recommendations_table', $product_id), + + 'nutritional_value' => get_post_meta($product_id, '_nutritional_value', true), + 'vitamins' => get_post_meta($product_id, '_vitamins', true), + 'additives' => get_post_meta($product_id, '_additives', true), + 'energy_value' => get_post_meta($product_id, '_energy_value', true), + 'important' => get_post_meta($product_id, '_important', true), + ]; + + $context['product_meta'] = $meta_fields; + } + } + + return $context; +}); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/components/single-product/component-template.twig b/wp-content/themes/cosmopet/modules/shop/components/single-product/component-template.twig new file mode 100644 index 0000000..7fd37a6 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/components/single-product/component-template.twig @@ -0,0 +1,447 @@ + + + {% set bodyClass = 'bg-white' %} + + {% set mainClass = 'wrapper' %} + + {% extends 'layout.twig' %} + + {% block content %} +
+ + + + {{ function('pll_e', 'к каталогу') }} + + +
+
+ {% for image in gallery_images %} +
+ {{ image.alt }} +
+ {% endfor %} +
+
+ +
+
+ {% if product_attributes.Flavor is defined and product_attributes.Flavor|length > 0 %} +
+ {{ product_attributes.Flavor[0].name }} +
+ {% endif %} + {% if product_attributes.Вкус is defined and product_attributes.Вкус|length > 0 %} + + {% endif %} + + {% if product_attributes.Тег is defined and product_attributes.Тег|length > 0 %} + + {% endif %} + {% if product.is_on_sale() %} +
+ {{ function('pll_e', 'Распродажа') }} % +
+ {% endif %} +
+

+ {{ product.get_title }} +

+ +
+
+ {% for image in gallery_images %} +
+
+ {{ image.alt }} +
+
+ {% endfor %} +
+
+
+ +
+

+ {{ product.get_price }} +

+ + {% if product.is_on_sale() %} +
+

+ {{ product.get_regular_price }} +

+

+ {{ ((product.get_regular_price - product.get_price) / product.get_regular_price * 100)|round }} +

+
+ {% endif %} +
+
+ {% set collection = fn('wc_get_product_terms', product.id, 'pa_collection') %} + {% if collection %} + {% set siblings = function('get_collection_siblings', collection[0].term_id) %} + {% if siblings %} +
+ {% for sibling in siblings %} + {% set weight = sibling.post_title|split(', ')|last %} + {% set current_weight = function('get_product_info', product.id, 'weight') %} + {% set class = weight == current_weight ? 'active' : '' %} + + {{ weight|upper }} + + {% endfor %} + +
+ {% endif %} + {% endif %} + + + +
+ +
+
+ +
+
+

+ {{ function('pll_e', 'ОПИСАНИЕ') }} +

+
+
+

+ {{ product.get_description() }} +

+
+
+
+ + {% if product_meta.composition %} +
+

+ {{ function('pll_e', 'СОСТАВ') }} +

+
+
+

+ {{ product_meta.composition }} +

+
+
+
+ {% endif %} + + {% if product_meta.feeding_recommendations_table %} +
+

+ {{ function('pll_e', 'РЕКОМЕНДАЦИИ ПО КОРМЛЕНИЮ') }} +

+
+
+
+ {% if product_meta.feeding_recommendations_table.header %} +
+

{{ product_meta.feeding_recommendations_table.header.0 is iterable ? product_meta.feeding_recommendations_table.header.0|join(', ') : product_meta.feeding_recommendations_table.header.0 }}

+ {% for row in product_meta.feeding_recommendations_table.body %} +
+

{{ row.0 is iterable ? row.0|join(', ') : row.0 }}

+
+
+ {% endfor %} +
+
+

{{ product_meta.feeding_recommendations_table.header.1 is iterable ? product_meta.feeding_recommendations_table.header.1|join(', ') : product_meta.feeding_recommendations_table.header.1 }}

+ {% for row in product_meta.feeding_recommendations_table.body %} +
+

{{ row.1 is iterable ? row.1|join(', ') : row.1 }}

+
+
+ {% endfor %} +
+
+

{{ product_meta.feeding_recommendations_table.header.2 is iterable ? product_meta.feeding_recommendations_table.header.2|join(', ') : product_meta.feeding_recommendations_table.header.2 }}

+ {% for row in product_meta.feeding_recommendations_table.body %} +
+

{{ row.2 is iterable ? row.2|join(', ') : row.2 }}

+
+ {% endfor %} +
+ {% endif %} +
+
+
+
+ {% elseif product_meta.feeding_recommendations %} +
+

+ {{ function('pll_e', 'РЕКОМЕНДАЦИИ ПО КОРМЛЕНИЮ') }} +

+
+
+ {{ product_meta.feeding_recommendations }} +
+
+
+ {% endif %} + + {% if product_meta.nutritional_value or product_meta.vitamins or product_meta.additives or product_meta.energy_value %} +
+

+ {{ function('pll_e', 'ПИЩЕВАЯ ЦЕННОСТЬ') }} +

+
+
+ {% if product_meta.nutritional_value and product_meta.vitamins %} +
+
+

{{ function('pll_e', 'ПИЩЕВАЯ ЦЕННОСТЬ') }}

+ {{ product_meta.nutritional_value }} +
+
+

{{ function('pll_e', 'ВИТАМИНЫ НА КГ') }}

+ {{ product_meta.vitamins }} +
+
+ {% endif %} + + {% if product_meta.additives or product_meta.energy_value %} +
+ {% if product_meta.additives %} +
+

{{ function('pll_e', 'ПИТАТЕЛЬНЫЕ ДОБАВКИ НА КГ') }}

+ {{ product_meta.additives }} +
+ {% endif %} + + {% if product_meta.energy_value %} +
+

{{ function('pll_e', 'ЭНЕРГЕТИЧЕСКАЯ ЦЕННОСТЬ НА 100 ГРАММ') }}

+
+
+
+

{{ product_meta.energy_value }}

+
+
+
+
+ {% endif %} +
+ {% endif %} +
+
+
+ {% endif %} + + +
+ + +
+
+

{{ function('pll_e', 'Важно') }}

+

+ {{ product_meta.important }} +

+
+
+
+ + {% set recommended_products = function('get_field', 'recommended_products', product.id) %} + {% set related_products = recommended_products ? recommended_products : function('wc_get_related_products', product.id, 4) %} + {% if related_products %} +
+
+
+

+ {{ function('pll_e', 'вашему питомцу может понравиться') }} +

+ +
+ + + +
+
+
+ {% for related_product in related_products %} +
+ {% set post_id = related_product.ID is defined ? related_product.ID : related_product %} + {% set wc_product = fn('wc_get_product', post_id) %} + {% if wc_product %} +
+
+ {% if wc_product.get_date_created|date('Y-m-d') >= criteria_for_new_product %} + + {{ function('pll_e', 'Новинка') }} + + {% endif %} + + {% if wc_product.is_on_sale() %} + + {{ function('pll_e', 'Распродажа %') }} + + {% endif %} +
+ + {{ wc_product.get_name() }} + +
+
+ {% set compound = fn('wc_get_product_terms', post_id, 'pa_compound') %} + {% for option in compound %} + {% set term = get_term(option) %} + {{ term.name }} + {% endfor %} +
+ {{ wc_product.get_name() }} +
+

{{ wc_product.get_price() }}

+
+
+ +
+
+
+
+ {{ wc_product.get_name() }} +
    + {% set features = fn('wc_get_product_terms', post_id, 'pa_features') %} + {% for option in features %} + {% set term = get_term(option) %} +
  • {{ term.name }}
  • + {% endfor %} +
+
+ +
+
+
+

Объем

+ +
+ {% set cur_weight = function('get_product_info', post_id, 'weight') %} + +
+
    + {% set collection = fn('wc_get_product_terms', post_id, 'pa_collection') %} + {% for option in collection %} + {% set term = get_term(option) %} + {% if term %} + {% set siblings = function('get_collection_siblings', term.term_id) %} + + {% for sibling in siblings %} + {% set weight = function('get_product_info', sibling.ID, 'weight') %} + + {% set class = '' %} + {% if weight == cur_weight %} + {% set class = 'active' %} + {% endif %} +
  • + +
  • + {% endfor %} + {% endif %} + {% endfor %} +
+
+
+
+
+

Количество

+ +
+ + + +
+
+
+

+ {{ wc_product.get_price() }} +

+
+
+ {{ function('get_add_to_cart_button', post_id) }} +
+ +
+
+
+
+ {% endif %} +
+ {% endfor %} +
+
+
+ {% endif %} +
+ + + +
+ {% endblock %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/modules/shop/module-controller.php b/wp-content/themes/cosmopet/modules/shop/module-controller.php new file mode 100644 index 0000000..9c541f6 --- /dev/null +++ b/wp-content/themes/cosmopet/modules/shop/module-controller.php @@ -0,0 +1,56 @@ +get_gallery_image_ids(); + $gallery_images = []; + + $main_image_id = $product->get_image_id(); + if ($main_image_id) { + $gallery_images[] = [ + 'id' => $main_image_id, + 'src' => wp_get_attachment_image_url($main_image_id, 'full'), + 'alt' => get_post_meta($main_image_id, '_wp_attachment_image_alt', true) + ]; + } + + foreach ($attachment_ids as $attachment_id) { + $gallery_images[] = [ + 'id' => $attachment_id, + 'src' => wp_get_attachment_image_url($attachment_id, 'full'), + 'alt' => get_post_meta($attachment_id, '_wp_attachment_image_alt', true) + ]; + } + + $context['gallery_images'] = $gallery_images; + + $related_products_ids = wc_get_related_products($product_id, 5); + if (!empty($related_products_ids)) { + $related_products = []; + foreach ($related_products_ids as $related_id) { + $related_product = wc_get_product($related_id); + if ($related_product) { + $related_products[] = $related_product; + } + } + $context['related_products'] = $related_products; + } + } + } + + return $context; + }); \ No newline at end of file diff --git a/wp-content/themes/cosmopet/single-blog_author.php b/wp-content/themes/cosmopet/single-blog_author.php new file mode 100644 index 0000000..a2ac841 --- /dev/null +++ b/wp-content/themes/cosmopet/single-blog_author.php @@ -0,0 +1,6 @@ + \ No newline at end of file diff --git a/wp-content/themes/cosmopet/single-product.php b/wp-content/themes/cosmopet/single-product.php new file mode 100644 index 0000000..ad3e75f --- /dev/null +++ b/wp-content/themes/cosmopet/single-product.php @@ -0,0 +1,60 @@ + '', + 'wrap_before' => '', + 'wrap_after' => '', + 'before' => '', + 'after' => '', + 'home' => _x('Home', 'breadcrumb', 'woocommerce'), + ); + + $breadcrumbs = new WC_Breadcrumb(); + $breadcrumbs->generate(); + + $formatted_breadcrumbs = array(); + foreach ($breadcrumbs->get_breadcrumb() as $crumb) { + $formatted_breadcrumbs[] = array( + 'text' => $crumb[0], + 'url' => $crumb[1] + ); + } + + $context['wc_breadcrumbs'] = $formatted_breadcrumbs; + } + + $product_id = get_the_ID(); + $product = wc_get_product($product_id); + + $context['product'] = $product; + + $context['related_products'] = array(); + $related_products_ids = wc_get_related_products($product_id, 5); + + if ($related_products_ids) { + foreach ($related_products_ids as $related_id) { + $related_product = wc_get_product($related_id); + if ($related_product) { + $context['related_products'][] = $related_product; + } + } + } + + Timber::render('modules/shop/components/single-product/component-template.twig', $context); +} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-left.svg b/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-left.svg new file mode 100644 index 0000000..465c268 --- /dev/null +++ b/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-left.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-right.svg b/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-right.svg new file mode 100644 index 0000000..8952470 --- /dev/null +++ b/wp-content/themes/cosmopet/static/shop/img/svg/main/arrow-right.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/wp-content/themes/cosmopet/static/shop/img/svg/main/black-x.svg b/wp-content/themes/cosmopet/static/shop/img/svg/main/black-x.svg new file mode 100644 index 0000000..cb3041d --- /dev/null +++ b/wp-content/themes/cosmopet/static/shop/img/svg/main/black-x.svg @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/wp-content/themes/cosmopet/templates/blog/blog-single.twig b/wp-content/themes/cosmopet/templates/blog/blog-single.twig index 019dc97..05d08fe 100644 --- a/wp-content/themes/cosmopet/templates/blog/blog-single.twig +++ b/wp-content/themes/cosmopet/templates/blog/blog-single.twig @@ -1,62 +1,89 @@ -{% extends 'layout.twig' %} - - -{% block content %} - - - - + {% extends 'layout.twig' %} + + + {% block content %} - -
-
-

{{post.name}}

-
- -

{{post.date}}

-

{{ function('pll_e', 'время чтения') }}: {{post.reading_time}}

- - {% if post.get_author_name %} -
- - {{post.get_author_name}} + + + + +
+
+

{{post.name}}

+
+ +

{{post.date}}

+

{{ function('pll_e', 'время чтения') }}: {{post.reading_time}}

+ + {% if post.get_author_name %} + + {% endif %} +
+
+ {{post.thumbnail.alt}}
- {% endif %}
-
- {{post.thumbnail.alt}} +
+ + + + +
+
+ {{post.content}}
+ +
+
+
+ + + {{ function('get_post_likes_count', post.ID) }} + +
+
+

+ {{ function('pll_e', 'КОММЕНТАРИИ') }} ({{ function('get_comments_number', post.ID) }}) +

+ {{ function('comments_template') }} +
+
+
+
-
+ - + - -
-
- {{post.content}} -
-
- -
-
- {% include '/blog/featured-slider.twig' %} -
-
- - +
+
+ {% include '/blog/featured-slider.twig' %} +
+
+ + -{% endblock %} \ No newline at end of file + {% endblock %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/blog/editorial.twig b/wp-content/themes/cosmopet/templates/blog/editorial.twig index 0409128..7b7ed3d 100644 --- a/wp-content/themes/cosmopet/templates/blog/editorial.twig +++ b/wp-content/themes/cosmopet/templates/blog/editorial.twig @@ -27,14 +27,21 @@

{{_post.date}}

{{_post.reading_time}}

- +
diff --git a/wp-content/themes/cosmopet/templates/blog/featured-slider.twig b/wp-content/themes/cosmopet/templates/blog/featured-slider.twig index daddad6..24ac65c 100644 --- a/wp-content/themes/cosmopet/templates/blog/featured-slider.twig +++ b/wp-content/themes/cosmopet/templates/blog/featured-slider.twig @@ -36,7 +36,20 @@
{{_post.date}}
{{ function('pll_e', 'время чтения') }}: {{_post.reading_time}}
- +
+
+ +{{ function('get_post_likes_count', _post.ID|default(0)) }} +
+
+ +{{ _post.get_comments_number }}
+ {% if _post.get_author_name %} + +{% endif %} +
{{ function('pll_e', 'читать статью') }} diff --git a/wp-content/themes/cosmopet/templates/blog/most-read.twig b/wp-content/themes/cosmopet/templates/blog/most-read.twig index 903c173..4163bd9 100644 --- a/wp-content/themes/cosmopet/templates/blog/most-read.twig +++ b/wp-content/themes/cosmopet/templates/blog/most-read.twig @@ -1,3 +1,6 @@ +{% set current_path = template_path ~ '/modules/blog/components/most-read' %} + +

{{ function('pll_e', 'САМЫЕ ЧИТАЕМЫЕ') }}:

@@ -33,12 +36,24 @@

{{ post.date|date('d.m.Y') }}

{{ function('pll_e', 'время чтения') }}: {{ post.reading_time|default('5 мин') }}

+
diff --git a/wp-content/themes/cosmopet/templates/blog/news-list.twig b/wp-content/themes/cosmopet/templates/blog/news-list.twig index 2a4d1ea..c201155 100644 --- a/wp-content/themes/cosmopet/templates/blog/news-list.twig +++ b/wp-content/themes/cosmopet/templates/blog/news-list.twig @@ -1,30 +1,40 @@ -{% for post in posts %} +{% set current_path = template_path ~ '/modules/blog/components/news-list' %} -
  • - - - {{post.thumbnail.alt}} - -
    - {{post.title}} -
    -

    {{post.date}}

    -

    {{ function('pll_e', 'время чтения') }}: {{post.reading_time}}

    -
      - {% if post.get_author_name %} - - - {% endif %} -
    + + {% for post in posts %} + +
  • + + + {{post.thumbnail.alt}} + +
    + {{post.title}} +
    +

    {{post.date}}

    +

    {{ function('pll_e', 'время чтения') }}: {{post.reading_time}}

    +
      +
    • + + {{ function('get_post_likes_count', post.ID) }} +
    • +
    • + + {{ post.comment_count }} +
    • + {% if post.get_author_name %} + + {% endif %} +
    +
    - -
  • -{% endfor %} \ No newline at end of file + + {% endfor %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/blog_author/author-archive.twig b/wp-content/themes/cosmopet/templates/blog_author/author-archive.twig new file mode 100644 index 0000000..86fb50f --- /dev/null +++ b/wp-content/themes/cosmopet/templates/blog_author/author-archive.twig @@ -0,0 +1,60 @@ +{% extends 'layout.twig' %} + + +{% block content %} + +{% set current_path = template_path ~ '/modules/author/' %} + + + + + + + + + +
    +
    +

    {{ function('pll_e', 'Все авторы') }}

    + +
    + + +
    + + {% include 'forms/discount.twig' %} +
    +
    + + {% include '/blog/featured-slider.twig' %} +
    +
    + + + + + + + +{% endblock %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/blog_author/author-posts-list.twig b/wp-content/themes/cosmopet/templates/blog_author/author-posts-list.twig new file mode 100644 index 0000000..bc77a01 --- /dev/null +++ b/wp-content/themes/cosmopet/templates/blog_author/author-posts-list.twig @@ -0,0 +1,36 @@ +{% for post in posts %} +
  • + + + {{ post.thumbnail.alt }} + +
    + {{ post.title }} +
    +

    {{ post.date|date('d.m.Y') }}

    +

    {{ function('pll_e', 'время чтения:') }} {{ post.reading_time|default(function('pll_e', '5 мин.')) }}

    +
      + {% if post.get_author_img %} + + {% endif %} +
    • + + {{ function('get_post_likes_count', post.ID) }} +
    • +
    • + + {{ post.comment_count }} +
    • +
    +
    +
    +
  • +{% endfor %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/blog_author/author-single.twig b/wp-content/themes/cosmopet/templates/blog_author/author-single.twig new file mode 100644 index 0000000..62db865 --- /dev/null +++ b/wp-content/themes/cosmopet/templates/blog_author/author-single.twig @@ -0,0 +1,92 @@ +{% set current_path = template_path ~ '/modules/blog/components/news-list' %} + +{% extends 'layout.twig' %} + +{% block content %} +
    + + + + + +
    +
    +
    +
    + {{ author.title }} +
    +
    +
    {{ author.title }}
    +
    {{ author.position }}
    +
    {{ author.content|striptags }}
    +

    {{ function('pll_e', 'статей:') }} {{ author.post_count }}

    +
    +
    +

    {{ author.meta('headline')|default(function('pll_e', 'Посты автора')) }}

    +
    +
    + +
    +
    +
    +
      + {% for post in author.posts %} +
    • + + + {{ post.thumbnail.alt }} + +
      + {{ post.title }} +
      +

      {{ post.date|date('d.m.Y') }}

      +

      {{ function('pll_e', 'время чтения:') }} {{ post.reading_time|default(function('pll_e', '5 мин.')) }}

      +
        + {% if post.get_author_img %} + + {% endif %} +
      • + + {{ function('get_post_likes_count', post.ID) }} +
      • +
      • + + {{ post.comment_count }} +
      • +
      +
      +
      +
    • + {% else %} +
    • {{ function('pll_e', 'Нет постов') }}
    • + {% endfor %} +
    + {% if total_pages > 1 %} +
    + + + +
    + {% endif %} +
    +
    +
    + +
    +{% endblock %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/comment/comment.twig b/wp-content/themes/cosmopet/templates/comment/comment.twig new file mode 100644 index 0000000..105a8af --- /dev/null +++ b/wp-content/themes/cosmopet/templates/comment/comment.twig @@ -0,0 +1,32 @@ +
    +
    + {{ comment.author.name }} +
    +
    + {{ comment.author.name }} +
    + + {{ comment.date }} + +
    +
    +

    + {{ comment.content }} +

    +
    + + +
    + +
    \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/forms/discount.twig b/wp-content/themes/cosmopet/templates/forms/discount.twig new file mode 100644 index 0000000..d3acd3b --- /dev/null +++ b/wp-content/themes/cosmopet/templates/forms/discount.twig @@ -0,0 +1,36 @@ +
    +
    +
    +

    {{sub_title}} +

    +
    + + +
    +
    +
    + +
    +

      +
      + +
      + + + + + + +
      +
      +
      +

      + {{ function('pll_e', 'Подписываясь на рассылку, я даю согласие на обработку персональных данных, на получение рекламных сообщений и новостей о товарах и услугах') }}

      +

      {{sub_text}}

      +
      +
      +
      \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/front-page/front-page.twig b/wp-content/themes/cosmopet/templates/front-page/front-page.twig index 430cdac..9aa23d4 100644 --- a/wp-content/themes/cosmopet/templates/front-page/front-page.twig +++ b/wp-content/themes/cosmopet/templates/front-page/front-page.twig @@ -609,42 +609,7 @@ -
      -
      -
      -

      {{sub_title}} -

      -
      - - -
      -
      -
      - -
      -

        -
        - -
        - - - - - - -
        -
        -
        -

        - {{ function('pll_e', 'Подписываясь на рассылку, я даю согласие на обработку персональных данных, на получение рекламных сообщений и новостей о товарах и услугах') }}

        -

        {{sub_text}}

        -
        -
        -
        + {% include 'forms/discount.twig' %} {% endblock %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/templates/shop/single-product.php b/wp-content/themes/cosmopet/templates/shop/single-product.php new file mode 100644 index 0000000..59884cb --- /dev/null +++ b/wp-content/themes/cosmopet/templates/shop/single-product.php @@ -0,0 +1,63 @@ + '', + 'wrap_before' => '', + 'wrap_after' => '', + 'before' => '', + 'after' => '', + 'home' => _x('Home', 'breadcrumb', 'woocommerce'), + ); + + $breadcrumbs = new WC_Breadcrumb(); + $breadcrumbs->generate(); + + $formatted_breadcrumbs = array(); + foreach ($breadcrumbs->get_breadcrumb() as $crumb) { + $formatted_breadcrumbs[] = array( + 'text' => $crumb[0], + 'url' => $crumb[1] + ); + } + + $context['wc_breadcrumbs'] = $formatted_breadcrumbs; + } + + + $product_id = get_the_ID(); + $product = wc_get_product($product_id); + + $context['product'] = $product; + + $context['related_products'] = array(); + $related_products_ids = wc_get_related_products($product_id, 5); + + if ($related_products_ids) { + foreach ($related_products_ids as $related_id) { + $related_product = wc_get_product($related_id); + if ($related_product) { + $context['related_products'][] = $related_product; + } + } + } + + Timber::render('modules/shop/components/single-product/component-template.twig', $context); +} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/woocommerce/archive-product/archive-product-tease.twig b/wp-content/themes/cosmopet/woocommerce/archive-product/archive-product-tease.twig index 4a39255..306fa6e 100644 --- a/wp-content/themes/cosmopet/woocommerce/archive-product/archive-product-tease.twig +++ b/wp-content/themes/cosmopet/woocommerce/archive-product/archive-product-tease.twig @@ -1,115 +1,117 @@ -{% set cur_product = fn('wc_get_product', product.id) %} -{% set attrs = post.product.get_attributes() %} -{% set cur_weight = function('get_product_info', post.id, 'weight') %} +{% if post.id is defined and post.id %} + {% set cur_product = fn('wc_get_product', post.id) %} + {% set attrs = post.product.get_attributes() %} + {% set cur_weight = function('get_product_info', post.id, 'weight') %} -
        -
        - {% if post.date('Y-m-d') >= criteria_for_new_product %} - - {{ function('pll_e', 'Новинка') }} - - {% endif %} +
        +
        + {% if post.date('Y-m-d') >= criteria_for_new_product %} + + {{ function('pll_e', 'Новинка') }} + + {% endif %} - {% if post._sale_price %} - - {{ function('pll_e', 'Распродажа %') }} - - {% endif %} -
        - - {{ post.title }} - -
        -
        - {% set compound = fn('wc_get_product_terms', post.id, 'pa_compound') %} - {% for option in compound %} - - {% set term = get_term(option) %} - {{ term.name }} - {% endfor %} -
        - {{ post.title }} -
        -

        {{ post._price() }}

        + {% if post._sale_price %} + + {{ function('pll_e', 'Распродажа %') }} + + {% endif %}
        -
        - -
        -
        -
        -
        - {{ post.title }} -
          - {% set features = fn('wc_get_product_terms', post.id, 'pa_features') %} - {% for option in features %} + + {{ post.title }} + +
          +
          + {% set compound = fn('wc_get_product_terms', post.id, 'pa_compound') %} + {% for option in compound %} + {% set term = get_term(option) %} -
        • {{ term.name }}
        • + {{ term.name }} {% endfor %} -
        +
        + {{ post.title }} +
        +

        {{ post._price() }}

        +
        +
        + +
        - -
        -
        -
        -

        Объем

        +
        +
        + {{ post.title }} +
          + {% set features = fn('wc_get_product_terms', post.id, 'pa_features') %} + {% for option in features %} + {% set term = get_term(option) %} +
        • {{ term.name }}
        • + {% endfor %} +
        +
        + + +
        +
        +

        Объем

        -
        - -
        -
          - {% set collection = fn('wc_get_product_terms', post.id, 'pa_collection') %} - {% for option in collection %} - {% set term = get_term(option) %} - {% set siblings = function('get_collection_siblings' , term.id) %} +
          + +
          +
            + {% set collection = fn('wc_get_product_terms', post.id, 'pa_collection') %} + {% for option in collection %} + {% set term = get_term(option) %} + {% set siblings = function('get_collection_siblings' , term.id) %} - {% for sibling in siblings %} + {% for sibling in siblings %} - {% set weight = function('get_product_info', sibling.ID, 'weight') %} - - {% set class = '' %} - {% if weight == cur_weight %} - {% set class = 'active' %} - {% endif %} -
          • - -
          • + {% set weight = function('get_product_info', sibling.ID, 'weight') %} + + {% set class = '' %} + {% if weight == cur_weight %} + {% set class = 'active' %} + {% endif %} +
          • + +
          • + {% endfor %} {% endfor %} - {% endfor %} -
          +
        +
        -
        -
        -

        Количество

        +
        +

        Количество

        -
        - - - +
        + + + +
        -
        -

        - {{ post._price() }} -

        -
        -
        - {{ function('get_add_to_cart_button', post.id) }} -
        -
        - -

        {{ function('pll_e', 'Подробнее') }}

        -
        +

        + {{ post._price() }} +

        +
        +
        + {{ function('get_add_to_cart_button', post.id) }} +
        +
        -
        - + +
        -
        \ No newline at end of file +{% endif %} \ No newline at end of file diff --git a/wp-content/themes/cosmopet/woocommerce/single-product.php b/wp-content/themes/cosmopet/woocommerce/single-product.php new file mode 100644 index 0000000..16272d7 --- /dev/null +++ b/wp-content/themes/cosmopet/woocommerce/single-product.php @@ -0,0 +1,19 @@ +