window.addEventListener('load', () => {
    wcagContrast1();
})

function wcagContrast1() {
 document.querySelector('.grid-bip .contrast div:nth-child(2)').addEventListener('click', () => {
    console.log('clock')
    document.querySelectorAll('body,div > *,ul li,a,span,img,p,div').forEach(items => {
        items.style.setProperty('background','black','important');
        items.style.setProperty('background-color','black','important');
        items.style.setProperty('color','yellow','important');
        
    })
 })
 document.querySelector('.grid-bip .contrast div:nth-child(1)').addEventListener('click', () => {
    document.querySelectorAll('body,div > *,ul li,a,span,img,p,div,body>*,html>*').forEach(items => {
        items.style.removeProperty('background');
        items.style.removeProperty('background-color');
        items.style.removeProperty('color');
        
    })
 })
 document.querySelector('.grid-bip .sc div:nth-child(2)').addEventListener('click', () => {
    document.querySelectorAll('span,a,img,p,div >*,body>*,div,body').forEach(items => {
        
        items.style.removeProperty('font-size');
        })


    document.querySelectorAll('span,a,img,p').forEach(items => {
        
    var war=	window.getComputedStyle(items).getPropertyValue('font-size').replaceAll('px','');
    var war1=new Number(war)*1.23;
    items.style.setProperty('font-size',war1+'px','important');
    })


    document.querySelectorAll('div').forEach(items => {
        if(items.textContent.length>1){
            console.log(items.textContent.length>1);
            var war=	window.getComputedStyle(items).getPropertyValue('font-size').replaceAll('px','');
        var war1=new Number(war)*1.05;
        items.style.setProperty('font-size',war1+'px','important');

        }
        
        })

 })



 document.querySelector('.grid-bip .sc div:nth-child(3)').addEventListener('click', () => {
                 
    document.querySelectorAll('span,a,img,p,div >*,body>*,div,body').forEach(items => {
        
        items.style.removeProperty('font-size');
        })



    document.querySelectorAll('span,a,img,p').forEach(items => {
        
    var war=	window.getComputedStyle(items).getPropertyValue('font-size').replaceAll('px','');
    var war1=new Number(war)*1.3;
    items.style.setProperty('font-size',war1+'px','important');
    })


    document.querySelectorAll('div').forEach(items => {
        if(items.textContent.length>1){
            console.log(items.textContent.length>1);
            var war=	window.getComputedStyle(items).getPropertyValue('font-size').replaceAll('px','');
        var war1=new Number(war)*1.08;
        items.style.setProperty('font-size',war1+'px','important');

        }
        
        })

 })


 document.querySelector('.grid-bip  .sc div:nth-child(1)').addEventListener('click', () => {
                 


    document.querySelectorAll('span,a,img,p,div >*,body>*,div,body').forEach(items => {
        
    items.style.removeProperty('font-size');
    })

    
    

 })






}