import styles from './styles.module.scss';
import { NavLink } from "react-router-dom";
import { ROUTE_PATH } from "@constants/routes";
import React, { useEffect, useRef } from "react";
import { stringFormat } from "@utils/helpers";
import logo from '@assets/logo/logo.png';
import fb from "@assets/footer/fb.webp";
import tg from "@assets/footer/tg.webp";
import ig from "@assets/footer/ig.webp";
import x from "@assets/footer/x.webp";
import wa from "@assets/footer/wa.webp";
import pay from "@assets/footer/pay.webp";
import tip1 from "@assets/footer/tip1.webp";
import tip2 from "@assets/footer/tip2.webp";

const i18n = global.i18n;
const objInfo = {
    isInit: false
};
const Footer = () => {
    // const anjRef = useRef(null);
    // useEffect(() => {
    //     if (!objInfo.isInit) {
    //         if (window.anj_75ede18c_13d5_4b2c_ae69_043e5c00f765) {
    //             window.anj_75ede18c_13d5_4b2c_ae69_043e5c00f765.init();
    //             objInfo.isInit = true;
    //         }
    //     }
    // }, []);
    // useEffect(() => {
    //     if (anjRef.current != null) {
    //         let ganj = document.getElementById('anj-75ede18c-13d5-4b2c-ae69-043e5c00f765');
    //         if (ganj != null) {
    //             let htmlstr = ganj.innerHTML;
    //             let host = window.location.host;
    //             let main_host = "www.24680.com";
    //             if (htmlstr != null && htmlstr.indexOf(main_host) === -1) {
    //                 htmlstr = htmlstr.replaceAll(host, main_host);
    //             }
    //             anjRef.current['innerHTML'] = htmlstr;
    //         }
    //     }
    // }, [anjRef.current]);
    // const renderAnjBasic = () => {
    //     return (
    //         <div ref={anjRef} id="anj-75ede18c-13d5-4b2c-ae69-043e5c00f765"
    //             data-anj-seal-id="75ede18c-13d5-4b2c-ae69-043e5c00f765"
    //             data-anj-image-size="60" data-anj-image-type="basic-small"></div>
    //     );
    // };
    // const renderGameing = () => {
    //     return (
    //         <div className={styles.footer_block}>
    //             <div className={styles.tit}>{i18n.t('footer.game_res')}</div>
    //             <div className={styles.footer_gaming_wrap}>
    //                 <div className={styles.gameing_item}>
    //                     <a href="https://cryptogambling.org" keep-scroll-position="true" rel="noopener noreferrer" className="">
    //                         <img alt="verify" src="https://cdn.ouro777.com/img/verify.webp" />
    //                     </a>
    //                 </div>
    //                 <div className={styles.gameing_item}>
    //                     <a href="https://www.responsiblegambling.org/" keep-scroll-position="true" rel="noopener noreferrer" className="">
    //                         <img alt="respon" src="https://cdn.ouro777.com/img/respon.webp" />
    //                     </a>
    //                 </div>
    //                 <div className={styles.gameing_item18}>
    //                     <NavLink to={ROUTE_PATH.PROTECT_MINORS}>
    //                         <img src="https://cdn.ouro777.com/img/18.png" style={{ width: '40px' }} />
    //                     </NavLink>
    //                 </div>
    //                 <div className={styles.gameing_item_anj}>
    //                     {renderAnjBasic()}
    //                 </div>
    //             </div>
    //         </div>
    //     );
    // };
    // const renderPolicy = () => {
    //     let domain = "24680.com";
    //     let email = "cs@24680.com";
    //     return (
    //         <div className={styles.footer_block}>
    //             <div className={styles.footer_copyright}>
    //                 {stringFormat(i18n.t('footer.copyright'), [domain, email])}
    //             </div>
    //             <div>
    //                 <NavLink to={ROUTE_PATH.PRIVACY}>{i18n.t("footer.privacy_policy")}</NavLink>
    //                 {" | "}
    //                 <NavLink to={ROUTE_PATH.SERVICES}>{i18n.t("footer.terms_of_service")}</NavLink>
    //                 {" | "}
    //                 <NavLink to={ROUTE_PATH.KYC}>{i18n.t("footer.kyc_policy")}</NavLink>
    //             </div>
    //         </div>
    //     );
    // };
    const renderMain = () => {
        return (
            <>
                <img src={logo} alt="" className={styles.logo} />
                <div className={styles.subInfo}>© 2025 All rights reserved.</div>
                <div className={styles.appIcons}>
                    <img src={fb} alt="" />
                    <img src={tg} alt="" />
                    <img src={ig} alt="" />
                    <img src={x} alt="" />
                    <img src={wa} alt="" />
                </div>
                <img src={pay} alt="" className={styles.pay} />
                <div className={styles.payTip}>Available payment methods are subject to current supply conditions</div>
                <div className={styles.content}>
                    USSlot777 is an online casino specifically designed for the North American market, ensuring all bets are conducted with complete fairness.
                    <br />
                    We are licensed and regulated by the New Jersey Division of Gaming Enforcement as an Internet gaming operator in accordance with the Casino Control Act N.J.S.A. 5:12-1 and its implementing regulations.
                    <br />
                    Only customers 21 and over are permitted to play our games.
                    <br />
                    <br />
                    We welcome player feedback and are committed to updating our casino based on your preferences.
                    <br />
                    If you or someone you know has a gambling problem and wants help, call 1-800 GAMBLER.
                </div>

                <div className={styles.tipImg}>
                    <img src={tip1} alt="" className={styles.tip1} />
                    <img src={tip2} alt="" className={styles.tip2} />
                </div>
            </>
        );
    };
    return (
        <footer className="app_container-footer">
            <div className={styles.footer_content}>
                {/* {renderGameing()}
                {renderPolicy()} */}

                {renderMain()}
            </div>
        </footer>
    );
};
export default Footer;
