Java, Python, Database, Flutter, Matlap, Micorcontroller, Tutorials, Swing Framework

Hancie e-Learning Studio

Learn Java, Learn HTML, CSS, PHP, Javascript, Python Tutorials || Download program source codes || Java Project and Source code available here || All types error troubleshooting tips available here

Responsive Card Slider in HTML CSS & JavaScript

 


index.html


<!DOCTYPE html>
<html lang="en">
<head>
<title>Hancie e-Learning Studio</title>
<!-- Swiper CSS -->
<link rel="stylesheet" href="resource/swiper-bundle.min.css">
</head>
<body>

<style>
/* Google Fonts - Poppins */
@import url('https://fonts.googleapis.com/css2?
family=Poppins:wght@300;400;500;600&display=swap');

*{
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}
body{
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #EFEFEF;
}
.slide-container{
  max-width: 1120px;
  width: 100%;
  padding: 40px 0;
}
.slide-content{
  margin: 0 40px;
  overflow: hidden;
  border-radius: 25px;
}
.card{
  border-radius: 25px;
  background-color: #FFF;
}
.image-content,
.card-content{
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 14px;
}
.image-content{
  position: relative;
  row-gap: 5px;
  padding: 25px 0;
}
.overlay{
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  background-color: #4070F4;
  border-radius: 25px 25px 0 25px;
}
.overlay::before,
.overlay::after{
  content: '';
  position: absolute;
  right: 0;
  bottom: -40px;
  height: 40px;
  width: 40px;
  background-color: #4070F4;
}
.overlay::after{
  border-radius: 0 25px 0 0;
  background-color: #FFF;
}
.card-image{
  position: relative;
  height: 150px;
  width: 150px;
  border-radius: 50%;
  background: #FFF;
  padding: 3px;
}
.card-image .card-img{
  height: 100%;
  width: 100%;
  object-fit: cover;
  border-radius: 50%;
  border: 4px solid #4070F4;
}
.name{
  font-size: 18px;
  font-weight: 500;
  color: #333;
}
.description{
  font-size: 14px;
  color: #707070;
  text-align: center;
}
.button{
  border: none;
  font-size: 16px;
  color: #FFF;
  padding: 8px 16px;
  background-color: #4070F4;
  border-radius: 6px;
  margin: 14px;
  cursor: pointer;
  transition: all 0.3s ease;
}
.button:hover{
  background: #265DF2;
}

.swiper-navBtn{
  color: #6E93f7;
  transition: color 0.3s ease;
}
.swiper-navBtn:hover{
  color: #4070F4;
}
.swiper-navBtn::before,
.swiper-navBtn::after{
  font-size: 35px;
}
.swiper-button-next{
  right: 0;
}
.swiper-button-prev{
  left: 0;
}
.swiper-pagination-bullet{
  background-color: #6E93f7;
  opacity: 1;
}
.swiper-pagination-bullet-active{
  background-color: #4070F4;
}

@media screen and (max-width: 768px) {
  .slide-content{
    margin: 0 10px;
  }
  .swiper-navBtn{
    display: none;
  }
}


</style>
        <div class="slide-container swiper">
<div class="slide-content">
    <div class="card-wrapper swiper-wrapper">
        <div class="card swiper-slide">
            <div class="image-content">
                <span class="overlay"></span>

                <div class="card-image">
                <img src="Hancie-Phago.jpg" alt="" class="card-img">
                </div>
            </div>

                        <div class="card-content">
    <h2 class="name">Hancie Phago</h2>
    <p class="description">The lorem text the section that
contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

    <button class="button">View More</button>
</div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
        <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

    <div class="card-content">
        <h2 class="name">Hancie Phago</h2>
        <p class="description">The lorem text the
section that contains header with having
open functionality. Lorem dolor sit
amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
        <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

     <div class="card-content">
        <h2 class="name">Hancie Phago</h2>
        <p class="description">The lorem
text the section that contains header with
having open functionality. Lorem dolor
sit amet consectetur adipisicing elit.</p>

<button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
        <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

    <div class="card-content">
   <h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text the section
that contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
        <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

    <div class="card-content">
  <h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text the section
that contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
<img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

     <div class="card-content">
  <h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text the section
that contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
<img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
      </div>

    <div class="card-content">
<h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text
the section that contains header with
having open functionality. Lorem
dolor sit amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
        <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

    <div class="card-content">
<h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text the section
that contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

  <button class="button">View More</button>
    </div>
</div>
<div class="card swiper-slide">
    <div class="image-content">
        <span class="overlay"></span>

        <div class="card-image">
            <img src="Hancie-Phago.jpg" alt="" class="card-img">
        </div>
    </div>

    <div class="card-content">
<h2 class="name">Hancie Phago</h2>
<p class="description">The lorem text the section
that contains header with having open functionality.
Lorem dolor sit amet consectetur adipisicing elit.</p>

        <button class="button">View More</button>
    </div>
</div>
</div>
            </div>

<div class="swiper-button-next swiper-navBtn"></div>
<div class="swiper-button-prev swiper-navBtn"></div>
<div class="swiper-pagination"></div>
        </div>

<script src="resource/swiper-bundle.min.js"></script>
        <script>
 
 var swiper = new Swiper(".slide-content", {
    slidesPerView: 3,
    spaceBetween: 25,
    loop: true,
    centerSlide: 'true',
    fade: 'true',
    grabCursor: 'true',
    pagination: {
      el: ".swiper-pagination",
      clickable: true,
      dynamicBullets: true,
    },
    navigation: {
      nextEl: ".swiper-button-next",
      prevEl: ".swiper-button-prev",
    },

    breakpoints:{
        0: {
            slidesPerView: 1,
        },
        520: {
            slidesPerView: 2,
        },
        950: {
            slidesPerView: 3,
        },
    },
  });


</script>


       
    </body>

 
</html>


Download Resources

































Welcome all to Hancie e-learning studio
Friends,
I have brought an e-learning platform for you from where you can teach internet, website, programming language, error troubleshooting, etc. Blogger, WordPress templates, themes are available for free on this website, which are not charged for downloading, so that you can earn money by blogging using such templates and this is not a difficult task and this You can do it now. You keep uploading new posts by us and keep taking advantage of this website. The aim of which is to spread the knowledge related to internet, career, web designing and technology to the people and contribute to the development of the country.