.services-section {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 20px;
  max-width: 1200px;
  margin: 40px auto;
  padding: 0 16px; /* ✅ Add this for left-right padding on all devices */
  box-sizing: border-box;
}


@media (max-width: 340) {
  .services-section {
    grid-template-columns: 1fr;
    padding: 0 80px; /* ✅ More padding for smaller screens like Android */
  }

  .card {
    min-width: auto;
    width: 100%;
  }
}
* {
  box-sizing: border-box;
}


.card {
  flex: 1;
  min-width: 300px;
  padding: 30px;
  border-radius: 0px;
  position: relative;
  
  transition: transform 0.3s;
  background-color: white;
}

.icon-circle {
  width: 60px;
  height: 60px;
  background: linear-gradient(to bottom right, #6c63ff, #8e66f8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

.icon-circle img {
  width: 30px;
  height: 30px;
}

.card h3 {
  font-size: 20px;
  margin-bottom: 10px;
}

.card p {
  font-size: 16px;
  line-height: 1.5;
}

.card-number {
  margin-top: 20px;
  font-weight: bold;
  /* color: #6c63ff; */
  position: relative;
  display: inline-block;
}

.graphic .card-number {
  color: white;
}

.card-number::before {
  content: '';
  position: absolute;
  top: 50%;
  left: -30px;
  width: 20px;
  height: 2px;
  background-color: currentColor;
  transform: translateY(-50%);
}

.arrow-icon {
  position: absolute;
  top: 20px;
  right: 20px;
  background: white;
  color: #6c63ff;
  width: 32px;
  height: 32px;
  font-weight: bold;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card:hover {
  /* transform: translateY(-10px) scale(1.02);  */
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}
/* Optional: icon scale effect on hover */
.card:hover .icon-circle {
  transform: scale(1.1);
  transition: transform 0.3s ease;
}

/* Smooth transition for the arrow icon too */
.arrow-icon {
  position: absolute;
  top: 20px;
  right: 20px;
  background: white;
  color: #6c63ff;
  width: 32px;
  height: 32px;
  font-weight: bold;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.3s ease;
}

.card:hover .arrow-icon {
  transform: rotate(45deg);
}



.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  height: 100%;
  width: 0%;
  background: #41295a;  /* fallback for old browsers */
  background: linear-gradient(to right, #2F0743, #41295a);
  z-index: -1;
  transition: width 0.4s ease;
  border-radius: 6px;
}

.card:hover::before {
  width: 100%;
}

.card:hover {
  color: white;
}

/* Ensure nested elements follow the text color */
.card h3,
.card p,
.card-number {
  transition: color 0.2s ease;
}

.card:hover h3,
.card:hover p,
.card:hover .card-number {
  color: white;
}

/* Icon circle transition */
.icon-circle {
  width: 60px;
  height: 60px;
  background: #6c63ff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.card:hover .icon-circle {
  background-color: rgba(255, 255, 255, 0.2);
  transform: scale(1.1);
}

/* Card number line */
.card-number {
  margin-top: 20px;
  font-weight: bold;
  color: #6c63ff;
  position: relative;
  display: inline-block;
}

.card-number::before {
  content: '';
  position: absolute;
  top: 50%;
  left: -30px;
  width: 20px;
  height: 2px;
  background-color: currentColor;
  transform: translateY(-50%);
}

.card:hover .card-number::before {
  background-color: white;
}

/* Optional: arrow icon animation */
.arrow-icon {
  position: absolute;
  top: 20px;
  right: 20px;
  background: white;
  color: #007bff;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  font-weight: bold;
  opacity: 0;
  transform: translate(0, 0);
  transition: opacity 0.3s ease, transform 0.4s ease;
  z-index: 1;
}

/* Show and animate on hover */
.card:hover .arrow-icon {
  opacity: 1;
  transform: translate(10px, -10px); /* move up and to the right */
}
