@-webkit-keyframes animLand {
   0% { background-position: 0px 0px; }
   100% { background-position: -335px 0px; }
}
@-moz-keyframes animLand {
   0% { background-position: 0px 0px; }
   100% { background-position: -335px 0px; }
}
@-o-keyframes animLand {
   0% { background-position: 0px 0px; }
   100% { background-position: -335px 0px; }
}
@keyframes animLand {
   0% { background-position: 0px 0px; }
   100% { background-position: -335px 0px; }
}

@-webkit-keyframes animSky {
   0% { background-position: 0px 100%; }
   100% { background-position: -275px 100%; }
}
@-moz-keyframes animSky {
   0% { background-position: 0px 100%; }
   100% { background-position: -275px 100%; }
}
@-o-keyframes animSky {
   0% { background-position: 0px 100%; }
   100% { background-position: -275px 100%; }
}
@keyframes animSky {
   0% { background-position: 0px 100%; }
   100% { background-position: -275px 100%; }
}

@-webkit-keyframes animBird {
   from { background-position: 0px 0px; }
   to { background-position: 0px -200px; }
}
@-moz-keyframes animBird {
   from { background-position: 0px 0px; }
   to { background-position: 0px -200px; }
}
@-o-keyframes animBird {
   from { background-position: 0px 0px; }
   to { background-position: 0px -200px; }
}
@keyframes animBird {
   from { background-position: 0px 0px; }
   to { background-position: 0px -200px; }
}

@-webkit-keyframes animPipe {
   0% { left: 900px; }
   100% { left: -100px; }
}
@-moz-keyframes animPipe {
   0% { left: 900px; }
   100% { left: -100px; }
}
@-o-keyframes animPipe {
   0% { left: 900px; }
   100% { left: -100px; }
}
@keyframes animPipe {
   0% { left: 900px; }
   100% { left: -100px; }
}

@-webkit-keyframes animCeiling {
   0% { background-position: 0px 0px; }
   100% { background-position: -63px 0px; }
}
@-moz-keyframes animCeiling {
   0% { background-position: 0px 0px; }
   100% { background-position: -63px 0px; }
}
@-o-keyframes animCeiling {
   0% { background-position: 0px 0px; }
   100% { background-position: -63px 0px; }
}
@keyframes animCeiling {
   0% { background-position: 0px 0px; }
   100% { background-position: -63px 0px; }
}


*,
*:before,
*:after
{
   /* border box */
   -moz-box-sizing: border-box;
   -webkit-box-sizing: border-box;
   box-sizing: border-box;
   /* gpu acceleration */
   -webkit-transition: translate3d(0,0,0);
   /* select disable */
   -webkit-touch-callout: none;
   -webkit-user-select: none;
   -khtml-user-select: none;
   -moz-user-select: none;
   -ms-user-select: none;
   user-select: none;
}

html,
body
{
   height: 100%;
   overflow: hidden;
   font-family: monospace;
   font-size: 12px;
   color: #fff;
}

#gamecontainer
{
   position: relative;
   width: 100%;
   height: 100%;
   min-height: 525px;
}

/*
Screen - Game
*/
#gamescreen
{
   position: absolute;
   width: 100%;
   height: 100%;
}

#sky
{
   position: absolute;
   top: 0;
   width: 100%;
   height: 80%;
   background-image: url('../assets/sky.png');
   background-repeat: repeat-x;
   background-position: 0px 100%;
   background-color: #4ec0ca;

   -webkit-animation: animSky 7s linear infinite;
   animation: animSky 7s linear infinite;
}

#flyarea
{
   position: absolute;
   bottom: 0;
   height: 420px;
   width: 100%;
}

#ceiling
{
   position: absolute;
   top: -16px;
   height: 16px;
   width: 100%;
   background-image: url('../assets/ceiling.png');
   background-repeat: repeat-x;

   -webkit-animation: animCeiling 481ms linear infinite;
   animation: animCeiling 481ms linear infinite;
}

#land
{
   position: absolute;
   bottom: 0;
   width: 100%;
   height: 20%;
   background-image: url('../assets/land.png');
   background-repeat: repeat-x;
   background-position: 0px 0px;
   background-color: #ded895;

   -webkit-animation: animLand 2516ms linear infinite;
   animation: animLand 2516ms linear infinite;
}

#bigscore
{
   position: absolute;
   top: 20px;
   left: 150px;
   z-index: 100;
}

#bigscore img
{
   display: inline-block;
   padding: 1px;
}


#scoreboard
{
   position: absolute;
   display: none;
   opacity: 0;
   top: 200px;
   left: 43px;
   width: 236px;
   height: 280px;
   background-image: url('../assets/scoreboard.png');
   background-repeat: no-repeat;
   z-index: 1000;
}

#medal
{
   position: absolute;
   opacity: 0;
   top: 114px;
   left: 32px;
   width: 44px;
   height: 44px;
}

#currentscore
{
   position: absolute;
   top: 105px;
   left: 107px;
   width: 104px;
   height: 14px;
   text-align: right;
}

#currentscore img
{
   padding-left: 2px;
}

#highscore
{
   position: absolute;
   top: 147px;
   left: 107px;
   width: 104px;
   height: 14px;
   text-align: right;
}

#highscore img
{
   padding-left: 2px;
}

#replay
{
   position: absolute;
   opacity: 0;
   top: 205px;
   left: 61px;
   height: 115px;
   width: 70px;
   cursor: pointer;
}

