<!doctype html>
<html>
<head>
<meta charset='utf-8'>
<style>
.content {
border: 3px solid grey;
}
.content + .content > .item > .copy-this {
color: yellow;
background: black;
}
.random-div {
color: brown;
}
.ruler {
width: 600px;
background: blue;
height: 5px;
border: 3px dashed gold;
}
.box::before {
content: '600px';
color: blue;
}
@media (min-width:600px) {
.content + .content > .item > .copy-this {
display: none;
}
}
</style>
</head>
<body>
<div class="content">
<div class="item">
<div class="copy-this">Some info 1[#1]</div>
<div class="random-div">Not to copy 1[#1]</div>
</div>
<div class="item">
<div class="copy-this">Some info 2[#1]</div>
</div>
<div class="item">
<div class="copy-this">Some info 3[#1]</div>
<div class="random-div">Not to copy 2[#1]</div>
</div>
<div class="item">
<div class="copy-this">Some info 4[#1]</div>
</div>
</div>
<div class="content">
<div class="item">
</div>
<div class="item">
<div class="random-div">This is original content[#2]</div>
</div>
<div class="item">
</div>
<div class="item">
</div>
</div>
<span class='box'></span>
<hr class='ruler'>
<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
<script>
$('.copy-this').each(function(idx, obj) {
var target = $('.content + .content > .item').eq(idx);
var clone = $(this).clone(true, true);
target.prepend(clone);
});
</script>
</body>
</html>
// Code goes here
/* Styles go here */