document.addEventListener("DOMContentLoaded",function(){const headers=document.querySelectorAll('h1, h2, h3, h4, h5, h6');headers.forEach((header)=>{if(header.tagName.toLowerCase()==='h1'&&document.body.classList.contains('category')){return}
if(header.closest('.et_pb_text_inner')){return}
if(header.closest('.post-header')||header.closest('.single-post-module')){return}
if(header.closest('.post-widget')||header.closest('.betting-partners')||header.closest('.widget')||header.closest('.featured-posts-slider-module')){return}
if(header.closest('.category-description')||header.closest('.top-description')){return}
const paragraph=document.createElement("p");paragraph.innerHTML=header.innerHTML;const computedStyle=window.getComputedStyle(header);for(let style of computedStyle){paragraph.style[style]=computedStyle.getPropertyValue(style)}
paragraph.style.color="#101828";paragraph.style.fontWeight="bold";if(header.closest('.widget_list_social')){paragraph.style.display="inline-block";paragraph.style.whiteSpace="nowrap";paragraph.style.wordBreak="normal"}else{paragraph.style.display="block";paragraph.style.whiteSpace="normal";paragraph.style.wordBreak="normal"}
paragraph.classList.add(`converted-${header.tagName.toLowerCase()}`);header.replaceWith(paragraph)})});jQuery(document).ready(function($){$(".featured-posts-slider-module .carousel-item").on("click",function(){var postURL=$(this).find(".entry-title a").attr("href");if(postURL){window.location.href=postURL}})});document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll("*").forEach((element)=>{if(window.getComputedStyle(element).color==="rgb(188, 46, 30)"){element.style.color="#6DB8FA"}
if(window.getComputedStyle(element).backgroundColor==="rgb(188, 46, 30)"){element.style.backgroundColor="#6DB8FA"}})});document.addEventListener("DOMContentLoaded",function(){function setRatingStars(){console.log("Updating rating stars...");var ratingStarsImg=document.querySelectorAll("#rating-stars .rating-star");if(ratingStarsImg.length>0){console.log(`Found ${ratingStarsImg.length} image-based rating stars, updating...`);ratingStarsImg.forEach((star,index)=>{if(index<5){star.classList.remove("star-off");star.classList.add("star-on");star.src="https://dota2gamers.gg/wp-content/themes/Extra/images/star-full.svg"}else{star.classList.remove("star-on");star.classList.add("star-off");star.src="https://dota2gamers.gg/wp-content/themes/Extra/images/star-empty.svg"}})}else{console.log("No image-based rating stars found.")}
var ratingStarsSpan=document.querySelectorAll("span.rating-star, .post-meta-icon.rating-star");if(ratingStarsSpan.length>0){console.log(`Found ${ratingStarsSpan.length} CSS-based rating stars, updating...`);ratingStarsSpan.forEach((star,index)=>{if(index%5<5){star.classList.remove("rating-star-empty");star.classList.add("rating-star-full");star.style.color="#FFD700";star.style.opacity="1"}else{star.classList.remove("rating-star-full");star.classList.add("rating-star-empty");star.style.color="#D3D3D3";star.style.opacity="0.5"}})}else{console.log("No CSS-based rating stars found.")}
console.log("Rating stars update complete.")}
setRatingStars();var observer=new MutationObserver(function(){console.log("New rating stars detected, updating...");setRatingStars()});observer.observe(document.body,{childList:!0,subtree:!0});console.log("MutationObserver is now watching for dynamically loaded rating stars...")});document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll(".post-thumbnail.header img").forEach(img=>{img.src=img.src.replace(/-\d+x\d+\.webp$/,'.webp')})});document.addEventListener("DOMContentLoaded",function(){document.querySelectorAll(".post").forEach(function(post){var featuredImage=post.querySelector(".post-thumbnail img, .header img");if(!featuredImage){var header=post.querySelector(".header");if(header){header.style.display="none"}}else{var header=post.querySelector(".header");if(header){header.style.display=""}}})})