.publications-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 30px;
  margin-top: 40px;

  @media (min-width: 992px) {
    grid-template-columns: 1fr 1fr;
  }
}

/* Publication Cards */
.publication-card {
  background: white;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  height: 100%;
  display: flex;
  flex-direction: column;
  @include custom-shade;

  &:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);

    .publication-image img {
      transform: scale(1.05);
    }
  }

  &.small {
    align-items: center;

    .publication-image {
      height: 250px;
      width: 100%;
    }

    .publication-content {
      padding: 15px;
      border-top: 1px solid #c3c3c32d;
    }

    .publication-title {
      font-size: 16px;
      font-family: $secondaryFont;

      &:hover {
        text-decoration: underline;
      }
    }
  }
}

/* Featured Publication */
.featured-publication {
  .publication-card {
    border-left: 4px solid $primaryColor;
  }

  .publication-image {
    height: 500px;
    // background-color: #f3f4f4;
  }
}

/* Small Publications Grid */
.other-publications {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px;

  @media (min-width: 768px) {
    grid-template-columns: 1fr 1fr;
  }
}

/* Publication Image */
.publication-image {
  position: relative;
  overflow: hidden;

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

.publication-badge {
  position: absolute;
  top: 15px;
  left: 15px;
  background: $secondaryColor;
  color: white;
  padding: 5px 10px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Publication Content */
.publication-content {
  padding: 25px;
  flex: 1;

  .publication-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    font-size: 12px;
    color: $textColor;
    text-transform: uppercase;

    .publication-type {
      color: $primaryColor;
      @include text-ellips;
    }
  }

  .publication-title {
    font-size: 20px;
    font-weight: 400;
    color: $blackColor;
    line-height: 1.4;
    font-family: $secondaryFont;
    @include text-ellips;

    &:hover {
      text-decoration: underline;
    }
  }

  .publication-excerpt {
    color: $textColor;
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 20px;
  }

  .publication-link {
    color: $primaryColor;
    font-weight: 600;
    font-size: 14px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    transition: all 0.3s ease;

    &:hover {
      color: $secondaryColor;

      i {
        transform: translateX(3px);
      }
    }

    i {
      transition: transform 0.3s ease;
    }
  }
}




/* -------- Single Publication (Same as Small) -------- */
.single-publication {
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  align-items: center;
  @include custom-shade;
  margin-bottom: 20px;

  &:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);

    .single-publication-image img {
      transform: scale(1.05);
    }

    
  }

  /* Image */
  .single-publication-image {
    height: 220px;
    width: 100%;
    overflow: hidden;
    position: relative;

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

     /* Overlay on Hover */
    .image-overlay {
      position: absolute;
      top: 0;
      left: 0;
      height: 100%;
      width: 100%;
      background: #034081e0;
      display: flex;
      justify-content: center;
      align-items: center;
      padding: 15px;
      opacity: 0;
      visibility: hidden;
      transform: translateY(40px);
      transition: all 0.4s ease;

      .overlay-title {
        color: #fff;
        font-size: 16px;
        font-weight: 500;
        line-height: 1.4;
        text-align: center;
        font-family: $secondaryFont;
      }
    }
  }

  /* Content */
  .single-publication-content {
    padding: 15px;
    width: 100%;
    border-top: 1px solid #c3c3c32d;

    .single-publication-title {
      font-size: 16px;
      font-family: $secondaryFont;
      font-weight: 400;
      color: $blackColor;
      @include text-ellips;

      &:hover {
        text-decoration: underline;
      }
    }
.publication-meta {
    display: flex;
    justify-content: space-between;
    margin-bottom: 5px;
    font-size: 12px;
    color: $textColor;
    text-transform: uppercase;

    .publication-type {
      color: $primaryColor;
      @include text-ellips;
    }
  }
    
  }
}


.single-publication:hover .image-overlay {
      opacity: 1;
      visibility: visible;
      transform: translateY(0);
    }