public
Last active

planetary system

  • Download Gist
dabblet.css
CSS
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220
/**
* planetary system
*/
html {
min-height: 100%;
overflow: hidden;
background: #000;
font: 13px/1.56 Helvetica;
}
input {display: none;}
label {
position: absolute;
z-index: 10;
color: #fff;
}
label {cursor: pointer;}
 
label[for*="zoom"], .fake-slider {top: 50px; height: 1.56em; transition: .95s ease-in;}
label[for*="zoom"] { width: 50px; text-align: center; }
label[for="zoomout50"] { left: 15px; }
label[for="zoomout67"] { left: 65px; }
label[for="zoomout75"] { left: 115px; }
label[for="zoomauto"] { left: 165px; }
input:checked + label { color: #000; font-weight: 700; }
.fake-slider {
left: 15px;
width: 200px;
border-radius: .35em;
position: absolute;
z-index: 9;
background: rgba(255,255,255,.4) linear-gradient(left, rgba(255,255,255,.94) 25%, rgba(255,255,255,.4) 25%) no-repeat;
background-size: 100% 100%;
}
#zoomout50:checked ~ .fake-slider {background-position: 0 0;}
#zoomout67:checked ~ .fake-slider {background-position: 50px 0;}
#zoomout75:checked ~ .fake-slider {background-position: 100px 0;}
#zoomauto:checked ~ .fake-slider {background-position: 150px 0;}
#zoomout50:checked ~ .planetary-system {transform: scale(.5);}
#zoomout67:checked ~ .planetary-system {transform: scale(.67);}
#zoomout75:checked ~ .planetary-system {transform: scale(.75);}
#zoomauto:checked ~ .planetary-system {transform: scale(1);}
.plane {
top: 0;
right: 0;
bottom: 0;
left: 0;
position: fixed;
}
.round {
min-width: 10px;
min-height: 10px;
border-radius: 50%;
}
.trace {
border: dashed 1px #ccc;
}
.orbit, .trace {
left: 50%;
top: 50%;
position: absolute;
}
.planet {
position: relative;
}
 
.planetary-system {
/**animation: wobble 9s infinite ease-in-out;/**/
transition: .95s ease-in;
}
@keyframes wobble {
0% { transform: rotate(0deg); }
65% { transform: rotate(10deg); }
100% { transform: rotate(0deg); }
}
 
.star-a .star {
width: 95px;
height: 95px;
margin: -47px 0 0 -47px;
border-radius: 50%;
box-shadow: 0 0 20px #ffc, 0 0 30px #fe8, 0 0 40px #fb3,
0 0 50px #e70, 0 0 60px #c40, 0 0 70px #931, 0 0 80px #410;
background: #dcdaa7;
}
 
.planet-a {
transform: skewX(-30deg) skewY(-15deg);
}
.planet-a .trace {
width: 320px;
height: 320px;
margin: -160px 0 0 -160px;
}
.planet-a .orbit {
animation: planet-a-motion 10s infinite linear;
}
@keyframes planet-a-motion {
from { transform: rotate(0deg) translate(-160px) rotate(0deg); }
to { transform: rotate(360deg) translate(-160px) rotate(-360deg); }
}
.planet-a .planet {
width: 34px;
height: 34px;
margin: -17px 0 0 -17px;
box-shadow: 0 0 5px #fff, 0 0 10px #ff7, 0 0 15px #fe0, 0 0 20px #f70;
transform: skewY(15deg) skewX(30deg);
background: radial-gradient(top left,
rgb(213,174,131), rgb(237,205,167) 33%,
rgb(163,161,122) 67%, rgb(101,84,74));
}
.moon-a-1 {
/**/transform: skewX(30deg) skewY(-15deg);/**/
}
.moon-a-1 .trace {
width: 70px;
height: 70px;
margin: -35px 0 0 -35px;
}
.moon-a-1 .orbit {
animation: moon-a-1-motion 7s infinite linear;
}
@keyframes moon-a-1-motion {
from { transform: rotate(0deg) translate(-35px) rotate(0deg); }
to { transform: rotate(360deg) translate(-35px) rotate(-360deg); }
}
.moon-a-1 .moon {
width: 14px;
height: 14px;
margin: -7px 0 0 -7px;
box-shadow: 0 0 5px #fff, 0 0 10px #ff7;
/**transform: skewY(15deg) skewX(-30deg);/**/
background: radial-gradient(top left,
rgb(213,255,131), rgb(237,205,167) 33%,
rgb(255,161,122) 67%, rgb(255,84,74));
}
 
.planet-b {
transform: skewX(-45deg) skewY(-15deg);
}
.planet-b .trace {
width: 850px;
height: 850px;
margin: -425px 0 0 -425px;
}
.planet-b .orbit {
animation: planet-b-motion 29s infinite linear;
}
@keyframes planet-b-motion {
from { transform: rotate(0deg) translate(-425px) rotate(0deg); }
to { transform: rotate(360deg) translate(-425px) rotate(-360deg); }
}
.planet-b .planet {
width: 70px;
height: 70px;
margin: -35px 0 0 -35px;
box-shadow: 0 0 5px rgb(182, 156, 132), 0 0 10px rgb(171, 168, 175), 0 0 15px rgb(214, 231, 232), 0 0 20px rgb(179, 171, 160), 0 0 25px #0f3;
transform: skewY(15deg) skewX(45deg);
background:radial-gradient(0% 0%,
rgb(123, 109, 100) 5%, rgb(182, 156, 132) 10%,
rgb(182, 156, 132) 15%, rgb(182, 156, 132) 20%,
rgb(196, 209, 228) 25%, rgb(197, 181, 155) 30%,
rgb(149, 133, 119) 35%, rgb(171, 168, 175) 40%,
rgb(165, 134, 116) 45%, rgb(182, 156, 132) 50%,
rgb(233, 232, 218) 55%, rgb(172, 150, 127) 60%,
rgb(154, 113, 81) 65%, rgb(214, 231, 232) 70%,
rgb(150, 138, 121) 75%, rgb(178, 164, 169) 80%,
rgb(173, 154, 144) 85%, rgb(179, 171, 160) 90%,
rgb(143, 127, 112) 95%, rgb(101, 95, 87) 100%);
}
.moon-b-1 {
/**/transform: skewX(30deg) skewY(-15deg);/**/
}
.moon-b-1 .trace {
width: 130px;
height: 130px;
margin: -65px 0 0 -65px;
}
.moon-b-1 .orbit {
animation: moon-b-1-motion 7s infinite linear;
}
@keyframes moon-b-1-motion {
from { transform: rotate(0deg) translate(-65px) rotate(0deg); }
to { transform: rotate(360deg) translate(-65px) rotate(-360deg); }
}
.moon-b-1 .moon {
width: 26px;
height: 26px;
margin: -13px 0 0 -13px;
box-shadow: 0 0 5px #fff, 0 0 10px #ff7;
/**/transform: skewY(15deg) skewX(-30deg);/**/
background: radial-gradient(top left,
rgb(213,255,131), rgb(237,205,167) 33%,
rgb(161,255,122) 67%, rgb(84,255,74));
}
.moon-b-2 {
/**/transform: skewX(30deg) skewY(-15deg);/**/
}
.moon-b-2 .trace {
width: 190px;
height: 190px;
margin: -95px 0 0 -95px;
}
.moon-b-2 .orbit {
animation: moon-b-2-motion 10s infinite linear;
}
@keyframes moon-b-2-motion {
from { transform: rotate(360deg) translate(-95px) rotate(-360deg); }
to { transform: rotate(0deg) translate(-95px) rotate(0deg); }
}
.moon-b-2 .moon {
width: 13px;
height: 13px;
margin: -7px 0 0 -7px;
box-shadow: 0 0 5px #fff, 0 0 10px #ff7;
/**/transform: skewY(15deg) skewX(-30deg);/**/
background: radial-gradient(top left,
rgb(213,131,255), rgb(237,205,255) 33%,
rgb(161,122,255) 67%, rgb(84,74,255));
}
dabblet.html
HTML
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44
 
<!-- content to be placed inside <body>…</body> -->
<input type="radio" name="zoom" value="zoomauto" id="zoomauto" checked>
<label for="zoomauto">100%</label>
<input type="radio" name="zoom" value="zoomout75" id="zoomout75">
<label for="zoomout75">75%</label>
<input type="radio" name="zoom" value="zoomout67" id="zoomout67">
<label for="zoomout67">67%</label>
<input type="radio" name="zoom" value="zoomout50" id="zoomout50">
<label for="zoomout50">50%</label>
<div class="fake-slider"></div>
<div class="planetary-system plane">
<div class="star-system plane">
<div class="star-a orbit"><div class="star round"></div></div>
</div>
<div class="planet-a plane">
<div class="trace round"></div>
<div class="orbit">
<div class="planet round">
<div class="moon-a-1 plane">
<div class="trace round"></div>
<div class="orbit"><div class="moon round"></div></div>
</div>
</div>
</div>
</div>
<div class="planet-b plane">
<div class="trace round"></div>
<div class="orbit">
<div class="planet round">
<div class="moon-b-1 plane">
<div class="trace round"></div>
<div class="orbit"><div class="moon round"></div></div>
</div>
<div class="moon-b-2 plane">
<div class="trace round"></div>
<div class="orbit"><div class="moon round"></div></div>
</div>
</div>
</div>
</div>
</div>
settings.json
JSON
1
{"view":"separate","fontsize":"80","seethrough":"","prefixfree":"1","page":"html"}

Please sign in to comment on this gist.

Something went wrong with that request. Please try again.