/* skrimpf.club version: 1.0 (revision 11) */
/*
 * Exact font restoration. Proprietary originals are self-hosted from ../fonts/.
 * Alien Encounters is loaded remotely; Montserrat is loaded in index.html.
 */

@font-face {
  font-family: 'Papyrus';
  src: local('Papyrus'), url('../fonts/Papyrus.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Papyrus';
  src: local('Papyrus'), url('../fonts/Papyrus.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Impact';
  src: local('Impact'), url('../fonts/Impact.ttf') format('truetype');
  font-weight: 400 900;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Brush Script MT';
  src: local('Brush Script MT'), local('Brush Script MT Italic'), url('../fonts/BrushScriptMT.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Comic Sans MS';
  src: local('Comic Sans MS'), url('../fonts/ComicSansMS.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Comic Sans MS';
  src: local('Comic Sans MS Bold'), url('../fonts/ComicSansMS-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Times New Roman';
  src: local('Times New Roman'), url('../fonts/TimesNewRoman.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Times New Roman';
  src: local('Times New Roman Bold'), url('../fonts/TimesNewRoman-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Arial Black';
  src: local('Arial Black'), url('../fonts/ArialBlack.ttf') format('truetype');
  font-weight: 400 900;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Georgia';
  src: local('Georgia'), url('../fonts/Georgia.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Georgia';
  src: local('Georgia Bold'), url('../fonts/Georgia-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Courier New';
  src: local('Courier New'), url('../fonts/CourierNew.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Courier New';
  src: local('Courier New Bold'), url('../fonts/CourierNew-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Tahoma';
  src: local('Tahoma'), url('../fonts/Tahoma.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Tahoma';
  src: local('Tahoma Bold'), url('../fonts/Tahoma-Bold.ttf') format('truetype');
  font-weight: 700;
  font-style: normal;
  font-display: block;
}
@font-face {
  font-family: 'Alien Encounters';
  src: url('https://static.wfonts.com/data/2015/05/14/alien-encounters-solid/ALIEESB.ttf') format('truetype');
  font-weight: 400 700;
  font-style: normal;
  font-display: block;
}

html, body {
  margin: 0;
  padding: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  font-family: 'Tahoma', sans-serif;
}

body {
  background-color: #000;
  background-image: none;
  background-repeat: repeat;
}

body.tiled-bg {
  background-color: #000;
  background-image: none;
}

body.happyfruit-bg {
  background-color: #000;
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}

#starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
}


html.fonts-loading #welcome-dialog {
  visibility: hidden;
}

html.fonts-ready #welcome-dialog {
  visibility: visible;
}

#center-wrap {
  position: absolute;
  top: 50%;
  left: 50%;
  cursor: pointer;
  z-index: 15;
  transition: opacity 2s ease;
}

#center-wrap img {
  display: block;
  transform-origin: center;
  object-fit: contain;
  max-width: 80vw;
  max-height: 80vh;
  transition: width 0.4s ease, transform 0.25s ease;
}

#bouncer,
.extra-bouncer {
  position: absolute;
  top: 0;
  left: 0;
  font-weight: 700;
  white-space: nowrap;
  user-select: none;
  will-change: transform;
  z-index: 3;
}

#bouncer {
  color: hsl(0, 90%, 60%);
  cursor: pointer;
  transition: opacity 0.3s ease, font-size 0.4s ease;
}

.extra-bouncer {
  pointer-events: auto;
  cursor: pointer;
}

#sinner-text {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: clamp(3rem, 20vw, 10.6667rem);
  font-weight: 700;
  color: #f00;
  white-space: nowrap;
  user-select: none;
  pointer-events: none;
  opacity: 0;
  display: none;
  z-index: 20;
}

#tile-layer {
  display: none;
  position: fixed;
  box-sizing: border-box;
  background-image: url('../skrimpf2.png');
  background-repeat: repeat;
  background-size: 150px 90px;
  align-items: center;
  justify-items: center;
  font-weight: 700;
  font-size: 22px;
  color: rgba(255, 255, 255, 0.92);
  text-shadow: 1px 1px 2px #000, -1px -1px 2px #000;
  pointer-events: none;
  z-index: 5;
  will-change: transform;
}

#tile-layer span {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

#forsaken {
  position: fixed;
  top: 18%;
  left: 50%;
  transform: translateX(-50%);
  color: #f00;
  background: #000;
  padding: 0.08em 0.22em 0.12em;
  box-shadow: 0 0 0 3px #000;
  font-weight: 700;
  font-size: 4rem;
  letter-spacing: 2px;
  pointer-events: none;
  opacity: 0;
  display: none;
  z-index: 25;
}


/* Initial welcome dialogue */
#welcome-overlay {
  position: fixed;
  inset: 0;
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #000;
}

#welcome-dialog {
  position: relative;
  width: min(560px, calc(100vw - 48px));
  min-height: 220px;
  box-sizing: border-box;
  padding: 48px 42px 28px;
  background: #000;
  color: #fff;
  font-family: 'Papyrus', fantasy;
}

.welcome-frame {
  position: absolute;
  inset: 12px;
  border: 2px solid rgba(255, 255, 255, 0.95);
  transform: rotate(-0.18deg) skewX(-0.35deg);
  pointer-events: none;
  filter: url(#chalk-roughness);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.25);
}

.welcome-frame::after {
  content: '';
  position: absolute;
  inset: 3px -2px -2px 2px;
  border: 1px solid rgba(255, 255, 255, 0.55);
  transform: rotate(0.25deg) skewX(0.3deg);
}

#welcome-title {
  position: relative;
  z-index: 1;
  width: max-content;
  max-width: 80%;
  margin: -10px auto 28px;
  padding: 0 14px;
  background: #000;
  font-family: 'Papyrus', fantasy;
  font-size: clamp(1.35rem, 4vw, 2rem);
  font-weight: normal;
  line-height: 1.2;
  text-align: center;
}

#welcome-message {
  position: relative;
  z-index: 1;
  margin: 0 0 34px;
  font-family: 'Papyrus', fantasy;
  font-size: clamp(0.9rem, 2.2vw, 1.15rem);
  line-height: 1.5;
  text-align: left;
}

