@font-face {
  font-family: "Retro Gaming";
  src: url("./fonts/retro_gaming.woff2") format("woff2"),
       url("./fonts/retro_gaming.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Martyric";
  src: url("./fonts/martyric.woff2") format("woff2"),
       url("./fonts/martyric.ttf") format("truetype");
  font-display: swap;
}


* {
  cursor: url("./cursors/arrow.cur"), auto;
}
html {
  height: 100%;
}
body {
  margin: 0;
  /*overflow: hidden;*/
  background: black;
  font-family: "Retro Gaming", sans-serif; 
  cursor: url("./cursors/arrow.cur"), auto;
  width: 100%;
  min-height: 100%;
  overflow-y: auto;
  overflow-x: hidden;
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}
.title {
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
}
h1 {
  font-family: "martyric", sans-serif; 
}
p {
  font-family: "Retro Gaming", sans-serif; 
}
.btn:hover {
  cursor: url("./cursors/hand.cur"), auto;
}
a:hover {
  cursor: url("./cursors/hand.cur"), auto;
}
button:hover .button-icon:hover {
  cursor: url("./cursors/hand.cur"), auto;
}
.restart-btn:hover {
  cursor: url("./cursors/hand.cur"), auto;
}
.hidden {
  display: none;
}
/* LOADING screen */
#loading-screen {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: black;
  color: white;
  font-size: 2rem;
  font-family: "Retro Gaming", sans-serif;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
}

/* 🌀 Fade-Out Effect */
.fade-out {
  animation: fadeOut 2s forwards;
}

@keyframes fadeOut {
  from { opacity: 1; }
  to { opacity: 0; visibility: hidden; }
}


