<?php echo !defined("GUVENLIK") ? die("Vaoww! Bu ne cesaret?") : null;?><?php
$pricingayar = $db->prepare("select * from pricing_ayar where id='1'");
$pricingayar->execute();
$pric = $pricingayar->fetch(PDO::FETCH_ASSOC);
?>
<?php
$num = 1;
$pricing_liste = $db->prepare("select * from pricing where durum='1' and dil='$_SESSION[dil]' order by sira asc ");
$pricing_liste->execute();


?>
<style>
    .pricing-home-main-div{width:<?php if($pric[width]==1){?> 90%; <?php }else {?> 100% <?php }?> ; height: auto; overflow: hidden; background-color: #<?php echo $pric[back_color] ?>; padding: <?php echo $pric[padding] ?>px 0 <?php echo $pric[padding] ?>px 0; margin:auto;text-align: center;}
</style>

<section class="pricing-section pb-70 pricing-home-main-div">
    <div class="container">
        <div class="section-head text-center">
            <h2 class="font-<?php echo $pric[font_weight] ?> font-spacing" style="color:#<?php echo $pric[baslik_color] ?>">
                <?php echo $diller['pricing-table']?></h2>
            <p style="color:#<?php echo $serv[spot_color] ?>; letter-spacing: 0.07em">
                <?php echo $diller['pricing-aciklamasi']?></p>
        </div>

        <div class="row">
    <?php foreach ( $pricing_liste as $pricing) { ?>

            <div class="col-lg-4 col-md-6 col-sm-6">
                <div class="price-card-area">
                    <div class="price-head-text" <?php if($pricing[tavsiye] ==1) {?> style="background:#<?php echo $pric[tavsiye_color] ?>; border-radius: 4px 4px 0 0;" <?php } ?>>
                    <?php if($pricing[tavsiye] ==1) {?>

                        <div class="pricing-tavsiye-board" style="background-color: #<?php echo $pric[tavsiye_color] ?>; color:#<?php echo $pric[tavsiye_text_color] ?>;position: absolute;top: 0;width: 100%;left: 0;}">
                            <?php echo $diller['pricing-tavsiye'] ?>
                        </div>

                    <?php } ?>
                    <i class="fa <?php echo $pricing[icon] ?>" style="color:#<?php echo $pric[icon_color] ?>"></i>
                    <h4 class="<?php echo $pric[text_size] ?> <?php echo $pric[text_weight] ?>" style="color:#<?php echo $pric[text_color] ?>; <?php if($pricing[fiyat] == null) { ?>border-bottom:1px solid #EBEBEB<?php }?> ">
                        <?php echo $pricing[baslik] ?></h4>
                        <?php if($pricing[fiyat] == !null) { ?>
                            <h2><span><?php echo $pricing[fiyat] ?> <?php echo $odemeayar[simge] ?></span>/<?php echo $pricing[odeme_date] ?></h2>
                        <?php }?>
                    </div>

                    <div class="plan-features">
                        <ul>
                            <?php
                            $pricing_ozellikler = $db->prepare("select * from pricing_ozellik where pr_id='$pricing[id]' and dil='$_SESSION[dil]' order by sira asc ");
                            $pricing_ozellikler->execute();
                            while($prozellik = $pricing_ozellikler->fetch(PDO::FETCH_ASSOC))
                            {
                                ?>
                            <li>
                                <i class="icofont-check-circled"></i>
                                <?php echo $prozellik[baslik] ?>
                            </li>
                        <?php } ?>
                        </ul>
                    </div>
                    <?php 
                    if($pricing[url]==null){

                    } else {
                        ?>
                        <div class="plan-btn">
                            <a href="<?php echo $pricing[url] ?>" style="
                     <?php if($pricing[tavsiye] ==1) {?>
                             color:#<?php echo $pric[tavsiye_text_color] ?>; background: #<?php echo $pric[tavsiye_color] ?>
                             <?php } else {?>
                             color:#<?php echo $pric[button_text_color] ?>; background: #<?php echo $pric[button_bg] ?>
                             <?php }?>
                             ">
                    <?php echo $diller['pricing-button-yazisi']; ?></a>
                        </div>
                    <?php } ?>
                </div>
            </div>
        <?php } ?>
        </div>
    </div>
</section>