CodePen

HTML

            
              <div id="container">
	<div class="row">
		<div class="img-1"></div>
	</div>
	<img class="img-2" src="http://www.dropbox.com/s/ryhdc9s524l5drb/img.svg?dl=1">

	<a id="btn">
		Change size of second image
	</a>
</div>
            
          
!

↑ Insert the most common viewport meta tag

CSS

            
              .row {
	border-bottom: 1px solid #666;
	height: 100px;
	position: fixed;
		top: 0;
		left: 0;
    width: 100%;
}

.img-1 {
	background: url("http://www.dropbox.com/s/ryhdc9s524l5drb/img.svg?dl=1") no-repeat center center;
	display: block;
	height: 100px;
	width: 200px;
}

.img-2 {
	margin-top: 200px;
}

.change .img-2 {
	height: 40px;
	width: 120px;
}


#btn {
  background-color: #eee;
  border: 1px solid #aaa;
  border-radius: 4px;
  cursor: pointer;
  display: block;
  font: 13px sans-serif;
  margin-top: 100px;
  padding: 1em 0;
  text-align: center;
  width: 250px;
}

#btn:hover { background-color: #f7f7f7; }
#btn:active { background-color: #eee; }
            
          
!
? ?
? ?
Must be a valid URL.
+ add another resource
via CSS Lint

JS

            
              var btn       = document.getElementById('btn'),
    container = document.getElementById('container');

// Adds or removes "size" class
function changeClass() {
  if( container.className == '' ){
    container.className = 'change';
  } else {
    container.className = '';
  }
}

btn.onclick = changeClass;
            
          
!
Must be a valid URL.
+ add another resource
via JS Hint
Loading ..................