/* title */
.title h1 {
  font-family: "martyric", sans-serif;
  font-size: 6rem;
  width: 100%;
  font-weight: bold;
  text-transform: uppercase;
  text-align: center;
  background: -webkit-linear-gradient(rgb(255, 18, 18) 30%, rgb(255, 215, 38));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  transform: skew(-10deg) rotate(-10deg) translateX(-2rem);
  transition: font-size 0.5s ease-in-out; /* animate changes in font-size */

}
h1>span {
 font-size: 10rem;
 transition: font-size 0.5s ease-in-out;

}
.title-top {
  margin-top: 0em;
  margin-bottom: -8rem;
  transition: margin-bottom 0.5s ease-in; /* animate changes in margin-bottom */

}
.title-bottom {
  margin-top: 0rem;
}
.shrink-titles .title h1 {
  font-size: 2rem;
}
.shrink-titles .title-top {
  margin-bottom: -4rem;
}
.shrink-titles h1 > span {
  font-size: 4rem;
}
/* Conteneur wrapper couvrant toute la hauteur de la fenêtre */
.wrapper {
  position: relative;
  width: 100%;
  height: 100vh;
  overflow: hidden;
}
.content {
  position: absolute;
  display: flex;
  justify-content: center;
  align-items: center;
  flex-direction: column;
  width: 100%;
}
/* background */
.television-screen {
  background: #1a1c2b; /* Dark blue base */
  width: 100vw;
  min-height: 100vh;
    position: relative;
  top: 0;
  left: 0;
  overflow-y: hidden; /* Ajoute une barre de défilement verticale si besoin */
  overflow-x: hidden;

}
.noise {
  width: 100%;
  height: 300%; /* Augmentez la hauteur pour éviter les coupures */
  background:
  linear-gradient(to bottom, transparent, #aaa4, #8881, #6664, #4445, #2228, #4443, transparent),
  repeating-linear-gradient(transparent 0 20px, #25242950 2px 4px);
  animation: moveNoise 12s linear infinite; /* Longer duration for smooth effect */
  position: absolute;
  top: 0;
  left: 0;
  z-index: 1;
  pointer-events: none;
}
.television-screen::after {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-image: url('./images/crt.png');
  background-repeat: no-repeat;
  background-size: 100% 100%;
  content: "";
  pointer-events: none;
}
/* language */
.language-selector {
  position: absolute;
  top: 10px;
  z-index: 9;
  right: 20px;
  display: flex;
  gap: 10px;
  padding: 25px;
  border: #ddd 1px solid;
  top: 0;
  border-width: 0px 0px 4px 4px;
  right: 0;
  border-radius: 0px 0px 0px 30px;
  background-color: #8BC6EC;
  background-color: #21D4FD;
  background-image: linear-gradient(19deg, #21D4FD 0%, #B721FF 100%);
}

.lang-button {
  background: none;
  border: none;
  cursor: pointer;
  padding: 5px;
}

.lang-button img {
  width: 75px;
  height: auto;
  transition: transform 0.2s ease-in-out;
}

.lang-button:hover img {
  transform: scale(1.1);
}

#nespad{
  margin-bottom: 0;
}
/* Back Button styling */
.start-buttons {
  background: #ddd;
  height: 30px;
  border: 3px solid #ddd;
  box-shadow: inset 3px 3px 3px rgba(0, 0, 0, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-around;
  width: 100px;
  position: absolute;
  border-radius: 10px;
  right: 0;
  right: 40px;
  margin-top: -15px;
  color: white;
  text-shadow: 1px 1px 0 #000, -1px -1px 0 #000, 1px -1px 0 #000, -1px 1px 0 #000, 1px 1px 0 #000;
}

.start-buttons > .btn {
  z-index: 9;
  background: #444;
  width: 70px;
  height: 20px;
  border-radius: 10px;
  border: 2px solid rgba(0, 0, 0, 0.3);
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.3),
     0 4px 12px rgba(0, 0, 0, 0.6);
}

.start-buttons > .btn:hover {
  position: relative;
  box-shadow: inset 0 1px 2px rgba(255, 255, 255, 0.15),
     0 1px 3px rgba(0, 0, 0, 0.6);
  transform: scale(0.98);
  background: #363636;
}

/* launch menu */
.launchmenu {
  top: 0;
  left: 0;
  font-size: 3rem;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 2;
}
.buttons {
  display: flex;
  flex-direction: column;
  justify-content: center;
  margin: auto;
  margin-top: 1em;
}
#mailto-icon {
}
.grey-with-red {
  color: rgb(192, 192, 192);
  text-shadow: 2px 2px 0 rgb(192, 11, 11);
}
.buttons a.active {
  color: rgb(147, 154, 255); /* Couleur sélectionnée */
  text-shadow: 2px 2px 0 rgb(47, 61, 255);
}
.buttons a {
  display: block;
  margin-bottom: 1rem;
  color: rgb(192, 192, 192); /* Couleur par défaut */
  text-align: center;
  text-shadow: 2px 2px 0 rgb(192, 11, 11);
}
.buttons a:hover {
  color: rgb(147, 154, 255); /* Couleur lorsque l'utilisateur survole */
  text-shadow: 2px 2px 0 rgb(47, 61, 255);
}

/* introText */
.intro {
  position: relative;
}

.intro-box {
  max-width: 800px;
  padding: 20px;
  background: linear-gradient(to bottom, #222, #111); /* Retro-style box */
  background-image: url("./images/introbg-min.jpg");
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  border: 4px solid #888; /* Border for the retro box */
  text-align: center;
  position: relative;
  overflow: hidden;
  margin: auto;
  min-height: 300px;
}
.innerBox {
  z-index: 1;
  position: relative;
}
.intro-text {
  font-size: 1.4rem;
  color: white;
  line-height: 1.5;
  margin: 0 100px;
  white-space: normal;
  overflow: hidden;
  display: inline-block;
  text-shadow:
    1px 1px 2px black,
    0 0 1em black,
    0 0 0.2em black;
}

/* Intro Images */
.bottom-right-image {
  position: absolute;
  position: absolute;
  bottom: 0;
  right: 0px;
  width: 200px;
  height: auto;
}
.top-left-image {
  position: absolute;
  bottom: -20px;
  left: -50px;
  width: 200px;
  height: auto;
}

/* bottom text */
.bottom-text {
  font-size: 1.5em;
  text-align: center;
  position: absolute;
  bottom: 25px;
  width: 100%;
}
.yellow-with-darkyellow {
  color: rgb(226, 179, 24);
  text-shadow: 0 2px 0 rgb(107, 77, 11), 2px 0 0 rgb(151, 109, 19),
    2px 2px 0 rgb(151, 109, 19);
}
.yellow {
  color: rgb(226, 179, 24);
}
/* game */
/* Obstacles */
.obstacle {
  position: absolute;
  right: -50px; /* Start off-screen */
  width: 50px; /* Adjust size for images */
  height: 50px;
  background-size: contain; /* Ensure the image fits inside */
  background-repeat: no-repeat;
  animation: moveObstacle 4s linear forwards;
  filter: invert(50%) sepia(100%) saturate(500%) hue-rotate(90deg);
  z-index: 2;
}

@keyframes moveObstacle {
  from {
    right: -50px;
  }
  to {
    right: 200%; /* Move off-screen */
  }
}
.scorepanel 
{
  z-index: 7 !important;
  position: relative;
  text-shadow:
  1px 1px 2px black,
  0 0 1em black,
  0 0 0.2em black;
  color: rgb(226, 179, 24);
  width: 10%;
  margin: auto;
  top: -20px;
  background: #80808082;
  border-radius: 0px 0 10px 11px;
  padding: 3px;
  box-shadow: 0 5px 5px 0 rgba(0, 0, 0, 0.55);
}
#score {
 /* position: absolute;
  top: 10px;
  left: 10px;
  font-size: 20px;
  font-family: Arial, sans-serif;*/
}
#mailto-icon {
  width: 95%;
  margin-left: 5%;
}

