title: Bootstrap CSS for Carousel controls
body: <p>Right so I need some help from CSS experts who can tell me what I'm looking at because I'm very new at this and I've been straying through the CSS forest without a map.</p>
  
  <p>I have a website with a number of modals. Each modal has a carousel of images. </p>
  
  <p>The images have some unwanted empty space around them. This empty space is part of the class="carousel-inner" div. I noticed the size of that div was 720 by 480 pixels and my images were smaller. So the first thing I did was resize the images in photoshop. That removed the empty space on the sides, but not below.</p>
  
  <p>Then I tried controlling the size of the carousel-inner div by adding some CSS of my own. That largely went nowhere, and really messed up the responsiveness of the whole modal.</p>
  
  <p>So I assume there is something in the CSS code relating to the carousel that is doing this. Unfortunately, there's so much of it that I really don't know what to change. I've fiddled around with some of it, but that either had no effect, or it messed stuff up.</p>
  
  <p>Any pointers would be greatly appreciated. I've been googling and fiddling with this stuff for hours..!</p>
  
  <p>So here's the code:</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-css lang-css prettyprint-override"><code>  .carousel {
    position: relative;
  }
  
  .carousel-inner {
    position: relative;
    max-width: 100%;
    overflow: hidden;
  }
  
  .carousel-inner&gt;.item {
    position: relative;
    display: none;
    -webkit-transition: .6s ease-in-out left;
    -o-transition: .6s ease-in-out left;
    transition: .6s ease-in-out left;
  }
  
  .carousel-inner&gt;.item&gt;img,
  .carousel-inner&gt;.item&gt;a&gt;img {
    line-height: 1;
  }
  
  @media all and (transform-3d),
  (-webkit-transform-3d) {
    .carousel-inner&gt;.item {
      -webkit-transition: -webkit-transform .6s ease-in-out;
      -o-transition: -o-transform .6s ease-in-out;
      transition: transform .6s ease-in-out;
      -webkit-backface-visibility: hidden;
      backface-visibility: hidden;
      -webkit-perspective: 1000px;
      perspective: 1000px;
    }
    .carousel-inner&gt;.item.next,
    .carousel-inner&gt;.item.active.right {
      left: 0;
      -webkit-transform: translate3d(100%, 0, 0);
      transform: translate3d(100%, 0, 0);
    }
    .carousel-inner&gt;.item.prev,
    .carousel-inner&gt;.item.active.left {
      left: 0;
      -webkit-transform: translate3d(-100%, 0, 0);
      transform: translate3d(-100%, 0, 0);
    }
    .carousel-inner&gt;.item.next.left,
    .carousel-inner&gt;.item.prev.right,
    .carousel-inner&gt;.item.active {
      left: 0;
      -webkit-transform: translate3d(0, 0, 0);
      transform: translate3d(0, 0, 0);
    }
  }
  
  .carousel-inner&gt;.active,
  .carousel-inner&gt;.next,
  .carousel-inner&gt;.prev {
    display: block;
  }
  
  .carousel-inner&gt;.active {
    left: 0;
  }
  
  .carousel-inner&gt;.next,
  .carousel-inner&gt;.prev {
    position: absolute;
    top: 0;
    width: 100%;
  }
  
  .carousel-inner&gt;.next {
    left: 100%;
  }
  
  .carousel-inner&gt;.prev {
    left: -100%;
  }
  
  .carousel-inner&gt;.next.left,
  .carousel-inner&gt;.prev.right {
    left: 0;
  }
  
  .carousel-inner&gt;.active.left {
    left: -100%;
  }
  
  .carousel-inner&gt;.active.right {
    left: 100%;
  }
  
  .carousel-control {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    width: 15%;
    font-size: 20px;
    color: #fff;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .6);
    background-color: rgba(0, 0, 0, 0);
    filter: alpha(opacity=50);
    opacity: .5;
  }
  
  .carousel-control.left {
    background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
    background-image: -o-linear-gradient(left, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
    background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .5)), to(rgba(0, 0, 0, .0001)));
    background-image: linear-gradient(to right, rgba(0, 0, 0, .5) 0%, rgba(0, 0, 0, .0001) 100%);
    filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#80000000', endColorstr='#00000000', GradientType=1);
    background-repeat: repeat-x;
  }
  
  .carousel-control.right {
    right: 0;
    left: auto;
    background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
    background-image: -o-linear-gradient(left, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
    background-image: -webkit-gradient(linear, left top, right top, from(rgba(0, 0, 0, .0001)), to(rgba(0, 0, 0, .5)));
    background-image: linear-gradient(to right, rgba(0, 0, 0, .0001) 0%, rgba(0, 0, 0, .5) 100%);
    filter: progid:DXImageTransform.Microsoft.gradient(startColorstr='#00000000', endColorstr='#80000000', GradientType=1);
    background-repeat: repeat-x;
  }
  
  .carousel-control:hover,
  .carousel-control:focus {
    color: #fff;
    text-decoration: none;
    filter: alpha(opacity=90);
    outline: 0;
    opacity: .9;
  }
  
  .carousel-control .icon-prev,
  .carousel-control .icon-next,
  .carousel-control .glyphicon-chevron-left,
  .carousel-control .glyphicon-chevron-right {
    position: absolute;
    top: 50%;
    z-index: 5;
    display: inline-block;
    margin-top: -10px;
  }
  
  .carousel-control .icon-prev,
  .carousel-control .glyphicon-chevron-left {
    left: 50%;
    margin-left: -10px;
  }
  
  .carousel-control .icon-next,
  .carousel-control .glyphicon-chevron-right {
    right: 50%;
    margin-right: -10px;
  }
  
  .carousel-control .icon-prev,
  .carousel-control .icon-next {
    width: 20px;
    height: 20px;
    font-family: serif;
    line-height: 1;
  }
  
  .carousel-control .icon-prev:before {
    content: '\2039';
  }
  
  .carousel-control .icon-next:before {
    content: '\203a';
  }
  
  .carousel-indicators {
    position: absolute;
    bottom: 10px;
    left: 50%;
    z-index: 15;
    width: 60%;
    padding-left: 0;
    margin-left: -30%;
    text-align: center;
    list-style: none;
  }
  
  .carousel-indicators li {
    display: inline-block;
    width: 10px;
    height: 10px;
    margin: 1px;
    text-indent: -999px;
    cursor: pointer;
    background-color: #000 \9;
    background-color: rgba(0, 0, 0, 0);
    border: 1px solid #fff;
    border-radius: 10px;
  }
  
  .carousel-indicators .active {
    width: 12px;
    height: 12px;
    margin: 0;
    background-color: #fff;
  }
  
  .carousel-caption {
    position: absolute;
    right: 15%;
    bottom: 20px;
    left: 15%;
    z-index: 10;
    padding-top: 20px;
    padding-bottom: 20px;
    color: #fff;
    text-align: center;
    text-shadow: 0 1px 2px rgba(0, 0, 0, .6);
  }
  
  .carousel-caption .btn {
    text-shadow: none;
  }
  
  @media screen and (min-width: 768px) {
    .carousel-control .glyphicon-chevron-left,
    .carousel-control .glyphicon-chevron-right,
    .carousel-control .icon-prev,
    .carousel-control .icon-next {
      width: 30px;
      height: 30px;
      margin-top: -10px;
      font-size: 30px;
    }
    .carousel-control .glyphicon-chevron-left,
    .carousel-control .icon-prev {
      margin-left: -10px;
    }
    .carousel-control .glyphicon-chevron-right,
    .carousel-control .icon-next {
      margin-right: -10px;
    }
    .carousel-caption {
      right: 20%;
      left: 20%;
      padding-bottom: 30px;
    }
    .carousel-indicators {
      bottom: 20px;
    }</code></pre>
  <pre class="snippet-code-html lang-html prettyprint-override"><code>&lt;!-- Portfolio Modal 1 --&gt;
  &lt;div class="portfolio-modal modal fade" id="portfolioModal1" tabindex="-1" role="dialog" aria-hidden="true"&gt;
    &lt;div class="modal-dialog"&gt;
      &lt;div class="modal-content"&gt;
        &lt;div class="close-modal" data-dismiss="modal"&gt;
          &lt;div class="lr"&gt;
            &lt;div class="rl"&gt;
            &lt;/div&gt;
          &lt;/div&gt;
        &lt;/div&gt;
        &lt;div class="container"&gt;
          &lt;div class="row"&gt;
            &lt;div class="col-lg-8 col-lg-offset-2"&gt;
              &lt;div class="modal-body"&gt;
                &lt;!-- Project Details Go Here --&gt;
                &lt;h2&gt;Dissonance&lt;/h2&gt;
                &lt;p class="item-intro text-muted"&gt;Kourse Theater, 2016&lt;/p&gt;
                &lt;div id="myCarousel" class="carousel slide" data-ride="carousel"&gt;
                  &lt;!-- Indicators --&gt;
                  &lt;ol class="carousel-indicators"&gt;
                    &lt;li data-target="#myCarousel" data-slide-to="0" class="active" &lt;/li&gt;
                    &lt;li data-target="#myCarousel" data-slide-to="1" &lt;/li&gt;
                    &lt;li data-target="#myCarousel" data-slide-to="2" &lt;/li&gt;
                  &lt;/ol&gt;
                  &lt;!-- Wrapper for slides --&gt;
                  &lt;div class="carousel-inner"&gt;
                    &lt;div class="item active"&gt;
                      &lt;img class="img-responsive img-centered" src="http://i577.photobucket.com/albums/ss219/presmo/dissonanceCarousel0.jpg" alt="DiPreview0"&gt;
                    &lt;/div&gt;
                    &lt;div class="item"&gt;
                      &lt;img class="http://i577.photobucket.com/albums/ss219/presmo/dissonanceCarousel1.jpg" alt="DiPreview1"&gt;
                    &lt;/div&gt;
                    &lt;div class="item"&gt;
                      &lt;img class="img-responsive img-centered" src="http://i577.photobucket.com/albums/ss219/presmo/dissonanceCarousel2.jpg" alt="DiPreview2"&gt;
                    &lt;/div&gt;
                  &lt;/div&gt;
                  &lt;!-- Left and right controls start : When I remove this block, the problem disappears --&gt;
                  &lt;a class="left carousel-control" href="#myCarousel" data-slide="prev"&gt;
                    &lt;span class="glyphicon glyphicon-chevron-left"&gt;&lt;/span&gt;
                  &lt;/a&gt;
                  &lt;a class="right carousel-control" href="#myCarousel" data-slide="next"&gt;
                    &lt;span class="glyphicon glyphicon-chevron-right"&gt;&lt;/span&gt;
                  &lt;/a&gt;
                  &lt;!-- Left and right controls end : When I remove this block, the problem disappears --&gt;
                &lt;/div&gt;
                &lt;p&gt;Some text&lt;/p&gt;
                &lt;p&gt;some text&lt;/p&gt;
                &lt;button type="button" class="btn btn-primary" data-dismiss="modal"&gt;&lt;i class="fa fa-times"&gt;&lt;/i&gt; Close Project&lt;/button&gt;
              &lt;/div&gt;
            &lt;/div&gt;
          &lt;/div&gt;
        &lt;/div&gt;
      &lt;/div&gt;
    &lt;/div&gt;
  &lt;/div&gt;</code></pre>
  </div>
  </div>
  </p>
  
  <p>And an image to show you what I mean:
  <a href="https://i.stack.imgur.com/bkYCs.png" rel="nofollow noreferrer">Screenshot</a></p>