title: bootstrap 4 card-deck containing cards with different width
body: <p>I am trying to use a <code>card-deck</code> in bootstrap 4 which contain cards with different width.</p>
  
  <p>For single cards you do the following to change the width (or use class <code>w-25</code>, <code>w-50</code> or <code>w-75</code> if the 25%, 50% or 75% width fit your needs):</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet" /&gt;
  
  &lt;div class="container"&gt;
    &lt;div class="card"&gt;
      &lt;div class="card-header"&gt;Header&lt;/div&gt;
      &lt;div class="card-body"&gt;
        &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;br&gt;
    &lt;div class="card" style="width: 30%"&gt;
      &lt;div class="card-header"&gt;Header&lt;/div&gt;
      &lt;div class="card-body"&gt;
        &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;br&gt;
    &lt;div class="card" style="width: 70%"&gt;
      &lt;div class="card-header"&gt;Header&lt;/div&gt;
      &lt;div class="card-body"&gt;
        &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>For a <code>card-deck</code> containing cards with equal width you do this:</p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet" /&gt;
  
  &lt;div class="container"&gt;
    &lt;h1&gt;Card Deck with equal width&lt;/h1&gt;
    &lt;div class="card-deck"&gt;
      &lt;div class="card"&gt;
        &lt;div class="card-header"&gt;Header&lt;/div&gt;
        &lt;div class="card-body"&gt;
          &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;div class="card"&gt;
        &lt;div class="card-header"&gt;Header&lt;/div&gt;
        &lt;div class="card-body"&gt;
          &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
    &lt;br&gt;
  
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>To have a <code>card-deck</code> containing cards with different width I tried this (<strong>without success</strong>):<br><em>Note: The cards are displayed with equal width even that they have different width...</em></p>
  
  <p><div class="snippet" data-lang="js" data-hide="false" data-console="true" data-babel="false">
  <div class="snippet-code">
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;link href="https://stackpath.bootstrapcdn.com/bootstrap/4.1.3/css/bootstrap.min.css" rel="stylesheet" /&gt;
  
  &lt;div class="container"&gt;
    &lt;div class="card-deck"&gt;
      &lt;div class="card" style="width: 30%"&gt;
        &lt;div class="card-header"&gt;Header&lt;/div&gt;
        &lt;div class="card-body"&gt;
          &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
        &lt;/div&gt;
      &lt;/div&gt;
      &lt;div class="card" style="width: 70%"&gt;
        &lt;div class="card-header"&gt;Header&lt;/div&gt;
        &lt;div class="card-body"&gt;
          &lt;p class="card-text"&gt;Lorem ipsum dolor sit amet, consectetur adipisici elit.&lt;/p&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>so obviously I'm doing something wrong here (or bootstrap 4 is not supporting this). any suggestions how to use a <code>card-deck</code> containing cards with different width?</p>