/* gamepad */
/* right hand */
/*.rightHand{
  position: absolute;
  z-index: 9;
  right: 0;
  padding: 25px;
  background-color: #2a2a2a;
  border-radius: 15px 0 0 15px;
  border: 8px solid #ddd;
  border-right: none;
  box-shadow: inset 0 0 3px #ddd;
  width: 200px;
  display: flex;
  height: 300px;
  justify-content: center;
  align-items: center;
} */
.action-pane .label {
  display: block;
  background-color: #ddd;
  border-radius: 0.4rem;
  width: 4rem;
  height: 4rem;
  right: 0;
  margin-left: 2.5em;
  margin-bottom: 3rem;
  line-height: 9.5em;
  position: relative;
  font-size: 1rem; 
  color:#c3442d;
}
.action-pane .caption {
  transform: scaleX(1.6);
}
.action-pane .button {
  position: absolute;
  top: .02rem;
  left: .22rem;
  width: 3.2rem;
  height: 3.2rem;
  background: #E0421B; /* fallack */
  background: -webkit-radial-gradient(35% 35%, circle closest-corner, #ff8957, #E0421B 100%);
  background: -moz-radial-gradient(35% 35%, circle closest-corner, #ff8957, #E0421B 100%);
  background: radial-gradient(35% 35%, circle closest-corner, #ff8957, #E0421B 100%);
  border-radius: 2em;
  border: .08em solid hsla(10, 90%, 55%, 1);
  box-shadow:
    2em 1em 0.2em 0 hsla(10, 90%, 45%, .5) inset, /* reflection */
    .04em .1em 0 hsla(10, 90%, 30%, 1), /* 3d */
    .08em .2em 0 hsla(10, 90%, 26%, 1),
    .12em .3em 0 hsla(10, 90%, 23%, 1),
    .1em .24em 0 .15em hsla(0, 0%, 15%, 1), /* hole */
    .1em .075em .5em rgba(0, 0, 0, .3), /* shadow */
    .3em .15em .5em rgba(0, 0, 0, .3),
    .6em .3em .5em rgba(0, 0, 0, .3),
    1.2em .6em .5em rgba(0, 0, 0, .3);
}

.action-pane .button:active {
  top: .40rem;
  left: .35rem;
  box-shadow:
    2em 1em 0.2em 0 hsla(10, 90%, 45%, .5) inset, /* reflection */
    .05em .1em 0 hsla(10,90%,30%,1), /* 3d */
    0 0 0 .15em hsla(0, 0%, 15%, 1), /* hole */
    .1em .075em .5em rgba(0,0,0,.3); /* shadow */
}

.button-icon {
  width: 40px;
  margin-top: 5px;
}

/* left hand */
.leftHand {
  position: absolute;
  z-index: 9;
  left: 0px;
  padding: 25px;
  /* padding-left: 75px; */
  padding-bottom: 15px;
  background-color: #2a2a2a;
  border-radius: 0 15px 15px 0;
  border: 8px solid #ddd;
  border-left: none;
  box-shadow: inset 0 0 3px #ddd;
  width: 200px;
  height: 300px;
}
.dpad-pane {
  display: inline-block;
  vertical-align: top;
  margin: 6.5em 4.5em 5em;
  width: 2.6em;
  height: 2.6em;
  position: relative;
  right: 50px;
  top: 25px;
}
.dpad-pane:before, .dpad-pane:after {
  content: "";
  background-color: #ddd;
  width: 100%;
  height: 280%;
  position: absolute;
  top: -94%;
  left: 0;
  border-radius: .3em;
}
.action-pane {
  margin-right: 75px;
}
  .dpad-hole:before, .dpad-hole:after {
    content: "";
    background-color: #000;
    margin: 7%;
    width: 0%;
    height: 265%;
    position: absolute;
    top: -93%;
    left: 0;
    border-radius: .2em;
    z-index: 1;
  }
  .dpad-pane:after, .dpad-hole:after  {
    transform: rotate(90deg);
  }
  #dpad {
    position: relative;
    z-index: 1;
    top: -.006em;
    left: -.1em;
  }
  #dpad:after { /* dpad-pit */
    content: "";
    position: absolute;
    z-index: 1;
    width: 1.2em;
    height: 1.2em;
    margin: .4em .5em;
    border-radius: 1em;
    background: -webkit-radial-gradient(76% 63%, circle closest-corner, hsla(0, 0%, 60%, 0.45), hsla(0, 0%, 10%, 1) 100%);
    background: -moz-radial-gradient(76% 63%, circle closest-corner, hsla(0, 0%, 60%, 0.45), hsla(0, 0%, 10%, 1) 100%);
    background: radial-gradient(76% 63%, circle closest-corner, hsla(0, 0%, 60%, 0.45), hsla(0, 0%, 10%, 1) 100%);
    box-shadow: -3px -2px 4px -1px #444444 inset /* scalable units did not work well across browsers */;
  }
  #dpad.up {
    transform: rotate(.4deg) scaleY(0.98);
    margin-top: .05em;
    margin-left: .15em;
  }
  #dpad.right {
    transform: rotate(.5deg) scaleX(1.02);
    margin-top: .01em;
    margin-left: .11em;
  }
  #dpad.down {
    transform: rotate(-.6deg) scaleY(1.01);
    margin-top: .05em;
    margin-left: .05em;
  }
  #dpad.left {
    transform: rotate(-.8deg) scaleX(0.97);
    margin-top: .015em;
    margin-left: .1em;
  }
    #dpad-body {
      left: -2.3em;
      top: -2.3em;
      position: absolute;
      z-index: 1;
    }
    #dpad .button {
      position: absolute;
      z-index: 2;
      width: 2em;
      height: 2em;
      background-color: rgba(0, 0, 0, 0); /* "transparent" buttons in ie9 aren't clickable, but rgba can be used */
      border: none;
      padding: 0;
    }
    #dpad .button:before {
      content: "";
      display: block;
      position: absolute;
      margin: 0 .55em 0;
      width: .8em;
      height: .8em;
      border-width: .1em;
      border-style: solid;
      transform: rotate(315deg);
    }
    #dpad .button:after {
      content: "";
      display: block;
      position: absolute;
      margin: .5em .5em 0;
      width: .8em;
      height: .45em;
      border-width: .1em;
      border-style: solid;
    }
    #up { top: -2.7em; }
      #up:before { border-color: #151515 #444 transparent transparent; }
      #up:after { border-color: transparent #444 #444 #151515; }
    #right {
      left: 2.7em;
      transform: rotate(90deg);
    }
      #right:before { border-color: #444 #444 transparent transparent; }
      #right:after { border-color: transparent #444 #151515 #151515; }
    #down {
      top: 2.7em;
      transform: rotate(180deg);
    }
      #down:before { border-color: #444 #151515 transparent transparent; }
      #down:after { border-color: transparent #151515 #151515 #444; }
    #left {
      left: -2.7em;
      transform: rotate(270deg);
    }
      #left:before { border-color: #444 #151515 transparent transparent; }
      #left:after { border-color: transparent #151515 #444 #444; }
  /* Mute Button */
  .mute-container {
    position: absolute;
    top: 50px;
    right: 40px;
  }
  
  #mute-music {
    display: block;
    position: relative;
    background: radial-gradient(circle at 35% 35%, #ff8957, #E0421B 100%);
    border: 3px solid #c3442d;
    border-radius: 0.4rem;
    width: 4rem;
    height: 4rem;
    line-height: 4rem;
    font-size: 1rem;
    color: #c3442d;
    text-align: center;
    box-shadow: inset -2px -2px 4px rgba(255, 255, 255, 0.4),
                inset 2px 2px 4px rgba(0, 0, 0, 0.3),
                3px 3px 6px rgba(0, 0, 0, 0.4);
    transition: transform 0.1s ease-in-out, box-shadow 0.1s;
    display: flex;
    justify-content: center;
    align-items: center;
  }
  #mute-music:active {
    transform: scale(0.9);
    box-shadow: inset -1px -1px 3px rgba(255, 255, 255, 0.5),
                inset 1px 1px 3px rgba(0, 0, 0, 0.4);
  }
  #mute-icon {
    width: 2rem;
    height: 2rem;
    transition: opacity 0.3s ease-in-out;
  }

