Last active
May 17, 2024 07:14
-
-
Save martindrapeau/ef53b4d6fa7c1d7092cdb7352638b194 to your computer and use it in GitHub Desktop.
Carbon ads CSS - Responsive bottom-right fixed position
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@media (min-width: 992px) { | |
#carbonads { | |
position: fixed; | |
right: 0; | |
bottom: 0; | |
box-sizing: border-box; | |
float: right; | |
background-color: rgba(0,0,0, 0.1); | |
padding: 1.5rem; | |
width: 32rem; | |
text-align: left !important; | |
margin: 0; | |
min-height: 1.3rem; | |
z-index: 1000; | |
border-top-left-radius: 10px; | |
} | |
#carbonads .carbon-img { | |
float: left; | |
width: 14.5rem; | |
} | |
#carbonads .carbon-poweredby { | |
margin-top: 1rem; | |
display: block; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
On desktop and landscape tablet (992px and above), the carbon ad is fixed bottom right. On smaller screens, original CSS is maintainted. Preview here on CSVJSON.
Derived from an existing gist by blivesta.