:root {
  --primary-color: #4a6bff;
  --secondary-color: #2c3e50;
  --light-color: #f8f9fa;
  --dark-color: #212529;
  --accent-color: #ff6b6b;
  --card-bg: #ffffff;
  --text-muted: #666;
  --border-radius: 15px;
  --box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
  --box-shadow-hover: 0 20px 40px rgba(0, 0, 0, 0.15);
}

.section {
  padding: 100px 0;

  @media (max-width: 991.98px) {
    padding: 80px 0;
  }

  @media (max-width: 767.98px) {
    padding: 60px 0;
  }
}

.section-title {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 60px;
  text-align: center;
  color: var(--secondary-color);
  position: relative;

  &::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background-color: var(--primary-color);
    border-radius: 2px;
  }

  @media (max-width: 991.98px) {
    font-size: 2rem;
  }
}

.portfolio-section {
  margin-top: 8vh;

  .card {
    border: none;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    background: var(--card-bg);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;

    &:hover {
      transform: translateY(-6px);
      box-shadow: var(--box-shadow-hover);
    }

    .card-img-top {
      height: 200px;
      object-fit: cover;
    }

    .card-body {
      padding: 1.25rem;
      display: flex;
      flex-direction: column;
      justify-content: space-between;
      flex-grow: 1;
    }

    .card-title {
      font-size: 1.25rem;
      font-weight: 600;
      color: var(--secondary-color);
      margin-bottom: 0.5rem;
    }

    .card-text {
      color: var(--text-muted);
      line-height: 1.6;
      margin-bottom: 0.75rem;
      flex-grow: 1;
    }

    .badge {
      font-size: 0.85rem;
      font-weight: 600;
      margin-bottom: 5px;
    }

    .mt-3 {
      margin-top: auto !important;
    }
  }
}

.projects-section {
  background-color: var(--light-color);

  .project-card {
    border: none;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    height: 100%;
    background: var(--card-bg);

    &:hover {
      transform: translateY(-10px);
      box-shadow: var(--box-shadow-hover);

      .project-img img {
        transform: scale(1.1);
      }
    }

    .project-img {
      height: 250px;
      overflow: hidden;

      img {
        width: 100%;
        height: 100%;
        object-fit: cover;
        transition: transform 0.5s ease;
      }
    }

    .project-content {
      padding: 1.5rem;

      .project-category {
        display: block;
        font-size: 0.9rem;
        font-weight: 600;
        color: var(--primary-color);
        margin-bottom: 0.5rem;
      }

      .project-title {
        font-size: 1.35rem;
        font-weight: 700;
        color: var(--secondary-color);
        margin-bottom: 0.75rem;
      }

      .project-description {
        color: var(--text-muted);
        line-height: 1.6;
        margin-bottom: 1rem;
      }

      .project-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        margin-bottom: 1rem;

        .badge {
          padding: 0.35em 0.75em;
          font-size: 0.8rem;
          font-weight: 500;
        }
      }

      .project-links {
        display: flex;
        gap: 15px;
        flex-wrap: wrap;
        align-items: center;

        a {
          color: var(--secondary-color);
          text-decoration: none;
          font-weight: 600;
          font-size: 0.9rem;
          display: flex;
          align-items: center;
          transition: color 0.3s ease;

          &:hover {
            color: var(--primary-color);
          }

          i {
            margin-right: 5px;
          }
        }
      }
    }
  }

.mt-3 .btn-sm {
  width: -webkit-fill-available;
  width: -moz-available;
  width: fill-available; /* fallback or future support */
}

  @media (max-width: 767.98px) {
    .project-links {
      justify-content: center;
    }
  }
}