/* sprites */
.sprites {
  position: absolute;
  z-index: 2;
  top: 45%;
}
.sprite {
  display: none; /* Hide all sprites by default */
  width: 100px;
  height: 200px;
  background-position: 0 0; 
  background-repeat: no-repeat;  
  position: absolute;
}
.sprite.visible {
  display: block; /* Only show the active sprite */
}
.spritekick {
  width: 190px;
  background-image: url(./images/s-kick.webp);
  animation: playSpritekick 1s steps(2) infinite;
}
.spritewin {
  width: 120px;
  background-image: url('./images/s-win.webp');
  animation: playSpriteWin 1s steps(7) infinite; 
}
.spriteleg {
  width: 190px;
  background-image: url(./images/s-leg.webp);
  animation: playSpriteLeg 1s steps(5) infinite;
  top: -10px;
}
.spriteceleb {
  width: 120px;
  background-image: url(./images/s-celeb.webp);
  animation: playSpriteCeleb 1s steps(10) infinite;
  top: -80px;
  background-size: 1350px;
  height: 330px;
}
.spritehit {
  width: 150px;
  top: -20px;
  background-image: url('./images/s-hit.webp');
  animation: playSpritehit 1s steps(5) infinite; 
}
.spritefoot {
  width: 240px;
  background-image: url(./images/s-foot.webp);
  animation: playSpriteFoot 1s steps(3) infinite;
}

.spritejump {
  width: 110px;
  height: 230px;
  top: -50px;
  background-image: url(./images/s-jump.webp);
  animation: playSpriteJump 1s steps(5) infinite;
}
.spritestance {
  width: 130px;
  background-image: url(./images/s-stance.webp);
  animation: playSpriteStance 3s steps(8) infinite;
}
.spriteturn {
  width: 150px;
  background-image: url(./images/s-turn.webp);
  animation: playSpriteTurn 1s steps(3) infinite;
}
@keyframes moveNoise {
  0% {
    transform: translateY(0); /* Start at the top */
  }
  100% {
    transform: translateY(-60%); /* Défile jusqu'à -200% */
  }
}

@keyframes slideInRight {
  0% {
    transform: translateX(-100%); /* Hors de l'écran à gauche */
    opacity: 0; /* Invisible */
  }
  50% {
    opacity: 0.5; /* Apparition progressive */
  }
  100% {
    transform: translateX(0); /* Position normale */
    opacity: 1; /* Complètement visible */
  }
}


@keyframes playSpritekick {
    from {
      background-position: 0 0; 
    }
    to {
      background-position: -400px 0; 
    }
  }

  
@keyframes playSpriteWin {
    from {
      background-position: 0 -25px; 
    }
    to {
      background-position: -940px -25px;
  }
}

@keyframes playSpriteLeg {
    from {
      background-position: 53px 0;
        }
    to {
      background-position: -1055px 0;
      }
}


@keyframes playSpriteCeleb {
    from {
      background-position: 0 0; 
    }
    to {
      background-position: -1360px 0;
      }
}

@keyframes playSpritehit {
    from {
      background-position: 0 0; 
    }
    to {
      background-position: -950px 0;
  }
}

@keyframes playSpriteFoot {
    from {
      background-position: 60px 0;
    }
    to {
      background-position: -660px 0;  
    }
}

@keyframes playSpriteJump {
  from {
    background-position: -40px 0;  }
  to {
    background-position: -730px 0;  }
}

@keyframes playSpriteStance {
  from {
    background-position: -35px 0;  
  }
  to {
    background-position: -1240px 0;
    }
}

@keyframes playSpriteTurn {
  from {
    background-position: 0 0; 
  }
  to {
    background-position: -530px 0; 
  }
}

