/* ------------------------------------------------------------------
   EazyScreen, feuille de style du lecteur televiseur.
   EazyWebNC, eazyweb.nc
   Cible imposee: Chrome 38 (webOS 2016).
   Pas de CSS grid, pas de variables CSS, flexbox avec repli -webkit-box.
   ------------------------------------------------------------------ */

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  color: #F2F0EC;
  overflow: hidden;
  font-family: "Helvetica Neue", Helvetica, Arial, "Liberation Sans", sans-serif;
  -webkit-text-size-adjust: none;
  -webkit-font-smoothing: antialiased;
  -webkit-user-select: none;
  user-select: none;
  -webkit-tap-highlight-color: rgba(0,0,0,0);
}

/* curseur souris masque partout */
html, body, div, video, img, span { cursor: none; }

/* ------------------------------------------------------------- la scene */

#stage {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  overflow: hidden;
  z-index: 1;
}

/* deux emplacements en alternance: l'un joue, l'autre precharge */
.slot {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: #000000;
  opacity: 0;
  visibility: hidden;
  z-index: 1;
}
.slot.on {
  opacity: 1;
  visibility: visible;
  z-index: 2;
}

/* repli des vieux moteurs: largeur et hauteur 100 pour cent, cale en 0,0.
   Nos medias sont en 16 sur 9 comme les televiseurs, le rendu est exact.
   object-fit cover prend le relais des que le moteur le comprend. */
.media {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: block;
  border: 0;
  margin: 0;
  padding: 0;
  background: #000000;
  object-fit: cover;
  -o-object-fit: cover;
  object-position: 50% 50%;
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
}
video.media { z-index: 1; }
img.media   { z-index: 2; visibility: hidden; }
img.media.on { visibility: visible; }

/* ------------------------------------------------------------ le bandeau */

#ticker {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 280px;
  height: 26vh;
  z-index: 5;
  display: none;
  pointer-events: none;
  background: -webkit-linear-gradient(top, rgba(0,0,0,0) 0%, rgba(0,0,0,0.55) 46%, rgba(0,0,0,0.88) 100%);
  background: linear-gradient(to bottom, rgba(0,0,0,0) 0%, rgba(0,0,0,0.55) 46%, rgba(0,0,0,0.88) 100%);
}
#ticker.on { display: block; }

/* zone de securite: le texte reste a plus de 8 pour cent du bord bas,
   beaucoup de televiseurs rognent l'image. */
#ticker-line {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 88px;
  bottom: 8.4vh;
  height: 78px;
  height: 7.2vh;
  overflow: hidden;
  white-space: nowrap;
}

#ticker-track {
  display: inline-block;
  white-space: nowrap;
  padding-left: 100%;
  font-size: 54px;
  font-size: 5vh;
  line-height: 78px;
  line-height: 7.2vh;
  font-weight: 700;
  letter-spacing: 0.012em;
  color: #FFFFFF;
  text-shadow: 0 2px 6px rgba(0,0,0,0.95), 0 0 26px rgba(0,0,0,0.75);
  -webkit-backface-visibility: hidden;
  backface-visibility: hidden;
  -webkit-animation-name: eztick;
  animation-name: eztick;
  -webkit-animation-timing-function: linear;
  animation-timing-function: linear;
  -webkit-animation-iteration-count: infinite;
  animation-iteration-count: infinite;
  -webkit-animation-duration: 30s;
  animation-duration: 30s;
}

@-webkit-keyframes eztick {
  from { -webkit-transform: translateX(0); }
  to   { -webkit-transform: translateX(-100%); }
}
@keyframes eztick {
  from { transform: translateX(0); }
  to   { transform: translateX(-100%); }
}

/* repli si le moteur ignore les animations: texte fixe et centre */
#ticker-track.static {
  display: block;
  padding-left: 0;
  text-align: center;
  overflow: hidden;
  text-overflow: ellipsis;
  -webkit-animation: none;
  animation: none;
}

/* ------------------------------------------- plaque sobre de repli */

#plate {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 9;
  display: none;
  text-align: center;
  background: #07090C;
  background: -webkit-radial-gradient(50% 40%, ellipse, #171D25 0%, #07090C 70%);
  background: radial-gradient(ellipse at 50% 40%, #171D25 0%, #07090C 70%);
}
#plate.on {
  display: block;
  display: -webkit-box;
  display: -webkit-flex;
  display: flex;
  -webkit-box-orient: vertical;
  -webkit-box-direction: normal;
  -webkit-flex-direction: column;
  flex-direction: column;
  -webkit-box-pack: center;
  -webkit-justify-content: center;
  justify-content: center;
  -webkit-box-align: center;
  -webkit-align-items: center;
  align-items: center;
}

#plate-in {
  width: 84%;
  max-width: 84%;
  padding: 0 8%;
}

#plate-kicker {
  font-size: 20px;
  font-size: 1.9vh;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: #C9A227;
  font-weight: 700;
  margin: 0 0 3vh 0;
}

#plate-title {
  font-size: 62px;
  font-size: 5.8vh;
  line-height: 1.16;
  font-weight: 600;
  color: #F2F0EC;
  margin: 0;
}

#plate-rule {
  width: 128px;
  height: 3px;
  background: #C9A227;
  margin: 3.4vh auto;
  opacity: 0.9;
}

#plate-msg {
  font-size: 30px;
  font-size: 2.7vh;
  line-height: 1.55;
  color: #9AA2AC;
  margin: 0 auto;
  max-width: 78%;
}

#plate-code {
  display: inline-block;
  margin-top: 3.2vh;
  padding: 1.4vh 2.6vh;
  border: 1px solid rgba(201,162,39,0.45);
  border-radius: 6px;
  background: rgba(201,162,39,0.07);
  font-family: "Courier New", Courier, monospace;
  font-size: 32px;
  font-size: 3vh;
  color: #E3C46A;
  letter-spacing: 0.02em;
}

#plate-foot {
  margin-top: 6vh;
  font-size: 22px;
  font-size: 2vh;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #6B7480;
}

/* ------------------------------------------------------ coin de depannage */

#diag {
  position: absolute;
  top: 6vh;
  right: 5%;
  z-index: 20;
  display: none;
  max-width: 42%;
  padding: 14px 18px;
  background: rgba(0,0,0,0.66);
  border: 1px solid rgba(201,162,39,0.45);
  border-radius: 5px;
  font-family: "Courier New", Courier, monospace;
  font-size: 20px;
  font-size: 1.85vh;
  line-height: 1.5;
  color: #D7DCE2;
  text-align: left;
  word-wrap: break-word;
  overflow-wrap: break-word;
}
#diag.on { display: block; }
#diag .k { color: #E3C46A; }

/* -------------------------------------------- micro video anti mise en veille */

#keepalive {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 2px;
  height: 2px;
  opacity: 0.02;
  z-index: 0;
  pointer-events: none;
}
