/* ===============================
   Reset and Base Styles
================================= */
* {
  box-sizing: border-box;
}

::-webkit-scrollbar {
  display: none;
}

[hidden] {
  display: none !important;
}

:root {
  --color-bg: #34343c;
  --color-text-main: #000000;
  --color-primary: #ffff00;
  --color-secondary: #ff0000;
  --wrapper-height: 87vh;
  --image-max-width: 300px;
  --image-margin: 3rem;
  --font-family: "HK Grotesk", sans-serif;
  --font-family-header: "HK Grotesk", sans-serif;
}

/* ===============================
   Fonts
================================= */
@font-face {
  font-family: HK Grotesk;
  src: url("https://cdn.glitch.me/605e2a51-d45f-4d87-a285-9410ad350515%2FHKGrotesk-Regular.otf?v=1603136326027") format("opentype");
}

@font-face {
  font-family: HK Grotesk;
  font-weight: 700;
  src: url("https://cdn.glitch.me/605e2a51-d45f-4d87-a285-9410ad350515%2FHKGrotesk-Bold.otf?v=1603136323437") format("opentype");
}

/* ===============================
   Animations
================================= */
@keyframes fadeIn {
  to {
    opacity: 1;
  }
}

@keyframes rainbowAnimation {
  0% { background-position: 0% 0%; }
  50% { background-position: 100% 100%; }
  100% { background-position: 0% 0%; }
}

/* ===============================
   Body and Layout
================================= */
body {
  margin: 0;
  padding: 0;
  height: 100vh;
  overflow: hidden;
  background: url("https://images.confusing.wtf/r/48xEZ1.jpg?compress=false") no-repeat center center fixed;
  background-size: cover;
  background-color: var(--color-bg);
  font-family: var(--font-family);
  opacity: 0;
  animation: fadeIn 2s ease-in forwards;
  display: flex;
  justify-content: center;
  align-items: center;
  position: relative;
}

#particles-js {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  z-index: 1;
  opacity: 0;
  animation: fadeIn 2s ease-in forwards 0.5s;
}

.wrapper {
  position: relative;
  z-index: 2;
  min-height: var(--wrapper-height);
  max-width: 80%;
  max-height: 80%;
  padding: 20px;
  margin: 0 1rem;
  display: grid;
  place-items: center;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  text-align: center;
  box-sizing: border-box;
  opacity: 0;
  animation: fadeIn 2s ease-in forwards 1s;
}

.content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 1000%;
  padding: 400px;
  background: rgba(0, 0, 0, 0.3);
  border-radius: 0;
  box-sizing: border-box;
}

/* ===============================
   Typography
================================= */
.title {
  margin: 0;
  font-size: 100px;
  font-family: var(--font-family-header);
  font-style: normal;
  font-weight: 700;
  line-height: 105%;
  background: linear-gradient(45deg, #000000, #000000, #2800ff, #2800ff, #ffffff, #ffffff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  color: #2600ff;
  cursor: context-menu;
}

.instructions {
  margin: 1rem auto 0;
}

.instructions h2 {
  font-size: 1.5em;
  color: white;
  background: none;
  display: flex;
  justify-content: center;
  align-items: center;
}

#typewriter {
  display: inline-block;
  text-align: center;
}

#secret-message {
  display: none;
  margin-top: 20px;
}

/* ===============================
   Buttons and Links
================================= */
.button-container {
  display: flex;
  justify-content: center;
  gap: 10px;
  margin-top: 20px;
  position: relative;
  text-align: center;
}

.button-container a {
  margin: 10px;
  display: block;
}

button, a {
  outline: none;
  transition: background-color 0.3s ease, transform 0.2s ease;
}

button {
  padding: 8px 16px;
  font-size: 1rem;
  color: white;
  border: none;
  border-radius: 5px;
  background: linear-gradient(45deg, #ff0000, #ff7f00);
  cursor: pointer;
}

button:hover {
  padding: 10px 20px;
  font-size: 1em;
  background: linear-gradient(45deg, #ff0000, #ff9900, #33cc33, #3399ff, #cc33ff, #ff33cc, #ff0000);
  background-size: 600% 600%;
  animation: rainbowAnimation 3s linear infinite;
  transform: scale(1.05);
}

button:active {
  background: linear-gradient(45deg, #ff0000, #ff7f00);
  transform: scale(0.98);
}

button:focus, a:focus {
  outline: 3px solid #00bfff;
}

.rainbow-button {
  padding: 8px 16px;
  font-size: 1rem;
  border: none;
  color: white;
  cursor: pointer;
  background: linear-gradient(45deg, #ff0000, #ff9900, #33cc33, #3399ff, #cc33ff, #ff33cc, #ff0000);
  background-size: 600% 600%;
  animation: rainbowAnimation 3s linear infinite;
  font-family: 'Comic Sans MS', cursive;
}

.tooltip {
  display: none;
  position: absolute;
  bottom: calc(var(--tooltip-bottom, 45%) + 10px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.8);
  color: white;
  padding: 5px;
  border-radius: 5px;
  font-size: 0.8rem;
  white-space: nowrap;
  z-index: 10;
  margin-bottom: 15px;
}

.button-container a:hover .tooltip {
  display: block;
}

/* ===============================
   UI Elements
================================= */
.hint {
  position: fixed;
  bottom: 2px;
  left: 2px;
  background: rgba(0, 0, 0, 0.7);
  color: white;
  padding: 5px 10px;
  border-radius: 5px;
  font-size: 0.9rem;
  text-align: center;
  transition: opacity 0.3s ease;
  z-index: 2000;
}

.hint:hover {
  opacity: 1;
}

.illustration {
  max-width: 100%;
  max-height: var(--image-max-width);
  margin-top: var(--image-margin);
}

.dipped {
  transform: translateY(5px);
}

.fileopener {
  cursor: pointer;
  font-weight: bold;
  border-bottom: 3px solid var(--color-primary);
  color: var(--color-secondary);
}

.fileopener:hover {
  border-bottom: 3px solid var(--color-secondary);
}

.links_underline {
  text-decoration: none;
}

.countdown-container {
  color: black;
  font-size: 30px;
  font-weight: bold;
  margin-top: 20px;
}

/* ===============================
   Menu and Navigation
================================= */
.menu {
  position: fixed;
  top: -150px;
  left: 0;
  width: 100%;
  height: 150px;
  background-color: rgba(26, 26, 26, 0.8);
  display: flex;
  justify-content: center;
  align-items: center;
  transition: top 0.5s ease-in-out;
  z-index: 1000;
  border-bottom: 2px solid #4a148c;
}

.menu.visible {
  top: 0;
}

.three-lines {
  position: fixed;
  top: 10px;
  right: 10px;
  width: 30px;
  height: 20px;
  cursor: pointer;
  z-index: 1100;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  transition: top 0.5s ease-in-out;
  transform-origin: center;
}

.three-lines div {
  background-color: white;
  height: 4px;
  transition: transform 0.3s, opacity 0.3s;
}

.three-lines.open {
  top: 160px;
}

.three-lines.open div:nth-child(1) {
  transform: rotate(45deg) translateY(11px);
}

.three-lines.open div:nth-child(2) {
  opacity: 0;
}

.three-lines.open div:nth-child(3) {
  transform: rotate(-45deg) translateY(-11px);
}

/* ===============================
   Footer
================================= */
footer {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), rgba(52, 52, 60, 0));
  color: white;
  text-align: center;
  padding: 10px;
  box-sizing: border-box;
  z-index: 1000;
  font-size: 14px;
}
