/** * Importing some libs */ @import url(http://maxcdn.bootstrapcdn.com/font-awesome/4.2.0/css/font-awesome.min.css); @import url(//cdnjs.cloudflare.com/ajax/libs/weather-icons/1.2/css/weather-icons.css); /** * Defining some variables */ $font-stack: 'Helvetica Neue', Helvetica, sans-serif; $gradient-color: linear-gradient(45deg, #539FA2 0%, #72B1A4 33%, #C4DBB4 67%, #ABCCB1, #61B2C3); /** * Let's work */ html, body {min-height: 100%;} p {margin: 0;} a {text-decoration: none;} body { width: 100%; height: 100%; background: $gradient-color; background-size: 600% 100%; animation: HeroBG 60s ease infinite; overflow: hidden; } @keyframes HeroBG { 0% { background-position:0 0 } 50% { background-position:100% 0 } 100% { background-position:0 0 } } .app { height: 150px; width: 280px; margin: 150px auto; background-color: #fff; border-radius: 5px 5px 10px 5px; } .square { margin: 0; width: 160px; height: 150px; background-color: #2c3e50; color: #fff; text-align: center; float: left; border-radius: 5px 0 0 5px; } p.temp { font-size: 5em; padding: 10px 0 0 10px; font-family: $font-stack; font-weight: 100; color: #f1c40f; } p.city { font-size: .9em; font-family: $font-stack; font-weight: 700; text-transform: uppercase; letter-spacing: .1em; } .icon { width: 100%; height: 60px; text-align: center; padding-top: 25px; margin-left: 10px; color: #2c3e50; font-size: 3em; } .forecast { width: 100%; background-color: #3498db; height: 49px; border-radius: 0 0 5px 5px; } ul { list-style-type: none; text-align: center; width: 100%; li { float:left; text-align: center; font-family: $font-stack; color: #fff; margin: 5px; } } li:first-child { margin-left: 16px; } .day { color: #2980b9; font-size: .6em; font-weight: 700; text-transform: uppercase; } .temp-fore { font-weight: 200; font-size: .8em; letter-spacing: 0.08em; } .source { font-size: .8em; width: 100%; text-align: center; margin: 20px 0; color: #000; opacity: .2; font-family: $font-stack; } .source a {color: #000;} /** *It hides the 4th element and above */ .forecast li:nth-child(n+4) { display: none; }