@extends('frontend.layouts.app')

@section('content')
@php
$isLogin = auth()->check(); 
$prefix = $isLogin ? '/secure' : '';
@endphp
    <div id="showM">
        <div class="overlap g8mmenu-close"></div>
        @include('frontend.partials.mobile.header')
        @include('frontend.partials.mobile.sidebar-menu')

        <style>.content .box .box__detail h4 {margin: 0;}</style>
        
        <div class="content">
            <section class="box">
                <div class="box__detail">
                    <h2 class="text-center">{{ $title }}</h2>
                    
                    @if($slug == 'aboutus')
                        @include('frontend.info.aboutus')
                    
                    @elseif($slug == 'tnc')
                        @include('frontend.info.tnc')
                    
                    @elseif($slug == 'policy')
                        @include('frontend.info.policy')
                    
                    @elseif($slug == 'responsible-gaming')
                        @include('frontend.info.responsible-gaming')

                    @elseif($slug == 'faq')
                        @include('frontend.info.faq')

                    @elseif($slug == 'contact')
                        @include('frontend.info.contact')
                    @endif

                </div>
            </section>
        </div>
        @include('frontend.partials.mobile.bottom-nav')
    </div>
    <div id="showD">
        @include('frontend.partials.desktop.header')

        <section class="slider">
            <section class="marquee">
                <div class="wrapper">
                    <div class="s-a">
                        <div class="marquee__bullhorn">
                            <i class="fas fa-bullhorn"></i>
                        </div>
                        <marquee scrolldelay="150" behavior="scroll" onmouseover="this.stop();" onmouseout="this.start();" direction="left">
                            <div style="width: 100000px; transform: translateX(0px);" class="js-marquee-wrapper">
                                <div class="js-marquee" style="margin-right: 0px; float: left;">{{ general()->title }}</div>
                            </div>
                        </marquee>
                    </div>
                </div>
            </section>
        </section>

        <div class="wrapper">
            <section class="info">
                
                <div class="info__left">
                    <ul>
                        <li class="{{ $slug == 'aboutus' ? 'active' : '' }}">
                            <a href="/secure/aboutus">Tentang Kami</a>
                        </li>
                        <li class="{{ $slug == 'tnc' ? 'active' : '' }}">
                            <a href="/secure/tnc">Syarat & Ketentuan</a>
                        </li>
                        <li class="{{ $slug == 'policy' ? 'active' : '' }}">
                            <a href="/secure/policy">Pribadi</a>
                        </li>
                        <li class="{{ $slug == 'responsible-gaming' ? 'active' : '' }}">
                            <a href="/secure/responsible-gaming">Tanggung Jawab</a>
                        </li>
                        <li class="{{ $slug == 'faq' ? 'active' : '' }}">
                            <a href="/secure/faq">Pusat Info</a>
                        </li>
                        <li class="{{ $slug == 'contact' ? 'active' : '' }}">
                            <a href="/secure/contact">Hubungi Kami</a>
                        </li>
                    </ul>
                </div>
                
                <div class="info__right">
                    <div class="info__right-title">{{ $title }}</div>
                    <div class="info__right-content">
                        
                        @if($slug == 'aboutus')
                            @include('frontend.info.aboutus')
                        @elseif($slug == 'tnc')
                            @include('frontend.info.tnc')
                        
                        @elseif($slug == 'policy')
                            @include('frontend.info.policy')
                        
                        @elseif($slug == 'responsible-gaming')
                            @include('frontend.info.responsible-gaming')

                        @elseif($slug == 'faq')
                            @include('frontend.info.faq')

                        @elseif($slug == 'contact')
                            @include('frontend.info.contact')
                        @endif

                    </div>
                </div>

            </section>
        </div>

        <section class="sidebar s-sidebar"></section>
        
        @include('frontend.partials.desktop.footer')
    </div>
    @endsection

@push('scripts')
<script type="text/javascript">
window.loadMeIfReady = function() {
    // Karena ini murni halaman statis teks, Anda tidak butuh script AJAX / DataTables yang berat di sini.
    // Dibiarkan kosong saja untuk performa maksimal!
};
</script>
@endpush