.rightHand>#controllerInner {
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.rightHand {
  position: absolute;
  z-index: 9;
  right: 0;
  background-color: #2a2a2a;
  border-radius: 15px 0 0 15px;
  border: 8px solid #ddd;
  border-right: none;
  box-shadow: inset 0 0 3px #ddd;
  width: 200px;
  height: 300px;
  display: flex;
  justify-content: center;
  align-items: center;
}
.leftHand#controllerOut {
  padding-left: 0;
  width: 230px;
}
.leftHand>#controllerInner {
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  margin-left: 0;
}
#controllerOut {
  position: absolute;
  top: calc(50vh - 150px);
  background: #c3c4c6;
  height: 270px;
  border-top: solid 4px #d2d6d7;
  box-shadow: 0 12px 12px 0 rgba(0, 0, 0, 0.55);
  padding-right: 0;
  padding-top: 30px;
  padding-bottom: 0;
  height: 300px;
}

#controllerInner {
  background: linear-gradient(#2e2724, #1F1714) left repeat;
  width: 480px;
  margin: 0;
  margin-left: 15px;
  border-radius: 6px;
  top: 35px;
  width: 210px;
  box-shadow: inset 2px -2px 4px 0 rgba(50, 50, 50, 0.75);
  border: 1px solid #191816;
  height: 280px;
}
/*
#controllerOut {
  position: relative;
  background: #c3c4c6;
  width: 500px;
  height: 200px;
  margin: 0 auto;
  border-top: solid 4px #d2d6d7;
  top: 150px;
  box-shadow: 0 12px 12px 0 rgba(0, 0, 0, 0.55);
  border-radius: 9px;
   
}
#controllerInner {
  position: relative;
  background: linear-gradient(#2e2724, #1F1714) left repeat;
  width: 480px;
  height: 155px;
  margin: 0 auto;
  border-radius: 6px;
  top: 35px;
  box-shadow:  inset 2px -2px 4px 0 rgba(50, 50, 50, 0.75);
  border: 1px solid #191816;
}*/



  /* WORKS */
  .works-container {
    text-align: center;
    margin-top: 2rem;
  }
  
  .works-title {
    font-size: 3rem;
    color: white;
    text-shadow: 3px 3px 0 red;
  }
  
  .works-list {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
    margin-top: 2rem;
  }
  
  .work-item {
    background: linear-gradient(to bottom, #222, #111);
    border: 4px solid #888;
    padding: 1rem;
    width: 300px;
    text-align: center;
  }
  
  .work-image {
    width: 100%;
    height: auto;
    border-bottom: 2px solid #444;
  }
  
  .work-title {
    font-size: 1.5rem;
    color: #ffdd57;
  }
  
  .work-description {
    color: white;
  }
  
  .work-date {
    color: gray;
  }
  
  .work-tag {
    background-color: red;
    color: white;
    padding: 5px 10px;
    font-size: 0.8rem;
  }
  
  .work-client {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 10px;
  }
  
  .client-logo {
    width: 30px;
    height: auto;
    margin-right: 10px;
  }
  
  .client-name {
    color: white;
  }
  .game-over {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3rem;
    color: white;
    text-shadow: 3px 3px 0 red;
    z-index: 9;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    opacity: 0; /* Initially invisible */
    transition: opacity 2s ease-in-out; /* Smooth fade-in effect */
  }
  
  .game-over.show {
    display: flex; /* Change from none to flex */
    align-items: center;
    justify-content: center;
    flex-direction: column;
    opacity: 1; /* Fully visible */
  }
  
  .game-over-text {
    font-size: 1.5rem;
    color: white;
    text-shadow: 3px 3px 0 red;
  }
  .restart {
    font-size: 2rem;
    padding: 15px 30px;
    color: white;
    background: linear-gradient(to bottom, #ff4747, #8b0000);
    border: 3px solid #c3442d;
    text-shadow: 3px 3px 0 black;
    border-radius: 10px;
    cursor: pointer;
    box-shadow: 0 4px 0px red;
    transition: all 0.2s ease-in-out;
    margin-top: 20px;
  }
  
  .restart:hover {
    background: linear-gradient(to bottom, #ff6969, #b30000);
    box-shadow: 0 6px 0px red;
  }
  
  .restart:active {
    transform: translateY(2px);
    box-shadow: 0 2px 0px red;
  }
  .game-over-text h1 {
    letter-spacing: 0.1em;
    margin-top: 1em;
    }

  /* ---------------------------- */
  /* Accordion system */
  /* ---------------------------- */
  .accordion-content {
    display: none;
  }
  
  .score-item.expanded .accordion-content {
    display: block;
  }
    
/* ---------------------------- */
/* Portfolio Section Base Styles */
/* ---------------------------- */
.innerSection {
  z-index: 9;
  position: relative;
  width: 50%;
  margin: auto;
}
/* Skills Section */
.skills-section {
  color: rgb(226, 179, 24);
  text-shadow: 0 2px 0 rgb(107, 77, 11), 2px 0 0 rgb(151, 109, 19), 2px 2px 0 rgb(151, 109, 19);
}
.skills-header .retro-title {
  font-size: 2.5rem;
  margin-bottom: .5rem;
}
.score-item {
  font-size: 1.2em;
}
/* --- Highlight the Selected Row --- */
.score-item.selected {
  background-color: rgba(255, 255, 255, 0.2); /* Transparent white highlight */
}

/* --- Score Header Layout with Dotted Separators --- */
.score-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Ensure the text doesn’t wrap */
.score-header > span {
  white-space: nowrap;
}

/* For every span except the last one, insert a dotted line after it */
.score-header > span:not(:last-child)::after {
  content: "";
  flex: 1;  /* Fills the space between items */
  border-bottom: 1px dotted rgba(255, 255, 255, 0.7);
  margin: 0 10px;  /* Adjust the horizontal space as needed */
}
.score-list li {
  list-style: decimal-leading-zero;
  padding: 0.5em 0;
}
/* portfolio */
.portfolio-section {
  color: white;
  padding: 2rem;
  text-align: center;
}
.accordion-content a {
  color: rgb(226, 179, 24);
}
/* Header Title */
.portfolio-header .retro-title {
  color: rgb(226, 179, 24);
  font-size: 2.5rem;
  margin-bottom: 1.5rem;
}
  .accordion-content.active {
    display: block;
  }
  .episode-gif {
    width: 50%;
    height: 420px; /* Reserve space to prevent shifting */
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease-in-out;
    display: flex; 
    margin: auto;
    margin-top: -50px;
     }

  .accordion-content.active .episode-gif {
    opacity: 1;
    visibility: visible;
  }
/* ---------------------------- */
/* Menu Panel Styles */
/* ---------------------------- */
.menu-panel {
  border: 2px solid #fff;
  display: inline-block;
  padding: 1rem;
  text-align: left;
  width: 100%;
}

/* Episode List */
.episode-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

/* Each Episode Option */
.episode {
  border-bottom: 1px solid #fff;
  padding: 0.5rem;
  position: relative;
  cursor: pointer;
  outline: none;
  transition: background-color 0.2s ease;
}

/* Remove border from last item */
.episode:last-child {
  border-bottom: none;
}

/* Hover and Selected Effects */
.episode:hover,
.episode.selected {
  background-color: rgba(255, 255, 255, 0.1);
}
.episode.selected {
  overflow-y: scroll;
  max-height: 50vh;
}
/* Episode Header: Thumbnail and Title */
.episode-header {
  display: flex;
  align-items: center;
}

/* Thumbnail Style */
.episode-thumbnail {
  width: 40px;
  height: 40px;
  margin-right: 1rem;
  image-rendering: pixelated;
}

/* Episode Title */
.episode-title {
  font-weight: bold;
  font-size: 1.2rem;
  color: white;
}

/* Gun Icon */
/* When an episode is selected, add a gun icon before its header */
.episode.selected .episode-header::before {
  display: inline-block;
  margin-right: 0.5rem;
}

/* ---------------------------- */
/* Accordion Content */
/* ---------------------------- */
.accordion-content {
  display: none;
  padding: 0.5rem 2rem;
  font-size: 0.9rem;
  border-top: 1px dashed #fff;
  margin-top: 0.5rem;
}

.episode.expanded .accordion-content {
  display: block;
}

/* Ensure images in the accordion have a pixelated look */
.accordion-image {
  width: 100%;
  max-width: 300px;
  display: block;
  margin: 0.5rem auto;
  image-rendering: pixelated;
}

/* ---------------------------- */
/* Navigation Instructions */
/* ---------------------------- */
.navigation {
  margin-top: 1rem;
  text-align: center;
  font-size: 0.8rem;
}

/* General Image Rendering for Pixel Art */
img {
  image-rendering: pixelated;
}


/* MENU */
@font-face {
  src: url(https://s3-us-west-2.amazonaws.com/s.cdpn.io/86186/terminal_copy.ttf);
  font-family: 'Terminal';
}
@font-face {
  src: url(https://s3-us-west-2.amazonaws.com/s.cdpn.io/86186/sys.ttf) format('truetype');
  font-family: 'Sys';
}

.screener::before {
  background: transparent linear-gradient(to bottom, #85908c 0%, #323431 100%) repeat scroll 0 0;
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate3d(-50%, -50%, 0);
  width: 100%;
  height: 100%;
  z-index: -1;
}
.scanlines {
  position: absolute;
  top: 0;
  z-index: 0;
}

.scanlines .overlay {
  height: 100%;
  left: 0;
  position: absolute;
  top: 0;
  width: 100%;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}
/*.scanlines .overlay::after {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  background-image: url('https://s3-us-west-2.amazonaws.com/s.cdpn.io/86186/crt.png');
  background-repeat: no-repeat;
  background-size: 100% 100%;
  content: "";
}*/
.scanlines .overlay::before {
  position: absolute;
  top: 0;
  left: 0;
  bottom: 0;
  right: 0;
  content: " ";
  background: linear-gradient(rgba(18, 16, 16, 0) 50%, rgba(0, 0, 0, 0.25) 50%), linear-gradient(90deg, rgba(255, 0, 0, 0.06), rgba(0, 255, 0, 0.02), rgba(0, 0, 255, 0.06));
  z-index: 2;
  background-size: 100% 2px, 3px 100%;
}

.picture {
  height: 100vh;
  overflow: hidden;
  width: 100vw;
  z-index: -1;
  transform: scale(0, 0);
  background: transparent linear-gradient(to bottom, #85908c 0%, #323431 100%) repeat scroll 0 0;
}

.tvmenu {
  opacity: 0;
  background-color: #0069ff;
  box-sizing: border-box;
  font-family: "Sys";
  font-size: 40px;
  height: auto;
  text-transform: uppercase;
  width: 30%;
  text-shadow: 1px 1px 0 #000000, -1px -1px 0 #000000, 1px -1px 0 #000000, -1px 1px 0 #000000;
  filter: blur(1px);
  color: #fff;
  animation: jerkup 100ms infinite;
  z-index: 8;
}
.tvmenu header {
  color: #e7e05c;
  margin-bottom: 10px;
  padding: 5px 15px;
  animation: 5s ease 2000ms normal none infinite running glitch;
}
.tvmenu ul {
  margin: 0;
  padding: 0;
  animation: 5s ease 2000ms normal none infinite running glitch;
}
.tvmenu ul li {
  box-sizing: border-box;
  list-style: none;
  padding: 5px 15px;
}
.tvmenu ul li.active {
  background-color: #1af2ff;
}
.tvmenu ul li.active a {
  /* background-color: #1af2ff; */
}
.tvmenu ul li a {
  color: #fff;
  text-decoration: none;
}
.tvmenu footer {
  background-color: #2afd72;
  margin-top: 10px;
  padding: 5px 15px;
  animation: 5s ease 2000ms normal none infinite running glitch;
}
.tvmenu footer::after {
  clear: both;
  content: " ";
  display: table;
}
.tvmenu footer .key {
  float: left;
  width: 50%;
}
.tvmenu footer .key span {
  background-color: #0069ff;
  border: 6px solid #e7e05c;
  border-radius: 6px;
  display: inline-block;
  height: 34px;
  line-height: 36px;
  padding-left: 6px;
}
.tvmenu footer .key:last-child {
  text-align: right;
}

.on .picture {
  animation: 3000ms linear 0ms normal forwards 1 running on;
}

.off .picture {
  animation: 750ms cubic-bezier(0.230, 1.000, 0.320, 1.000) 0ms normal forwards 1 running off;
}

.text {
  color: lime;
  content: "AV-1";
  opacity: 0;
  filter: blur(0.5px);
  font-family: Sys;
  font-size: 6vmin;
  left: 5%;
  position: absolute;
  text-shadow: 0 0 3px lime;
  top: 10%;
  width: 200px;
}

.on .text,
.on .tvmenu {
  opacity: 1;
  transition: opacity 10ms ease 2000ms;
}

@keyframes on {
  0% {
    transform: scale(1, 0.8) translate3d(0, 0, 0);
    filter: brightness(4);
    opacity: 1;
  }
  3.5% {
    transform: scale(1, 0.8) translate3d(0, 100%, 0);
  }
  3.6% {
    transform: scale(1, 0.8) translate3d(0, -100%, 0);
    opacity: 1;
  }
  9% {
    transform: scale(1.3, 0.6) translate3d(0, 100%, 0);
    filter: brightness(4);
    opacity: 0;
  }
  11% {
    transform: scale(1, 1) translate3d(0, 0, 0);
    filter: contrast(0) brightness(0);
    opacity: 0;
  }
  100% {
    transform: scale(1, 1) translate3d(0, 0, 0);
    filter: contrast(1) brightness(1.2) saturate(1.3);
    opacity: 1;
  }
}

@keyframes off {
  0% {
    transform: scale(1, 1);
    filter: brightness(1);
  }
  40% {
    transform: scale(1, 0.005);
    filter: brightness(100);
  }
  70% {
    transform: scale(1, 0.005);
  }
  90% {
    transform: scale(0.005, 0.005);
  }
  100% {
    transform: scale(0, 0);
  }
}

.text span {
  filter: blur(1px);
  position: absolute;
}

.text span:nth-child(1) {
  color: red;
  margin-left: -2px;
  filter: blur(2px);
}

.text span:nth-child(2) {
  color: lime;
  margin-left: 2px;
  filter: blur(2px);
}

.text span:nth-child(3) {
  color: blue;
  position: 20px 0;
  filter: blur(1px);
}

.text span:nth-child(4) {
  color: #fff;
  filter: blur(1px);
  text-shadow: 0 0 50px rgba(255, 255, 255, 0.4);
}

.text span:nth-child(5) {
  color: rgba(255, 255, 255, 0.1);
  filter: blur(15px);
}

.text span {
  animation: blur 30ms infinite, jerk 50ms infinite;
}
/* RESPONSIVE MOBILE */ 
/* screen under 960px */

.mobile-start {
  display: none;
  width: 80px;
  right: 0;
  margin: auto;
  flex-direction: column;
  height: 100px;
  position: absolute;
  align-self: anchor-center;
  margin-top: 30px;
}
.mobile-menu {
  display: none;
  position: fixed;
  bottom: 60px;
  right: 0;
  background-color: #2a2a2a87;
  height: 160px;
  width: 100px;
  border-radius: 10px 0px 0 10px;
  z-index: 99;
  box-shadow: 0 12px 12px 0 rgba(0, 0, 0, 0.55);
}
@media (max-width: 1360px) {
  #controllerOut {
    width: 150px;  }
  .leftHand#controllerOut  {
    width: 150px;  }
  .dpad-pane {
    right: 80px;
  }
  .action-pane {
    margin-right: 0px;
  }
  .leftHand>#controllerInner {
    margin-left: -90px;
    }
    .tvmenu {
      width: 50%;
    }
    .start-buttons.menu-button {
      right: 20px;
  }
  .rightHand  .start-buttons{
      left: 1.8em;
  }

}


@media (max-width: 1100px) {
  .title h1 {
    font-size: 4rem;
  }  
  h1>span {
    font-size: 6rem;
  }
  /* activate mobile menu */
  .mobile-start {
    display: flex;
  }
  .mobile-menu {
    display: flex;
  }
  .language-selector {
    padding: 15px;
    }
  .lang-button img {
    width: 60px;
  } 
  .title {
    margin-left: 15%;
  }
  .intro-box {
    margin-top: 5em;
  }
  .buttons {
    margin-top: 0em;
  }
  .onlylarge {
    display: none;
  }
  .launchmenu{
    font-size: 2.7rem;
    }
  .intro-text {
    margin: 15px;
    font-size: 1.5em;
    text-align: start;
  }
  .sprite {
    animation: none !important; /* Disable all sprite animations */
  }
  .title-top {
    margin-bottom: -4rem;
  }
  .sprite {
    display: none !important;
    animation: none !important; /* Disable all sprite animations */
  }
  .intro {
    height: 100%;
  }
  .title-bottom {
    margin-bottom: 0.5rem;
  }
  .portfolio-header .retro-title {
    font-size: 1.5rem;
  }

}
/*******************/
/* height responsive */
@media (max-height: 1200px) {
  .title h1 {
    font-size: 4rem;
  }
  .title-top {
    margin-bottom: -5rem;
  }
  h1>span {
    font-size: 6rem;
  }
  .innerSection {
    overflow-y: auto;
    max-height: calc(100vh - 500px);
  }
  .launchmenu {
    font-size: 2rem;
  }
  .launchmenu .butttons {
    margin-top: 0;
  }
  .launchmenu .butttons a {
    margin-bottom: 0;
  }

}

@media (max-height: 1000px) {
  .title h1 {
    font-size: 2rem;
}
.title-top {
  margin-bottom: -4rem;
}
  h1>span {
    font-size: 4rem;
}
  .innerSection {
    max-height: calc(100vh - 250px);
  }
}
/*******************/

@media (max-width: 820px) {
  .shrink-titles .title h1 {
    font-size: 2rem;
  }
  .shrink-titles h1 > span {
    font-size: 3rem;
  }

  .score-list {
    padding-left: 0;
  }
  .score-list li {
  list-style: none;
  }
  .title {
    margin-top: 3em;
  }
  .title h1 {
    font-size: 3rem;
  
  }
  .title h1 {
    width: 120%;
  }
  h1>span {
    font-size: 5rem;
  }
  .title-bottom {
    margin-top: 2rem;
}
  .intro-box {
    margin-top: 0em;
    margin: 25px;
  }
  .language-selector {
    padding: 5px;
  }
  .lang-button img {
    width: 50px;
  }
  .innerSection {
    width: 80%;
  }
  .tvmenu {
    width: 70%;
  }
  .episode-gif {
    width: 100%;
  }
  .episode.selected {
    max-height: 35vh;
}
}
@media (max-width: 600px) {
  .intro-text {
    font-size: 1.2em;
  }

  .title-bottom {
    margin-top: 2rem;
  }
  .launchmenu{
    font-size: 1.5rem;
    width: 80%;
  }
  .tvmenu {
    width: 90%;
}
  .intro-box {
    max-width: 80%;
    padding: 15px;
    border: 2px solid #888;
  }
  .buttons {
    margin-top: -0.3em;
  }
  .launchmenu.buttons {
    margin-top: 0;
  }
  .accordion-content {
    padding: 0.5rem 1rem;
  }
  .menu-panel {
    padding: 0;
    width: inherit;
  }
  .innerSection {
    width: 90%;
  }
  .bottom-text {
    font-size: 1em;
}
.television-screen {
    padding-bottom: 2em;
  }
}
@media (max-width: 400px) {
  .title h1 {
    font-size: 2rem;
  }
  h1>span {
    font-size: 3rem;
  }
  .intro-text {
    font-size: 1.1em;
  }
  .lang-button {
    padding: 2px;
  }
  .lang-button img {
    width: 40px;
  }
  .menu-panel {
    padding: 0;
  }
  .accordion-content {
    display: none;
    padding: 0.2rem 0.5rem;
  }

}


@keyframes blur {
  0% {
    filter: blur(1px);
    opacity: 0.8;
  }
  50% {
    filter: blur(1px);
    opacity: 1;
  }
  100% {
    filter: blur(1px);
    opacity: 0.8;
  }
}

@keyframes jerk {
  50% {
    transform: translateX(1px);
  }
  51% {
    transform: translateX(0);
  }
}

@keyframes jerkup {
  0% {
    transform: translateY(1px);
  }
  100% {
    transform: translateY(0);
  }
}

.text span:nth-child(2) {
  animation: jerkup 1s infinite;
}

.text span:nth-child(3) {
  animation: glitch1 1s infinite;
}

@keyframes glitch1 {
  0% {
    transform: translateX(0);
  }
  30% {
    transform: translateX(0);
  }
  31% {
    transform: translateX(10px);
  }
  32% {
    transform: translateX(0);
  }
  98% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(10px);
  }
}

.text span:nth-child(2) {
  animation: glitch2 1s infinite;
}

@keyframes glitch2 {
  0% {
    transform: translateX(0);
  }
  30% {
    transform: translateX(0);
  }
  31% {
    transform: translateX(-10px);
  }
  32% {
    transform: translateX(0);
  }
  98% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-10px);
  }
}

.overlay .text {
  animation: 5s ease 2000ms normal none infinite running glitch;
}

@keyframes glitch {
  30% {
  }
  40% {
    opacity: 1;
    transform: scale(1, 1);
    transform: skew(0, 0);
  }
  41% {
    opacity: 0.8;
    transform: scale(1, 1.2);
    transform: skew(80deg, 0);
  }
  42% {
    opacity: 0.8;
    transform: scale(1, 1.2);
    transform: skew(-50deg, 0);
  }
  43% {
    opacity: 1;
    transform: scale(1, 1);
    transform: skew(0, 0);
  }
  65% {
  }
}
