<?php $lang=stb_lang(); $B='/NewSite'; $fa=$lang==='fa'; ?>
<style>
.ct-channels{display:grid;grid-template-columns:repeat(3,1fr);gap:12px;margin-bottom:40px}
@media(max-width:700px){.ct-channels{grid-template-columns:1fr}}
.ct-channel{background:#0a0c10;border:1px solid rgba(255,255,255,.07);border-radius:14px;padding:24px;
  position:relative;overflow:hidden;transition:border-color .2s,transform .2s;cursor:default}
.ct-channel:hover{border-color:rgba(200,16,46,.3);transform:translateY(-3px)}
.ct-channel::before{content:'';position:absolute;top:0;left:0;right:0;height:2px;
  background:#C8102E;transform:scaleX(0);transform-origin:left;transition:transform .3s}
.ct-channel:hover::before{transform:scaleX(1)}
.ct-channel-icon{width:42px;height:42px;border-radius:10px;background:rgba(200,16,46,.08);
  border:1px solid rgba(200,16,46,.15);display:flex;align-items:center;justify-content:center;margin-bottom:14px}
.ct-channel-icon svg{stroke:#C8102E;fill:none;width:18px;height:18px}
.ct-channel-name{font-size:15px;font-weight:700;color:#fff;margin-bottom:6px}
.ct-channel-desc{font-size:12.5px;color:rgba(255,255,255,.4);margin-bottom:12px;line-height:1.5}
.ct-channel-email{font-size:13px;font-weight:600;color:#C8102E;text-decoration:none}
.ct-channel-hours{font-size:11px;color:rgba(255,255,255,.3);margin-top:4px}
@keyframes ct-ping{0%{transform:scale(1);opacity:1}75%,100%{transform:scale(2);opacity:0}}
.ct-live-badge{display:inline-flex;align-items:center;gap:6px;font-size:10.5px;font-weight:700;
  color:#14e0a3;margin-bottom:8px}
.ct-live-badge span{width:7px;height:7px;border-radius:50%;background:#14e0a3;position:relative;flex-shrink:0}
.ct-live-badge span::after{content:'';position:absolute;inset:0;border-radius:50%;
  background:#14e0a3;animation:ct-ping 1.5s cubic-bezier(0,0,.2,1) infinite}
.ct-offices{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:16px}
@media(max-width:600px){.ct-offices{grid-template-columns:1fr}}
.ct-office{background:#0a0c10;border:1px solid rgba(255,255,255,.07);border-radius:12px;padding:20px}
.ct-office-city{font-size:11px;font-weight:700;letter-spacing:.12em;color:rgba(200,16,46,.8);text-transform:uppercase;margin-bottom:8px}
.ct-office-addr{font-size:13px;color:rgba(255,255,255,.5);line-height:1.6}
.ct-quick-link{display:flex;align-items:center;gap:12px;padding:14px 16px;border-radius:10px;
  background:#0a0c10;border:1px solid rgba(255,255,255,.07);text-decoration:none;margin-bottom:8px;
  transition:border-color .15s}
.ct-quick-link:hover{border-color:rgba(200,16,46,.25)}
.ct-quick-link-arr svg{stroke:rgba(200,16,46,.6);fill:none;width:16px;height:16px;flex-shrink:0}
/* Telegram widget */
.ct-telegram{display:flex;align-items:center;gap:14px;padding:18px 20px;
  background:linear-gradient(135deg,rgba(0,136,204,.08),rgba(0,136,204,.04));
  border:1px solid rgba(0,136,204,.2);border-radius:14px;margin-bottom:12px;
  text-decoration:none;transition:border-color .2s,transform .2s}
.ct-telegram:hover{border-color:rgba(0,136,204,.45);transform:translateY(-2px)}
.ct-tg-icon{width:44px;height:44px;border-radius:50%;background:rgba(0,136,204,.15);
  border:1px solid rgba(0,136,204,.25);display:flex;align-items:center;justify-content:center;flex-shrink:0}
.ct-tg-icon svg{fill:#0088cc;width:22px;height:22px}
.ct-tg-name{font-size:15px;font-weight:700;color:#fff;margin-bottom:3px}
.ct-tg-handle{font-size:12px;color:rgba(0,136,204,.8)}
.ct-tg-arr{margin-left:auto;color:rgba(0,136,204,.5);font-size:18px}
</style>

<article class="ip-page">
<div class="ip-hero">
  <div class="ip-hero-glow"></div>
  <div class="ip-container">
    <nav class="ip-breadcrumb">
      <a href="<?php echo stb_url($B.'/');?>"><?php echo $fa?'خانه':'Home';?></a>
      <span class="ip-breadcrumb-sep">›</span>
      <span><?php echo $fa?'تماس با ما':'Contact';?></span>
    </nav>
    <div class="ip-kicker"><span class="ip-kicker-dot"></span><?php echo $fa?'با ما در تماس باشید':'GET IN TOUCH';?></div>
    <h1 class="ip-h1"><?php echo $fa?'ما <em>۲۴/۷</em> اینجاییم':'We\'re Here <em>24/7</em>';?></h1>
    <p class="ip-hero-desc"><?php echo $fa?'چه سوالی درباره معاملات، حساب، مشارکت یا مشکلات فنی داشته باشید — تیم ما سریع پاسخ می‌دهد.':'Whether you have a question about trading, your account, partnerships, or technical issues — our team responds fast.';?></p>
  </div>
</div>

<section class="ip-section">
  <div class="ip-container">

    <h2 class="ip-section-title"><?php echo $fa?'کانال‌های <em>تماس</em>':'Contact <em>Channels</em>';?></h2>
    <div class="ct-channels">
      <?php
      $channels = [
        ['<path d="M22 16.92v3a2 2 0 01-2.18 2 19.79 19.79 0 01-8.63-3.07A19.5 19.5 0 013.07 9.81 19.79 19.79 0 01.02 1.18 2 2 0 012 0h3a2 2 0 012 1.72 12.84 12.84 0 00.7 2.81 2 2 0 01-.45 2.11L6.15 7.5a16 16 0 006.35 6.35l1.06-1.1a2 2 0 012.11-.45 12.84 12.84 0 002.81.7A2 2 0 0122 14.92z" stroke-width="1.5"/>',
         $fa?'پشتیبانی مشتریان':'Customer Support',
         $fa?'حساب‌ها، واریز، برداشت، مشکلات پلتفرم.':'Accounts, deposits, withdrawals, platform issues.',
         'support@stbbrokers.com'],
        ['<path d="M17 21v-2a4 4 0 00-4-4H5a4 4 0 00-4 4v2" stroke-width="1.5"/><circle cx="9" cy="7" r="4" stroke-width="1.5"/>',
         $fa?'مشارکت و IB':'Partnership & IB',
         $fa?'استعلامات IB، وابسته و سفیر.':'IB, affiliate, and ambassador inquiries.',
         'partners@stbbrokers.com'],
        ['<path d="M10 20l4-16m4 4l4 4-4 4M6 16l-4-4 4-4" stroke-width="1.5" stroke-linecap="round"/>',
         $fa?'پشتیبانی فنی':'Technical Support',
         $fa?'مشکلات پلتفرم، اتصال و سیستم.':'Platform, connectivity, and system issues.',
         'tech@stbbrokers.com'],
      ];
      foreach($channels as $c): ?>
      <div class="ct-channel">
        <div class="ct-live-badge"><span></span><?php echo $fa?'در دسترس ۲۴/۷':'Available 24/7';?></div>
        <div class="ct-channel-icon"><svg viewBox="0 0 24 24" stroke="currentColor" fill="none"><?php echo $c[0];?></svg></div>
        <div class="ct-channel-name"><?php echo $c[1];?></div>
        <div class="ct-channel-desc"><?php echo $c[2];?></div>
        <a href="mailto:<?php echo $c[3];?>" class="ct-channel-email"><?php echo $c[3];?></a>
        <div class="ct-channel-hours"><?php echo $fa?'پاسخ ظرف ۲ ساعت در ساعات بازار':'Response within 2 hours during market hours';?></div>
      </div>
      <?php endforeach; ?>
    </div>

    <!-- Telegram -->
    <a href="<?php echo $fa ? 'https://t.me/stbbroker_ir' : 'https://t.me/stbbrokereng'; ?>" target="_blank" rel="noopener" class="ct-telegram">
      <div class="ct-tg-icon">
        <svg viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg">
          <path d="M12 0C5.373 0 0 5.373 0 12s5.373 12 12 12 12-5.373 12-12S18.627 0 12 0zm5.894 8.221-1.97 9.28c-.145.658-.537.818-1.084.508l-3-2.21-1.447 1.394c-.16.16-.295.295-.605.295l.213-3.053 5.56-5.023c.242-.213-.054-.333-.373-.12L7.17 13.667l-2.96-.924c-.643-.204-.657-.643.136-.953l11.57-4.461c.537-.194 1.006.131.978.892z"/>
        </svg>
      </div>
      <div>
        <div class="ct-tg-name"><?php echo $fa?'کانال تلگرام STB':'STB Telegram Channel';?></div>
        <div class="ct-tg-handle">@<?php echo $fa ? 'stbbroker_ir' : 'stbbrokereng'; ?> · <?php echo $fa?'اخبار لحظه‌ای، آپدیت‌های پلتفرم':'Live news, platform updates';?></div>
      </div>
      <div class="ct-tg-arr">›</div>
    </a>

    <!-- Offices + Quick Links -->
    <div style="display:grid;grid-template-columns:1fr 1fr;gap:40px" class="ct-grid">
      <style>@media(max-width:768px){.ct-grid{grid-template-columns:1fr!important}}</style>

      <!-- LEFT: Offices + Phones + Business Hours -->
      <div>
        <h2 class="ip-section-title" style="margin-bottom:20px"><?php echo $fa?'آدرس <em>دفاتر</em>':'Office <em>Locations</em>';?></h2>
        <div class="ct-offices">
          <?php foreach([
            [$fa?'ثبت‌شده — سنت لوسیا':'Registered — Saint Lucia',
             $fa?'طبقه همکف، ساختمان Sotheby، روستای Rodney، خلیج Rodney، Gros Islet':'Ground Floor, The Sotheby Building, Rodney Village, Rodney Bay, Gros Islet'],
            [$fa?'عملیات — بلغارستان':'Operations — Bulgaria',
             $fa?'بلغارستان، صوفیه، بلوار ۵۸، ورودی C، طبقه اول، دفتر شماره ۴':'Bulgaria bul. 58, ent.C, Floor 1, Office 4, Sofia, Bulgaria'],
          ] as $o): ?>
          <div class="ct-office">
            <div class="ct-office-city"><?php echo $o[0];?></div>
            <div class="ct-office-addr"><?php echo $o[1];?></div>
          </div>
          <?php endforeach; ?>
        </div>

        <div style="margin-top:16px;font-size:13px;color:rgba(255,255,255,.4);line-height:2">
          <?php echo $fa?'تلفن (بلغارستان)':'Tel (BG)';?>: <a href="tel:+35929286457" style="color:rgba(200,16,46,.8)">+359 2 928 6457</a>
          &nbsp;·&nbsp;
        </div>

        <div style="margin-top:20px;background:#0a0c10;border:1px solid rgba(255,255,255,.07);border-radius:12px;padding:18px 20px">
          <div style="font-size:11px;font-weight:700;letter-spacing:.12em;text-transform:uppercase;color:rgba(200,16,46,.7);margin-bottom:12px"><?php echo $fa?'ساعات کاری':'Business Hours';?></div>
          <?php foreach($fa?[
            ['دوشنبه – جمعه','۸ صبح – ۸ شب (GMT)'],
            ['شنبه','۱۰ صبح – ۴ بعدازظهر (GMT)'],
            ['یکشنبه','بسته'],
          ]:[
            ['Monday – Friday','8:00 AM – 8:00 PM (GMT)'],
            ['Saturday','10:00 AM – 4:00 PM (GMT)'],
            ['Sunday','Closed'],
          ] as $h): ?>
          <div style="display:flex;justify-content:space-between;font-size:12.5px;padding:5px 0;border-bottom:1px solid rgba(255,255,255,.04)">
            <span style="color:rgba(255,255,255,.5)"><?php echo $h[0];?></span>
            <span style="color:#fff;font-weight:600"><?php echo $h[1];?></span>
          </div>
          <?php endforeach; ?>
        </div>
      </div>

      <!-- RIGHT: Quick Links -->
      <div>
        <h2 class="ip-section-title" style="margin-bottom:20px"><?php echo $fa?'لینک‌های <em>سریع</em>':'Quick <em>Links</em>';?></h2>
        <?php
        $links = [
          [$B.'/faq/', $fa?'سوالات متداول':'FAQ', $fa?'پاسخ سریع به سوالات رایج.':'Quick answers to common questions.'],
          [$B.'/deposit/', $fa?'واریز و برداشت':'Deposit & Withdrawal', $fa?'روش‌های پرداخت و کارمزدها.':'Payment methods and fees.'],
          [$B.'/platforms/', $fa?'راهنمای پلتفرم':'Platform Guides', $fa?'دانلود MT5 و آموزش‌ها.':'Download MT5 and tutorials.'],
          [$B.'/legal/', $fa?'اسناد حقوقی':'Legal Documents', $fa?'قراردادها و سیاست‌ها.':'Agreements and policies.'],
        ];
        foreach($links as $r): ?>
        <a href="<?php echo stb_url($r[0]);?>" class="ct-quick-link">
          <div style="flex:1">
            <div style="font-size:14px;font-weight:600;color:#fff;margin-bottom:2px"><?php echo $r[1];?></div>
            <div style="font-size:12px;color:rgba(255,255,255,.35)"><?php echo $r[2];?></div>
          </div>
          <div class="ct-quick-link-arr"><svg viewBox="0 0 24 24"><path d="M9 18l6-6-6-6" stroke-width="1.5" stroke-linecap="round"/></svg></div>
        </a>
        <?php endforeach; ?>
      </div>
    </div>

  </div>
</section>
</article>
