<div class="col-xl-4 col-lg-6 col-md-12 col-sm-12 col-12 layout-spacing">
    <div class="widget widget-account-invoice-three">
        <div class="widget-heading">
            <div class="wallet-usr-info">
                <div class="usr-name">
                    <span> Arisan Motor <?= $data_arisan['nm_kelompok'] ?><br>
                        <center><?= $data_arisan['id'] ?></center>
                    </span>
                </div>
                <?php
                if ($data_arisan['status_arisan'] == 'PROSES') : ?>
                    <div class="add">
                        <button type="button" class="btn btn-primary mb-1 mr-1 btn-rounded" data-toggle="modal" data-target="#tambahAnggota">
                            <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-plus">
                                <line x1="12" y1="5" x2="12" y2="19"></line>
                                <line x1="5" y1="12" x2="19" y2="12"></line>
                            </svg>
                        </button>
                    </div>
                <?php endif;
                ?>
            </div>
            <div class="wallet-balance">
                <p>Saldo Lelang :
                    <br><b><?= $this->mycustom->nice_number($saldo_kelompok) ?></b>
                </p>
                <h6 class=""></h6>
            </div>
        </div>
        <div class="widget-amount">
            <div class="w-a-info funds-received">
                <span>Target <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-up">
                        <polyline points="18 15 12 9 6 15"></polyline>
                    </svg></span>
                <p><?= $this->mycustom->nice_number(($data_arisan['tagihan_iuran'] * $anggota_aktif)) ?></p>
            </div>

            <div class="w-a-info funds-spent">
                <span>Realisasi <svg xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round" class="feather feather-chevron-up">
                        <polyline points="18 15 12 9 6 15"></polyline>
                    </svg></span>
                <p><?php
                    if ($realisasi['realisasi_bulan_ini'] == null) :
                        echo 0;
                    else :
                        echo $this->mycustom->nice_number($realisasi['realisasi_bulan_ini']);
                    endif;
                    ?>
                </p>
            </div>
        </div>

        <div class="widget-content">
            <div class="bills-stats">
                <?php
                if ($data_arisan['status_arisan'] == 'PROSES') : ?>
                    <span>PROSES</span>
                <?php elseif ($data_arisan['status_arisan'] == 'AKTIF') : ?>
                    <span style="background-color: green;">AKTIF</span>
                <?php elseif ($data_arisan['status_arisan'] == 'VERIFIKASI') : ?>
                    <span>VERIFIKASI</span>
                <?php else : ?>
                    <span style="background-color: red;"> SELESAI</span>
                <?php endif;
                ?>
            </div>
            <div class="invoice-list">
                <div class="inv-detail">
                    <div class="info-detail-1">
                        <p>Target : </p>
                        <p><span class="w-currency"></span> <span class="bill-amount"><?= $data_arisan['target_anggota'] ?>
                                Anggota</span>
                        </p>
                    </div>
                    <div class="info-detail-1">
                        <p>Aktif : </p>
                        <p><span class="w-currency"></span> <span class="bill-amount"><?= $anggota_aktif ?>
                                Anggota</span>
                        </p>
                    </div>
                    <div class="info-detail-2">
                        <p>Menang : </p>
                        <p><span class="w-currency"></span> <span class="bill-amount"><?= $anggota_menang ?>
                                Anggota</span>
                        </p>
                    </div>
                    <div class="info-detail-2">
                        <p>Mundur : </p>
                        <p><span class="w-currency"></span> <span class="bill-amount">
                                <?= $anggota_mundur ?> Anggota</span>
                        </p>
                    </div>
                    <div class="info-detail-2">
                        <p>Iuran /Bulan : </p>
                        <p><span class="w-currency"></span> <span class="bill-amount"><?= $this->mycustom->nice_number($data_arisan['tagihan_iuran']) ?>
                                X
                                <?= $data_arisan['tempo'] ?> Bulan</span>
                        </p>
                    </div>
                </div>
                <div class="inv-action">
                    <a href="<?= base_url('arisan/laporan/laporan_motor/kelompok/' . $this->encrypt->encode($data_arisan['id'])) ?>" class="btn btn-outline-primary view-details">Laporan</a>
                    <a href="<?= base_url('arisan/aktifitas/tagihan/kelompok/' . $this->encrypt->encode($data_arisan['id'])) ?>" class="btn btn-outline-primary pay-now">Tagihan</a>
                </div>
            </div>
        </div>
    </div>
</div>