Pen Settings

HTML

CSS

CSS Base

Vendor Prefixing

Add External Stylesheets/Pens

Any URLs added here will be added as <link>s in order, and before the CSS in the editor. You can use the CSS from another Pen by using its URL and the proper URL extension.

+ add another resource

JavaScript

Babel includes JSX processing.

Add External Scripts/Pens

Any URL's added here will be added as <script>s in order, and run before the JavaScript in the editor. You can use the URL of any other Pen and it will include the JavaScript from that Pen.

+ add another resource

Packages

Add Packages

Search for and use JavaScript packages from npm here. By selecting a package, an import statement will be added to the top of the JavaScript editor for this package.

Behavior

Auto Save

If active, Pens will autosave every 30 seconds after being saved once.

Auto-Updating Preview

If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.

Format on Save

If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.

Editor Settings

Code Indentation

Want to change your Syntax Highlighting theme, Fonts and more?

Visit your global Editor Settings.

HTML

              
                <div class="frosted-glass-group">
  <section class="frosted-glass">
    <div class="glass-top"></div>
  </section>
  <section class="front">
    <div class="glass-front"></div>
  </section>

  <img src="https://user-images.githubusercontent.com/13382614/111855540-68477c80-894b-11eb-9f87-8a6ae85079fd.png" alt="" class="shadow">

  <div class="details">
    <h3 class="section-title">Glass Morphism</h3>
    <p class="desc">Create 3d objects using pure css</p>
  </div>
  <a href="https://www.behance.net/gallery/115664441/Glass-Morphism-to-render-3d-products-in-figma" class="breakdown">Concept Breakdown</a>
</div>
              
            
!

CSS

              
                @import url("https://fonts.googleapis.com/css2?family=Poppins:wght@400;700&display=swap");

body {
  background-color: #16161c;
  font-family:font-family: Poppins;
  width: 100vw;
  height: 100vh;
  /*   uncomment the line below to add gradient heighlight background */
  /*   background: linear-gradient(248.72deg, #545661 -36.29%, #16161c 50.47%); */
}

.frosted-glass-group {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.frosted-glass {
  perspective: 1500px;
  width: 400px;
  height: 278px;
  /*background: linear-gradient(225deg, #04fffe 14.89%, #2ac870 85.85%) no-repeat center;
  background-position: 25px 175px;
  background-size: 350px 100px; */
}

section.frosted-glass:after {
  content: "";
  display: flex;
  height: 50%;
  width: 80%;
  margin: 30px;
  background: linear-gradient(225deg, #04fffe 14.89%, #2ac870 85.85%) no-repeat
    center;
  /* background: linear-gradient(
      0deg,
      #04fffec4 14.89%,
      rgb(42 200 112 / 20%) 85.85%
    )
    no-repeat center; */
  position: absolute;
  z-index: -1;
  top: 98px;
  transform: rotateX(45deg);
}

.front {
  width: 420px;
  height: 50px;
  perspective: 200px;
  background-size: 350px 42px;
  background-position: 25px 12px;
  position: relative;
  top: -34px;
  z-index: 1;
}

section.front:after {
  content: "";
  display: flex;
  height: 24px;
  width: 60%;
  background: linear-gradient(225deg, #04fffe 14.89%, #2ac870 85.85%) no-repeat center;
  position: absolute;
  z-index: -1;
  left: 5%;
  top: 58%;
  border-radius: 70px;
}

.glass-top {
  width: 100%;
  height: 100%;
  transform: rotateX(45deg);
  border-radius: 12px;
  backdrop-filter: blur(42px);
}

.glass-front {
  width: 100%;
  height: 100%;
  transform: rotateX(170deg);
  border-radius: 4px;
  backdrop-filter: blur(42px);
}

.shadow {
  position: relative;
  top: -80px;
  left: -10px;
  width: 580px;
  opacity: 1;
}

.details {
  display: flex;
  position: relative;
  top: -180px;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  z-index: -1;
}

.section-title {
  font-family: Poppins;
  margin: 0 auto;
  font-size: 180px;
  line-height: 80%;
  font-style: normal;
  font-weight: 700;
  letter-spacing: -0.0465em;
  text-align: left;
  background: linear-gradient(225deg, #04fffe 14.89%, #2ac870 85.85%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.desc {
  font-family: Poppins;
  font-size: 25px;
  font-style: normal;
  font-weight: 400;
  line-height: 24px;
  letter-spacing: 0em;
  text-align: left;
  color: white;
}

.breakdown {
  font-family: Poppins;
  font-size:24px;
  line-height:32px;
  text-decoration: none;
  color: white;
}

.breakdown:after {
  content:"";
  width:100%;
  display:block;
  margin-top:12px;
  background:linear-gradient(225deg, #04fffe 14.89%, #2ac870 85.85%);
  height:4px;
  
}

.breakdown:hover {
  background: linear-gradient(225deg, #2ac870 14.89%, #04fffe  85.85%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

              
            
!

JS

              
                
              
            
!
999px

Console