.boundingbox
{
   position: absolute;
   display: none;
   top: 0;
   left: 0;
   width: 0;
   height: 0;
   border: 1px solid red;
}

#player
{
   left: 60px;
   top: 200px;
}

.bird
{
   position: absolute;
   width: 50px;
   height: 50px;
   background-image: url('../assets/bird.png');
   background-size: 50px 200px;
   background-repeat: no-repeat;
   
   /* Éviter blur/antialiasing entre frames */
   image-rendering: -moz-crisp-edges;
   image-rendering: -webkit-crisp-edges;
   image-rendering: pixelated;
   image-rendering: crisp-edges;
   transform: translateZ(0);
   backface-visibility: hidden;

   -webkit-animation: animBird 300ms steps(4) infinite;
   animation: animBird 300ms steps(4) infinite;
}

.pipe
{
   position: absolute;
   left: -100px;
   width: 77px;
   height: 100%;
   z-index: 10;

   -webkit-animation: animPipe 7500ms linear;
   animation: animPipe 7500ms linear;
}

.pipe_upper
{
   position: absolute;
   top: 0;
   width: 77px;
   background-image: url('../assets/pipe.png');
   background-repeat: repeat-y;
   background-position: center;
}

.pipe_upper:after
{
   content: "";
   position: absolute;
   bottom: 0;
   width: 77px;
   height: 38px;
   background-image: url('../assets/pipe-down.png');
   background-size: 77px 38px;
}

.pipe_lower
{
   position: absolute;
   bottom: 0;
   width: 77px;
   background-image: url('../assets/pipe.png');
   background-repeat: repeat-y;
   background-position: center;
}

.pipe_lower:after
{
   content: "";
   position: absolute;
   top: 0;
   width: 77px;
   height: 38px;
   background-image: url('../assets/pipe-up.png');
   background-size: 77px 38px;
}

#footer
{
   position: absolute;
   bottom: 3px;
   left: 3px;
   color: #000;
}

#footer a,
#footer a:link,
#footer a:visited,
#footer a:hover,
#footer a:active
{
   padding: 2px;
   text-decoration: none;
   color: #000;
}

#footer div
{
   padding: 2px;
}

/* Splash logo - CENTRÉ avec le splash, AU-DESSUS */
#splashlogo
{
   position: absolute;
   top: -50px;
   left: 59px;
   width: 200px;
   height: auto;
   z-index: 6;
   display: none;
}

/* Splash - position de base */
#splash
{
   position: absolute;
   top: 75px;
   left: 65px;
   width: 188px;
   height: 170px;
   background-image: url('../assets/splash.png');
   background-repeat: no-repeat;
   opacity: 0;
   z-index: 5;
}

/* Game Over Video - CENTRÉE avec le scoreboard, AU-DESSUS */
#gameovervideo
{
   position: absolute;
   display: none;
   top: -60px;
   left: -39px;
   width: 400px;
   height: 250px;
   z-index: 1001;
}

#gameovervideo video
{
   width: 100%;
   height: 100%;
   border: none;
}

/* Responsive mobile */
@media (max-width: 600px) {
   #gameovervideo {
      width: 320px;
      height: 200px;
      top: -136px;
   }
}

/* Easter Egg Overlay */
#easteregg-overlay
{
   position: fixed;
   top: 0;
   left: 0;
   width: 100%;
   height: 100%;
   background-color: rgba(0, 0, 0, 0.95);
   z-index: 9999;
   display: none;
   overflow-y: auto;
   cursor: pointer;
}

#easteregg-content
{
   max-width: 800px;
   margin: 20px auto;
   padding: 30px;
   color: #fff;
   font-family: 'Courier New', monospace;
   font-size: 14px;
   line-height: 1.6;
}

.easteregg-title
{
   text-align: center;
   font-size: 28px;
   color: #ff4444;
   margin-bottom: 10px;
   text-shadow: 2px 2px 4px #000;
}

.easteregg-subtitle
{
   text-align: center;
   font-size: 16px;
   color: #ffcc00;
   margin-bottom: 30px;
}

.easteregg-event
{
   margin-bottom: 20px;
   padding: 15px;
   background-color: rgba(255, 255, 255, 0.05);
   border-left: 3px solid #ff4444;
   border-radius: 0 8px 8px 0;
}

.easteregg-event img
{
   vertical-align: middle;
   margin-right: 5px;
}

.easteregg-event strong
{
   color: #ffcc00;
   font-size: 15px;
}

.easteregg-details
{
   margin-top: 10px;
   padding-left: 30px;
   color: #ccc;
   font-size: 13px;
   line-height: 1.8;
}

.easteregg-stats
{
   text-align: center;
   margin-top: 30px;
   padding: 20px;
   background-color: rgba(255, 0, 0, 0.2);
   border-radius: 8px;
   font-size: 16px;
   color: #ff6666;
}

#easteregg-hint
{
   text-align: center;
   margin-top: 40px;
   padding: 15px;
   background-color: rgba(255, 255, 255, 0.1);
   border-radius: 8px;
   font-size: 16px;
   color: #aaa;
}

@media (max-width: 600px) {
   #easteregg-content {
      padding: 15px;
      font-size: 12px;
   }
   
   .easteregg-title {
      font-size: 20px;
   }
   
   .easteregg-event strong {
      font-size: 13px;
   }
   
   .easteregg-details {
      font-size: 11px;
      padding-left: 15px;
   }
}
