* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
   
}

body {
    background-color: #f3f4f6;
    
}

.card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}


.card-container {
  
  display: grid;
    grid-template-columns: repeat(3, 1fr);
    align-items: center;

    gap: 20px;
    padding: 20px;
}

/* Card Styling */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 30px;
  justify-content: center;
}

.card {
     width: 300px;
    height: 480px;
    background: #fff;
    /* box-shadow: 0 0 10px rgba(0, 0, 0, 0.1); */
    border-radius: 10px;
    overflow: hidden;
    display: flex
;
    flex-direction: column;
    justify-content: space-between;
    text-align: center;
    transition: transform 0.3s 
ease;
}

.card:hover {
  transform: translateY(-5px);
}



/* Left-side Text Section */
.card-text {
  flex-grow: 1;
  padding: 15px 20px;
}


.card-text h3 {
  font-size: 18px;
  font-weight: 600;
  margin-bottom: 8px;
  color: #000;
}


 
.card-text p {
  font-size: 14px;
  color: #555;
  text-align: start;
  line-height: 1.5;
  margin: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 3; /* show max 3 lines */
  -webkit-box-orient: vertical;
}

/* Center Image Section */
.card-image {
  width: 100%;
      height: 300px;
  overflow: hidden;
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover; /* ensures all images same height/width ratio */
}


/* Right-side Buttons Section */



.icon {
    font-size: 1.2em;
}

/* Responsive Design */
@media (max-width: 768px) {
    .card {
        flex-direction: column !important;
        height: auto;
    }
    .card-container {
  
  display: grid;
    grid-template-columns: repeat(1, 1fr);
    align-items: center;
justify-items: center !important;
    gap: 20px;
    padding: 20px;
}

    .card-text,
    .card-image,
    .card-buttons {
        width: 100%;
        text-align: center;
        padding: 10px;
    }

    .card-buttons {
        flex-direction: row;
        justify-content: center;
    }
}
#had{
  
font-size: 1rem;
    color: #141414;
    font-weight: 400;
    line-height: 1.67;
text-align: left;
color: #000;
text-underline-position: from-font;
text-decoration-skip-ink: none;

}
#had-down{
   
font-size: 19px;
font-weight: 400;
line-height: 23.2px;
text-align: left;
color: #fff;
text-underline-position: from-font;
text-decoration-skip-ink: none;
margin-top: 15px;

}
/* Button container */
.card-buttons {
    place-items: end;
    display: flex;
    gap: 16px;
    margin-bottom: 26px;
  justify-content: center;
       margin-right: 0px;
}
/* General button styles */
.card-buttons button {
      display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 11px;
    font-size: 16px;
    border-radius: 13px;
    border: none;
    width: fit-content;      /* Ensure the button width fits the content */
}

/* Styles for the visit button */
#visit {
 background-color: white;
    color: #058ACB;
    font-size: 18px;
    border: 2px solid;
}

/* Styles for the view case study button */
#view {
   background-color: transparent;
    border: 2px solid #000;
    color: #000;
   
}

/* Icon inside the button */
#visit img {
    height: 23px;             /* Set the icon size */
    width: auto;              /* Maintain the aspect ratio of the icon */
}
/* Remove underline from links */
.card-buttons a {
    text-decoration: none; /* Removes the underline from the links */
}
.card1 {
    background: #0095D5 !important;

}
.card2{
    background: #1E5DE4 !important;

}
.card3{
    background:#1E5DE4 !important;

}
.card4{
    background: #711EE4 !important;

}