title: How can I add text to my hexagonal elements?
body: <p>I'm trying to make a grid of hexagons and I need some text on top of these hexagons. I have tried different things but nothing has worked.</p>
  
  <p>I also tried to place a background-image on top of it (with the number), but I also can't get the image on it.</p>
  
  <p><strong>HTML/CSS</strong></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="false" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-css lang-css prettyprint-override"><code>.container {
    width: 1000px; 
    line-height: 1.3;
    margin-left: 30%;
  }
  ol.even {
    position: relative;
    left: 3.63em;
  }
  ol.odd {
    position: relative;
    margin-top: -6.5%;
    margin-bottom: -6.5%;
  }
  .hex {
    position: relative;
    margin: 1em auto;
    width: 4em; 
    height: 6.8em;
    border-radius: 1em/.5em;
    background: #ccc;
    transform: rotate(-90deg);
    display: inline-block;
    margin-right: 3em;
    transition: all 150ms ease-in-out;
  }
  .hex:before, .hex:after {
    position: absolute;
    width: inherit; height: inherit;
    border-radius: inherit;
    background: inherit;
    content: '';
  }
  .hex:before {
    transform: rotate(60deg);
  }
  .hex:after {
    transform: rotate(-60deg);
  }
  .hex:hover {
    background: #F58787;
    cursor: pointer;
  }
  
  #hexMidden:hover {
    background: #ccc;
    cursor: auto;
  }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;body&gt;
      &lt;div class="container"&gt;
          &lt;ol class="even"&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
          &lt;/ol&gt;  
          &lt;ol class="odd"&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
              &lt;li class='hex' id="hexMidden"&gt;&lt;/li&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
          &lt;/ol&gt;
          &lt;ol class="even"&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
              &lt;li class='hex'&gt;&lt;/li&gt;
          &lt;/ol&gt;  
      &lt;/div&gt;
  &lt;/body&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>The code above I found on the Internet.</p>