<?php

$ml_text = get_content_from_json("references");

 ?>

<section class="_sec references" data-sec="ref">
  <div class="g-sec-1 g-clr-0 ref">
    <div class="g-row g-fullheight">

      <div class="g-column-1">

        <div class="g-fullwidth">
          <div class="g-h2">
            <h2>
              <div class="_a" data-de="0">
                <span class="h-line _a-Y"><?= $ml_text[LANG]['h2'] ?></span>
              </div>
            </h2>
          </div>
		  
		<?php line("g-line-container header-line", "g-line-medium", 1300); ?>

		<?php for($i = 0 ; $i < 2 ; $i++) { ?>
		  <div class="g-paragraph _a" data-de="400">
			<h3 class="offers-subtitle">
			  <div class="_a" data-de="200">
				<span class="h-line _a-Y"><?= $ml_text[LANG]['h3-'.$i] ?></span>
			  </div>
			</h3>
			<p class="_a-opacity"><?= $ml_text[LANG]['p-'.$i] ?></p>
		  </div>
		<?php } ?>
        </div>

      </div>

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

<section class="_sec" data-sec="ref_list">
  <div class="ref-container g-fullwidth g-clr-0">

     <?php foreach ($posts as $post): ?>

    <div class="_ref ref-wrapper">

      <div class="ref-header">
        <div class="ref-h-img g-img-full">
          <div class="g-bg" style="background-image: url( '<?= UPLOADS_URL ?>img/projets/<?= $post['cover_image'] ?>')"></div>
          <div class="bg-overlay hide _ref-overlay"></div>
          <div class="ref-h-hover _ref-hover">
            <div class="ref-h-hover-title">
              <span><?= $post["title"][LANG] ?></span>
            </div>
            <div class="ref-h-hover-desc">
              <span><?= $post["role"][LANG] ?></span>
            </div>

          </div>
        </div>
        <div class="ref-h-title-wrapper">
          <h2 class="ref-h-title">
            <span class="_ref-title hide"><?= $post["title"][LANG] ?></span>
          </h2>
          <h3 class="ref-h-title">
            <span class="_ref-title hide"><?= $post["role"][LANG] ?></span>
          </h3>
        </div>
        <div class="ref-scroll-helper _ref-scroll hide">
          <svg viewBox="0 0 24 14">
            <g transform="matrix(1,0,0,1,-0.00630567,-10.5398)">
                <g transform="matrix(0.0222222,0,0,0.0222222,0,0)">
                    <g transform="matrix(21.1624,-21.1624,21.1624,21.1624,32.1036,506.113)">
                        <path d="M1.504,22.496L24,22.496L24,25.504L-1.504,25.504L-1.504,-0L1.504,-0L1.504,22.496Z"/>
                    </g>
                </g>
            </g>
          </svg>
        </div>
      </div>
      <div class="ref-section _ref-sec g-fullwidth g-clr-0">
        <div class="ref-sec ">

          <div class="g-h2 ref-sec-title">
            <h2>
              <div class="_a" data-de="0">
                <span class="h-line _a-Y"><?= $post["title"][LANG] ?></span>
              </div>
            </h2>
            <h3>
              <div class="_a" data-de="200">
                <span class="h-line _a-Y"><?= $post["role"][LANG] ?></span>
              </div>
            </h3>
          </div>

        <?php MethodPosts::get_post_content($post["content_file"]); ?>
        </div>
      </div>

    </div>

    <?php endforeach; ?>

  </div>
</section>