.welcome-actions {
  position: relative;
  z-index: 1;
  display: flex;
  justify-content: flex-end;
}

#welcome-close {
  padding: 5px 18px;
  border: 1px solid #fff;
  background: #000;
  color: #fff;
  font-family: 'Papyrus', fantasy;
  font-size: 0.95rem;
  cursor: pointer;
}

#welcome-close:hover,
#welcome-close:focus-visible {
  background: #fff;
  color: #000;
  outline: none;
}

.falling-letter {
  position: fixed;
  top: 0;
  left: 0;
  font-weight: 700;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
  z-index: 4;
  will-change: transform;
}


.skrimpf-apparition {
  position: fixed;
  z-index: 2;
  pointer-events: none;
  user-select: none;
  white-space: nowrap;
  opacity: 0;
  font-family: 'Montserrat', 'Tahoma', sans-serif;
  font-size: clamp(52px, 9vw, 112px);
  font-style: italic;
  font-weight: 800;
  line-height: 0.95;
  letter-spacing: -0.045em;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.45);
  animation: skrimpfApparition 10s ease-in-out forwards;
}

@keyframes skrimpfApparition {
  0% { opacity: 0; transform: scale(0.96); }
  24% { opacity: 0.95; transform: scale(1); }
  68% { opacity: 0.95; transform: scale(1); }
  100% { opacity: 0; transform: scale(1.03); }
}


/* Version 1.0 wacky click effects */
#center-wrap img.picture-wacky-compress {
  animation: pictureWackyCompress 900ms cubic-bezier(.18,.9,.3,1.35);
}

@keyframes pictureWackyCompress {
  0%   { transform: scale(1, 1); }
  18%  { transform: scale(0.28, 1.18); }
  38%  { transform: scale(1.16, 0.78); }
  58%  { transform: scale(0.84, 1.10); }
  76%  { transform: scale(1.07, 0.94); }
  100% { transform: scale(1, 1); }
}

.skrimpf-image-echo {
  position: fixed;
  z-index: 40;
  pointer-events: none;
  user-select: none;
  transform: translate(-50%, -50%);
  object-fit: contain;
  opacity: 0.96;
  animation: skrimpfImageEchoFade 1s linear forwards;
  will-change: opacity;
}

@keyframes skrimpfImageEchoFade {
  from { opacity: 0.96; }
  to   { opacity: 0; }
}

.skrimpf-storm-dialog {
  position: fixed;
  width: 286px;
  max-width: calc(100vw - 8px);
  box-sizing: border-box;
  overflow: hidden;
  color: #000;
  background: #ece9d8;
  border: 3px solid #0054e3;
  border-top-width: 0;
  border-radius: 7px 7px 2px 2px;
  box-shadow:
    2px 3px 10px rgba(0,0,0,.55),
    inset 1px 0 #0831d9,
    inset -1px 0 #001ea0,
    inset 0 -1px #001ea0;
  font: 11px 'Tahoma', sans-serif;
}

.skrimpf-storm-titlebar {
  min-height: 27px;
  margin: 0 -3px;
  padding: 4px 8px 3px;
  box-sizing: border-box;
  color: #fff;
  font: bold 13px 'Tahoma', sans-serif;
  text-shadow: 1px 1px #0f2f87;
  border-radius: 7px 7px 0 0;
  border-top: 1px solid #4aa4ff;
  border-left: 1px solid #0a46d3;
  border-right: 1px solid #001ea0;
  background:
    linear-gradient(to bottom,
      #0997ff 0%,
      #087df1 7%,
      #0058ee 20%,
      #0053ee 58%,
      #034fe4 82%,
      #003bc2 100%);
  box-shadow: inset 0 1px rgba(255,255,255,.6), inset 0 -1px #002ca5;
}

.skrimpf-storm-body {
  display: flex;
  align-items: center;
  gap: 12px;
  min-height: 70px;
  box-sizing: border-box;
  padding: 14px 17px 8px;
  background: #ece9d8;
}

.skrimpf-storm-body img {
  width: 42px;
  height: 42px;
  flex: 0 0 42px;
  object-fit: contain;
}

.skrimpf-storm-body span {
  font: 11px 'Tahoma', sans-serif;
}

.skrimpf-storm-actions {
  display: flex;
  justify-content: flex-end;
  padding: 6px 13px 12px;
  background: #ece9d8;
}

.skrimpf-storm-actions button {
  min-width: 75px;
  min-height: 23px;
  box-sizing: border-box;
  padding: 2px 11px 3px;
  border: 1px solid #003c74;
  border-radius: 3px;
  color: #000;
  background: linear-gradient(to bottom, #fff 0 45%, #e5eef7 46%, #c9dff4 100%);
  box-shadow: inset 1px 1px #fff, inset -1px -1px #8aa9c7;
  font: 11px 'Tahoma', sans-serif;
  cursor: default;
}

.skrimpf-storm-actions button:hover {
  border-color: #e68b2c;
  box-shadow: inset 1px 1px #fff, inset -1px -1px #d69d59, 0 0 0 1px #ffcf72;
}

.skrimpf-storm-actions button:active {
  padding: 3px 10px 2px 12px;
  background: #d9e8f7;
  box-shadow: inset 1px 1px #7f9db9;
}
