I am trying to style click button further. Is it possible?

Here is my current button:


red plain color.

I would like to put orange border with transparent background.


<!DOCTYPE html>
<meta charset="utf-8">

<link rel="stylesheet" type="text/css" href="css/style.css">


.btn {

     width: 100px;
     background-color: red;
     color: white;  


#box {

      padding: 10px;


.yellow, .grey, .red, .classy {

      padding: 8px;




<?php include('nav.php'); ?>


<center><h2><b>Our Portfolio</b></h2></center>
Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero eros et accumsan et iusto odio dignissim

<div id="filters" class="button-group">
  <button class="btn" data-filter="*">All</button>
  <button class="btn" data-filter=".yellow">Yellow</button>
  <button class="btn" data-filter=".red">Red</button>
  <button class="btn" data-filter=".grey">Grey</button>
  <button class="btn" data-filter=".classy">Classy</button>

<div id="box">
  <div class="grey" data-category="transition" data-name="classy6">
    <img class="name" src="Images/Portfolio/portfolio1.jpg" width="270px">    
  <div class="red" data-category="metalloid" data-name="classy5">
    <img class="name" src="Images/Portfolio/portfolio2.jpg" width="270px">   
  <div class="yellow" data-category="metalloid2" data-name="classy4">
    <img class="name" src="Images/Portfolio/portfolio3.jpg" width="270px">   
  <div class="classy" data-category="metalloid3" data-name="classy3">    
    <img class="name" src="Images/Portfolio/portfolio4.jpg" width="270px">

  <div class="yellow" data-category="metalloid4" data-name="classy2">
    <img class="name" src="Images/Portfolio/portfolio5.jpg" width="270px">   
  <div class="grey" data-category="metalloid5" data-name="classy1">  
    <img class="name" src="Images/Portfolio/portfolio6.jpg" width="270px">
<script src="https://ajax.googleapis.com/ajax/libs/jquery/1.11.3/jquery.min.js"></script>
<script src="//cdnjs.cloudflare.com/ajax/libs/jquery.isotope/2.2.0/isotope.pkgd.min.js"></script>
  /*var $grid = $grid.isotope({*/
  var $container = $('#box').isotope({ 
    getSortData: {
      name: '[data-name]',
      symbol: '.symbol',
      number: '.number parseInt',
      category: '[data-category]',
      weight: function( itemElem ) {
        var weight = $( itemElem ).find('.weight').text();
        return parseFloat( weight.replace( /[\(\)]/g, '') );
  // sort items on button click
  $('#sorts').on( 'click', 'button', function() {
    var sortByValue = $(this).attr('data-sort-by');
    $container.isotope({ sortBy: sortByValue });

<!-- filter -->


// init Isotope
var $container = $('#box').isotope({
  // options
// filter items on button click
$('#filters').on( 'click', 'button', function() {
  var filterValue = $(this).attr('data-filter');
  $container.isotope({ filter: filterValue });



$container.isotope({ filter: '.yellow' });
$container.isotope({ filter: '.red' });
$container.isotope({ filter: '.grey' });
$container.isotope({ filter: '.classy' });
$container.isotope({ filter: '*' });


<!-- end filter -->

<img src="Images/Portfolio/clients.jpg">

<div align="center">
Lorem ipsum dolor sit amet, consectetuer adipiscing <br>elit, sed diam nonummy nibh euismod <br>tincidunt ut laoreet dolore magna aliquam<br> erat volutpat.<br>
<b>dolore magna aliquam</b><br><br>

<?php include('footer.php'); ?>

Member Avatar

You should apply the .btn class a border: 1px solid orange and background-color: transparent

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, learning, and sharing knowledge.