HTML preprocessors can make writing HTML more powerful or convenient. For instance, Markdown is designed to be easier to write and read for text documents and you could write a loop in Pug.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. So you don't have access to higher-up elements like the <html>
tag. If you want to add classes there that can affect the whole document, this is the place to do it.
In CodePen, whatever you write in the HTML editor is what goes within the <body>
tags in a basic HTML5 template. If you need things in the <head>
of the document, put that code here.
The resource you are linking to is using the 'http' protocol, which may not work when the browser is using https.
CSS preprocessors help make authoring CSS easier. All of them offer things like variables and mixins to provide convenient abstractions.
It's a common practice to apply CSS to a page that styles elements such that they are consistent across all browsers. We offer two of the most popular choices: normalize.css and a reset. Or, choose Neither and nothing will be applied.
To get the best cross-browser support, it is a common practice to apply vendor prefixes to CSS properties and values that require them to work. For instance -webkit-
or -moz-
.
We offer two popular choices: Autoprefixer (which processes your CSS server-side) and -prefix-free (which applies prefixes via a script, client-side).
Any URL's added here will be added as <link>
s in order, and before the CSS in the editor. If you link to another Pen, it will include the CSS from that Pen. If the preprocessor matches, it will attempt to combine them before processing.
You can apply CSS to your Pen from any stylesheet on the web. Just put a URL to it here and we'll apply it, in the order you have them, before the CSS in the Pen itself.
If the stylesheet you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the CSS from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
JavaScript preprocessors can help make authoring JavaScript easier and more convenient.
Babel includes JSX processing.
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.
You can apply a script from anywhere on the web to your Pen. Just put a URL to it here and we'll add it, in the order you have them, before the JavaScript in the Pen itself.
If the script you link to has the file extension of a preprocessor, we'll attempt to process it before applying.
You can also link to another Pen here, and we'll pull the JavaScript from that Pen and include it. If it's using a matching preprocessor, we'll combine the code before preprocessing, so you can use the linked Pen as a true dependency.
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.
Using packages here is powered by Skypack, which makes packages from npm not only available on a CDN, but prepares them for native JavaScript ES6 import
usage.
All packages are different, so refer to their docs for how they work.
If you're using React / ReactDOM, make sure to turn on Babel for the JSX processing.
If active, Pens will autosave every 30 seconds after being saved once.
If enabled, the preview panel updates automatically as you code. If disabled, use the "Run" button to update.
If enabled, your code will be formatted when you actively save your Pen. Note: your code becomes un-folded during formatting.
Visit your global Editor Settings.
<div id="container">
<div id="text-container">
<h1>Happy Thanksgiving</h1>
<h2><span>20</span><span>20</span></h2>
</div>
<div id="sun-container">
<svg viewBox="0 0 150 145" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="inner-sun" fill-rule="evenodd">
<circle id="sun" cx="61" cy="82" r="61"></circle>
<circle class="dot" cx="10" cy="19" r="3"></circle>
<circle class="dot" cx="148.5" cy="1.5" r="1.5"></circle>
<circle class="dot" cx="95" cy="144" r="1"></circle>
</g>
</svg>
</div>
<div id="rays-container" data-depth='0.5'>
<svg viewBox="0 0 404 229" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="rays" fill-rule="evenodd">
<line x1="31" y1="226" x2="3" y2="217" class="ray"></line>
<line x1="54" y1="184" x2="17" y2="147" class="ray"></line>
<line x1="114" y1="155" x2="59" y2="60" class="ray"></line>
<line x1="173" y1="137" x2="145" y2="3" class="ray"></line>
<line x1="231" y1="137" x2="259" y2="3" class="ray"></line>
<line x1="290" y1="155" x2="345" y2="60" class="ray"></line>
<line x1="350" y1="184" x2="387" y2="147" class="ray"></line>
<line x1="373" y1="226" x2="401" y2="217" class="ray"></line>
</g>
</svg>
</div>
<div id="turkey-container" data-depth='0.5'>
<svg viewBox="0 0 172 186" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="turkey" fill-rule="evenodd">
<path d="M167.206001,70.3765841 C167.206001,40.3765841 132.206001,44.3765841 132.206001,64.3765841 C132.206001,84.3765841 157.206001,84.3765841 157.206001,116.376584 C157.206001,148.376584 124.206001,153.376584 115.206001,148.376584" id="neck"></path>
<path d="M118.206001,133.376584 C118.206001,153.376584 95.2060007,173.376584 51.2060007,166.376584 C77.2060007,150.376584 77.2060007,143.376584 80.2060007,130.376584" id="wing"></path>
<line x1="108.206001" y1="155.376584" x2="108.206001" y2="181.376584" id="leg1"></line>
<line x1="88.2060007" y1="165.376584" x2="88.2060007" y2="181.376584" id="leg2"></line>
<path d="M75.2060007,145.376584 C58.2060007,159.376584 29.2060007,142.376584 29.2060007,103.376584 C29.2060007,64.3765841 59.2060007,46.3765841 63.2060007,44.3765841 C75.2060007,48.3765841 81.2060007,63.3765841 81.2060007,71.3765841" id="tail"></path>
<path d="M57.2060007,87.3765841 C68.539334,74.7099174 82.539334,69.3765841 99.2060007,71.3765841 C115.872667,73.3765841 127.872667,82.3765841 135.206001,98.3765841" id="back"></path>
<path d="M111.348958,72.982222 C119.139287,43.9083194 101.885541,14.0239553 72.8116387,6.23362654 C43.737736,-1.55670219 13.8533719,15.6970435 6.06304317,44.7709461 C-0.148643244,67.9532754 9.56221456,91.6508807 28.491812,104.252432" id="feather"></path>
</g>
</svg>
</div>
<div id="leaf-container">
<svg viewBox="0 0 141 73" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink">
<g id="leaf" fill-rule="evenodd">
<path d="M137,10 C114.866666,29.3333333 92.533333,39 70,39 C47.466667,39 24.8000003,29.3333333 2,10" id="stem"></path>
<path d="M114,27 C99.3333333,35 95,46.3333333 101,61 C117,56.3333333 121.333333,45 114,27 Z"></path>
<path d="M113.612903,27 C98.9462366,35 94.6129032,46.3333333 100.612903,61 C116.612903,56.3333333 120.946237,45 113.612903,27 Z"></path>
<path d="M114,27 C107.333333,12.3333333 97,8.33333333 83,15 C87,28.3333333 97.3333333,32.3333333 114,27 Z"></path>
<path d="M76.2997601,38.1183854 C59.4332534,40.0394618 51.6666667,48.6666667 53,64 C68.3333333,65.3333333 76.09992,56.7061285 76.2997601,38.1183854 Z"></path>
<path d="M76.65867,38.2633944 C75.0253544,21.6368075 66.2861342,13.219667 50.4410096,13.0119729 C48.4850009,29.5634625 57.224221,37.980603 76.65867,38.2633944 Z"></path>
<path d="M39.3648737,32.3926122 C20.4549579,30.1308707 9.55644378,35.4642198 6.66933133,48.3926594 C21.5536496,55.8916492 32.4521637,50.5583001 39.3648737,32.3926122 Z"></path>
<path d="M39.6479783,32.6566116 C45.2159928,16.8855372 40.3333333,6.66666667 25,2 C19,16.6666667 23.8826594,26.8855372 39.6479783,32.6566116 Z"></path>
</g>
<circle class="dot" cx="9.5" cy="2.5" r="2.5"></circle>
<circle class="dot" cx="118.5" cy="6.5" r="1.5"></circle>
<circle class="dot" cx="86.5" cy="70.5" r="2.5"></circle>
</svg>
<span></span>
</div>
</div>
<button class="meta" id="color-toggle"></button>
<p class="meta">Artwork by <a href="https://dribbble.com/stephendoulas" target="_blank">Stephen Doulas</a> // Animation by <a href="https://codepen.io/jackiezen" target="_blank">Jackie Zen</a></p>
<button class="meta" id="replay">Replay ↻</button>
@import url("https://fonts.googleapis.com/css2?family=Roboto+Condensed:wght@700&display=swap");
*,
*:before,
*:after {
box-sizing: border-box;
margin: 0;
padding: 0;
}
*:before,
*:after {
position: absolute;
content: "";
}
:root {
--container-width: 50vw;
--color-black: #323232;
--color-orange: #fe911b;
--color-cream: #fef3e9;
--max-width: 50vh;
--text-timing: 0.25s;
--text-unit: 10;
--spacing-unit: 0.68;
--degree-unit: calc(var(--spacing-unit) * 2);
--margin: 5vh;
}
html {
--background-color: var(--color-cream);
--stroke-color: var(--color-black);
}
html.dark-mode {
--background-color: var(--color-black);
--stroke-color: var(--color-cream);
}
body {
width: 100%;
height: 100vh;
overflow: hidden;
font-family: "Roboto Condensed", sans-serif;
display: flex;
flex-direction: column;
justify-content: center;
align-items: center;
background: var(--background-color);
}
/* body:before {
width: 100%;
height: 100%;
background-image: url(http://api.thumbr.it/whitenoise-500x500.png?background=FEF3E900&noise=626262&density=1&opacity=30);
z-index: 100;
}
*/
#container {
width: var(--container-width);
height: calc(var(--container-width) * 1.4);
margin: 0 auto;
display: flex;
justify-content: center;
align-items: center;
position: relative;
max-width: var(--max-width);
max-height: calc(var(--max-width) * 1.4);
margin-top: -6%;
}
#container > div {
position: absolute;
}
#turkey-container {
position: absolute;
width: 43%;
height: auto;
margin-bottom: 35%;
bottom: 0;
margin-right: -6%;
}
#sun-container {
position: relative;
width: 38%;
height: auto;
margin-bottom: 35%;
bottom: 0;
opacity: 0;
}
.sun-animation {
animation: fade, shift;
animation-duration: calc(var(--text-timing) * 4);
animation-fill-mode: forwards;
animation-delay: calc(var(--text-timing) * 3);
}
@keyframes shift {
0% {
margin-left: 0;
}
100% {
margin-left: -12%;
}
}
#rays-container {
position: absolute;
width: 100%;
height: auto;
top: 0;
opacity: 0;
}
.ray-animation {
animation: fade calc(var(--text-timing) * 3) forwards 1s;
}
#rays > * {
stroke-width: 6px;
stroke: var(--color-orange);
}
#turkey-container svg,
#leaf-container svg,
#sun-container svg,
#rays-container svg {
width: auto;
height: 100%;
display: block;
stroke-linecap: round;
stroke-linejoin: round;
overflow: visible;
}
#turkey > *,
#leaf > *:not(.dot) {
fill: none;
stroke: var(--stroke-color);
}
#leaf-container svg .dot {
fill: var(--stroke-color);
}
.stroke-animation {
animation: svgFill 1.25s ease-out forwards;
}
.ray-stroke-animation {
animation: svgFill ease-out infinite alternate 1s;
}
#rays .ray:nth-of-type(odd) {
animation-delay: 1.25s;
}
#rays .ray:first-of-type {
animation-duration: 1.8s;
}
#rays .ray:nth-of-type(2) {
animation-duration: 2s;
}
#rays .ray:nth-of-type(3) {
animation-duration: 1.7s;
}
#rays .ray:nth-of-type(4) {
animation-duration: 2.15s;
}
#rays .ray:nth-of-type(5) {
animation-duration: 1.85s;
}
#rays .ray:nth-of-type(6) {
animation-duration: 2.2s;
}
#rays .ray:nth-of-type(7) {
animation-duration: 2.2s;
}
#rays .ray:nth-of-type(8) {
animation-duration: 2.15s;
}
#turkey > * {
stroke-width: 6px;
}
#leaf > *:not(.dot) {
stroke-width: 5px;
}
#leaf > * {
stroke-width: none;
fill: var(--stroke-color);
}
#inner-sun > * {
stroke-width: none;
fill: var(--color-orange);
}
@keyframes svgFill {
100% {
stroke-dashoffset: 0;
}
}
#leaf > *:not(.dot) {
animation-delay: 1s;
}
#leaf > .dot {
opacity: 0;
}
.leaf-dot-aniamtion {
animation: fade calc(var(--text-timing) * 1) forwards 1.5s;
}
#leaf > .dot:first-of-type {
animation-delay: 1.75s;
}
#leaf > .dot:last-of-type {
animation-delay: 2s;
}
#leaf-container {
width: 35%;
height: auto;
bottom: 0;
margin-right: -3%;
margin-bottom: 5%;
position: relative;
opacity: 0;
overflow: visible;
}
.leaf-animation {
animation: fade calc(var(--text-timing) * 1) forwards 1s;
}
#leaf-container span {
position: absolute;
width: 70%;
height: 10%;
bottom: 0;
background: var(--stroke-color);
margin-bottom: -24%;
border-radius: 50%;
left: 50%;
transform: translateX(-50%);
opacity: 0;
}
.leaf-shadow-animation {
animation: fade calc(var(--text-timing) * 2) forwards 1.75s;
}
#text-container {
width: 86%;
padding-bottom: 86%;
bottom: 0;
margin-bottom: 16%;
position: relative;
}
#text-container:before {
width: 100%;
height: 50%;
bottom: 0;
}
#text-container:after {
width: 100%;
height: 100%;
border-radius: 50%;
}
#text-container h2 {
position: absolute;
width: 100%;
display: flex;
justify-content: space-between;
bottom: 0;
font-size: min(max(3.5vw), 3.5vh);
color: var(--color-orange);
opacity: 0;
}
.h2-animation {
animation: fade calc(var(--text-timing) * 1) forwards 1s;
}
#text-container h2 span {
position: relative;
padding-bottom: 2%;
}
#text-container h2 span:before {
width: 100%;
height: 10%;
background: var(--color-orange);
bottom: 0;
border-radius: 25% / 250%;
}
#text-container h2 span:first-letter {
letter-spacing: min(max(1vw), 2vh);
}
#text-container h1 {
position: absolute;
font-size: 250%;
color: var(--stroke-color);
text-transform: uppercase;
height: 50%;
width: 100%;
display: flex;
justify-content: center;
font-size: min(max(4.5vw), 4.5vh);
}
#text-container h1 span {
position: absolute;
height: 100%;
transform-origin: bottom center;
line-height: 1;
width: 6%;
display: flex;
justify-content: center;
align-items: flex-start;
opacity: 0;
}
.h1-animation {
animation: fade calc(var(--text-timing) * 1) forwards;
}
@keyframes fade {
0% {
opacity: 0;
}
100% {
opacity: 1;
}
}
#text-container h1 span:first-of-type {
animation-delay: calc(var(--text-timing) * 0.25);
}
#text-container h1 span:nth-of-type(2) {
animation-delay: calc(var(--text-timing) * 0.5);
}
#text-container h1 span:nth-of-type(3) {
animation-delay: calc(var(--text-timing) * 0.75);
}
#text-container h1 span:nth-of-type(4) {
animation-delay: calc(var(--text-timing) * 1);
}
#text-container h1 span:nth-of-type(5) {
animation-delay: calc(var(--text-timing) * 1.75);
}
#text-container h1 span:nth-of-type(6) {
animation-delay: calc(var(--text-timing) * 2);
}
#text-container h1 span:nth-of-type(7) {
animation-delay: calc(var(--text-timing) * 2.25);
}
#text-container h1 span:nth-of-type(8) {
animation-delay: calc(var(--text-timing) * 2.5);
}
#text-container h1 span:nth-of-type(9) {
animation-delay: calc(var(--text-timing) * 2.75);
}
#text-container h1 span:nth-of-type(10) {
animation-delay: calc(var(--text-timing) * 3);
}
#text-container h1 span:nth-of-type(11) {
animation-delay: calc(var(--text-timing) * 3.25);
}
#text-container h1 span:nth-of-type(12) {
animation-delay: calc(var(--text-timing) * 3.5);
}
#text-container h1 span:nth-of-type(13) {
animation-delay: calc(var(--text-timing) * 3.75);
}
#text-container h1 span:nth-of-type(14) {
animation-delay: calc(var(--text-timing) * 4);
}
#text-container h1 span:nth-of-type(15) {
animation-delay: calc(var(--text-timing) * 4.25);
}
#text-container h1 span:nth-of-type(16) {
animation-delay: calc(var(--text-timing) * 4.5);
}
#text-container h1 span:nth-of-type(17) {
animation-delay: calc(var(--text-timing) * 4.75);
}
#text-container h1 span:nth-of-type(18) {
animation-delay: calc(var(--text-timing) * 5);
}
#text-container h1 span:first-of-type,
#text-container h1 span:nth-of-type(2),
#text-container h1 span:nth-of-type(3) {
transform: rotate(-90deg);
}
#text-container h1 span:last-of-type,
#text-container h1 span:nth-of-type(17),
#text-container h1 span:nth-of-type(16) {
transform: rotate(90deg);
}
#text-container h1 span:first-of-type,
#text-container h1 span:last-of-type {
margin-top: calc(calc(var(--text-unit) * 1%) * 2);
}
#text-container h1 span:nth-of-type(2),
#text-container h1 span:nth-of-type(17) {
margin-top: calc(calc(var(--text-unit) * 1%) * 1);
}
#text-container h1 span:nth-of-type(3) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -6))
)
);
}
#text-container h1 span:nth-of-type(16) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 6))
)
);
}
#text-container h1 span:nth-of-type(4) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -5))
)
);
}
#text-container h1 span:nth-of-type(15) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 5))
)
);
}
#text-container h1 span:nth-of-type(5) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -4))
)
);
}
#text-container h1 span:nth-of-type(14) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 4))
)
);
}
#text-container h1 span:nth-of-type(6) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -3))
)
);
}
#text-container h1 span:nth-of-type(13) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 3))
)
);
}
#text-container h1 span:nth-of-type(7) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -2))
)
);
}
#text-container h1 span:nth-of-type(12) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 2))
)
);
}
#text-container h1 span:nth-of-type(8) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * -1))
)
);
}
#text-container h1 span:nth-of-type(11) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 1))
)
);
}
#text-container h1 span:nth-of-type(9) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(calc(var(--spacing-unit) * -1) + calc(var(--degree-unit) * 0))
)
);
}
#text-container h1 span:nth-of-type(10) {
transform: rotate(
calc(
calc(var(--text-unit) * 1deg) *
calc(var(--spacing-unit) + calc(var(--degree-unit) * 0))
)
);
}
.meta {
position: absolute;
opacity: 0.7;
z-index: 101;
}
button {
font-size: 0.8rem;
cursor: pointer;
background: transparent;
color: var(--stroke-color);
transition: all 0.3s;
border: 3px solid var(--stroke-color);
line-height: 1.5;
border-radius: 30px;
height: 30px;
padding: 0 14px;
text-transform: uppercase;
font-weight: 700;
letter-spacing: 0.05rem;
}
button:hover {
transform: scale(1.05);
}
#replay {
bottom: var(--margin);
right: var(--margin);
}
#color-toggle {
border-radius: 50%;
width: 30px;
overflow: hidden;
padding: 0;
bottom: var(--margin);
left: var(--margin);
}
#color-toggle:after {
width: 50%;
height: 100%;
background: var(--stroke-color);
top: 0;
right: 0;
}
button:focus {
outline: 0;
}
p {
padding: 0;
margin: 0;
line-height: 1.8;
font-size: 0.8rem;
text-transform: uppercase;
font-weight: 700;
letter-spacing: 0.1rem;
color: var(--stroke-color);
bottom: 0;
margin: var(--margin);
text-align: center;
}
p a:link,
p a:visited {
color: var(--color-orange);
text-decoration: none;
border-bottom: 2px solid var(--color-orange);
}
@media only screen and (max-width: 768px) {
#color-toggle {
top: var(--margin);
}
#replay {
top: var(--margin);
}
button {
font-size: 0.7rem;
cursor: pointer;
background: transparent;
color: var(--stroke-color);
transition: all 0.3s;
border: 3px solid var(--stroke-color);
line-height: 1.5;
border-radius: 26px;
height: 26px;
padding: 0 14px;
}
p {
font-size: 0.7rem;
}
p a:link {
border-bottom: 1px solid var(--color-orange);
}
#color-toggle {
width: 26px;
}
}
$(document).ready(function () {
console.log("ready!");
$("h1").lettering();
setup();
$("#replay").click(function () {
refresh();
setup();
});
$("#color-toggle").click(function () {
$("html").toggleClass("dark-mode");
});
$("#turkey > *, #leaf > *:not(.dot), #rays > *").each(function () {
var length_stroke = $(this).get(0).getTotalLength();
$(this).css({
"stroke-dasharray": length_stroke + " " + length_stroke,
"stroke-dashoffset": length_stroke
});
});
$.fn.parallax = function (resistance, mouse) {
$el = $(this);
TweenLite.to($el, 0.2, {
x: -((mouse.clientX - window.innerWidth / 2) / resistance),
y: -((mouse.clientY - window.innerHeight / 2) / resistance)
});
};
});
function refresh() {
$("#sun-container").removeClass("sun-animation");
$("#rays-container").removeClass("ray-animation");
$("#leaf-container").removeClass("leaf-animation");
$("#turkey > *, #leaf > *:not(.dot)").removeClass("stroke-animation");
$("#rays > *").removeClass("ray-stroke-animation");
$("#leaf > .dot").removeClass("leaf-dot-animation");
$("#leaf-container span").removeClass("leaf-shadow-animation");
$("#text-container h2").removeClass("h2-animation");
$("#text-container h1 span").removeClass("h1-animation");
}
function animations() {
$("#sun-container").addClass("sun-animation");
$("#rays-container").addClass("ray-animation");
$("#leaf-container").addClass("leaf-animation");
$("#turkey > *, #leaf > *:not(.dot)").addClass("stroke-animation");
$("#rays > *").addClass("ray-stroke-animation");
$("#leaf > .dot").addClass("leaf-dot-animation");
$("#leaf-container span").addClass("leaf-shadow-animation");
$("#text-container h2").addClass("h2-animation");
$("#text-container h1 span").addClass("h1-animation");
}
function setup() {
$("#container").hide(0).fadeIn(800);
animations();
setTimeout(function () {
$(document).mousemove(function (e) {
$("#sun-container #sun").parallax(150, e);
$("h1, h2, #rays-container").parallax(350, e);
$("#turkey-container").parallax(60, e);
$("#leaf-container #leaf").parallax(200, e);
});
}, 2250);
$("button#replay").hide().delay(2500).fadeIn(800);
}
Also see: Tab Triggers