:root {
  box-sizing: border-box;
  margin: 0;
}

/* Layout and Styling */


html,
body {
  width: 100%;
  height: 100vh;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

body {
  font-family: 'Monaspace Radon', monospace;
  padding: 10px;
  color: #10002b;
  background-color: #fbe9ff;
  background-image: url(/images/starryybackg.webp);
  background-repeat: repeat;
  background-attachment: fixed;
}

a {
  color: #7a1cac;
  text-decoration: none;
  font-weight: bold;
}

footer {
  text-align: center;
  margin-top: 20px;
  color: #7a1cac;
  font-size: 11px;
  padding-top: 10px;
}

h1,
h2,
h3 {
  margin: 5px;
  text-align: center;
}

h1 {
  font-size: 1.4rem;
  letter-spacing: 2px;
  font-weight: normal;
  border-bottom: 2px dashed #240046;
  padding-bottom: 10px;
  font-family: 'Courier New', monospace;
  color: #7a1cac;
}

h2,
h3 {
  font-weight: normal;
  color: #240046;
}

/* Main Box Layout */

.container {
  height: 70vh;
  max-height: 85vh;
  max-width: 55rem;
  min-height: 0;
  overflow-y: auto;
  overflow-x: hidden;
  margin: 5vh auto;
  border: 4px double #240046;
  outline: none;
  border-radius: 15px;
  overflow: hidden;
  display: flex;
  flex-wrap: wrap;
  align-content: flex-start;
  padding: 5px 15px 5px 15px;
  gap: 10px;
  background-color: rgba(240, 220, 255, 0.9);
  background-image: linear-gradient(rgba(0, 0, 0, 0.05) 50%, transparent 50%);
  box-shadow: 0 0 50px 10px rgba(180, 100, 255, 0.6);
  background-size: 100% 4px;
}

.full {
  flex: 1 1 100%;
  border: none;
  min-width: 0;
}

.main {
  display: flex;
  flex-wrap: wrap;
  width: 100%;
  gap: 10px;
  align-items: center;
  height: 280px;
  justify-content: center;
}

.main section:nth-child(1) {
  flex: 2;
}

.main section:nth-child(2) {
  flex: 3;
}

.main section:nth-child(3) {
  margin-top: 50px;
}

.half {
  flex: 1;
  min-width: 250px;
}

.information {
  text-align: center;
  margin: 0;
  display: flex;
  flex-direction: column;
  justify-content: center;
  height: 100%;
  padding: 0 20px;
}

.mobile-nav {
  display: none;
}

/* Header */

header {
  width: 102%;
  height: 100px;
  background-image: url(/images/starryybackg.webp);
  border-radius: 15px;
  position: relative;

  margin-top: 10px;
  border: 3px double #240046;
}

header span {
  font-size: 2.5rem;
  position: absolute;
  bottom: -10px;
  right: 10px;
  background-color: #fbe9ff;
  color: #10002b;
  padding: 5px 15px;
  border: 3px solid #240046;
  border-radius: 15px;
  transform: rotate(-2deg);
  font-family: 'Monaspace Xenon', monospace;
  z-index: 5;
}

.scrolling-text {
  position: absolute;
  top: 10px;
  right: 20px;
  width: 50%;
  color: rgba(255, 255, 255, 0.7);
  font-family: 'Monaspace Krypton', monospace;
  font-size: 14px;
  letter-spacing: 2px;
  text-transform: uppercase;
  text-shadow: 0 0 5px #ff00ff;
  z-index: 10;
  pointer-events: none;
}

/* Header Button Cluster */
.button-cluster {
  position: absolute;
  top: 16px;
  left: 30px;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  transform: rotate(-1deg);
  z-index: 20;
}

.button-cluster img {
  width: 88px;
  height: 31px;
  display: block;
  border: 1px solid white;
  opacity: 0.8;
  transition: all 0.2s ease;
}

.button-cluster img:hover {
  opacity: 1;
  transform: scale(1.1);
  box-shadow: 0 0 10px #ff00ff;
  z-index: 30;
}

/* Blinkie Board */
.blinkie-board {
  text-align: center;
  border: none;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.blinkie-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 4px;
}

.blinkie-grid img {
  image-rendering: auto;
  border: 1px solid transparent;
  border-radius: 4px;
  transition: all 0.2s ease;
  height: 22px;
}

.blinkie-grid img:hover {
  transform: scale(1.1);
  border-color: #7a1cac;
  box-shadow: 0 0 10px #ff00ff;
  z-index: 10;
  cursor: help;
}

.retro-box {
  width: 90%;
  max-width: 350px;
  height: 200px;
  margin: 0 auto 20px auto;
  border: 2px solid #240046;
  box-shadow: none;
  border-radius: 8px;
  padding: 5px;
  background-color: rgba(255, 255, 255, 0.6);
  background-image: linear-gradient(var(--gradientBottom) 1px, transparent 1px),
    linear-gradient(90deg, var(--gradientBottom) 1px, transparent 1px);
  background-size: 20px 20px;
  overflow-y: auto;
}

.retro-box legend {
  color: #10002b;
  padding: 2px 10px;
  border-radius: 15px;
  font-weight: bold;
  position: sticky;
  top: 0;
}

.retro-box ul {
  margin-top: 5px;
  list-style-type: none;
  padding: 0 0 0 10px;
}

.retro-box li {
  padding: 5px 0;
}

/* Floating Image Links */
.floater,
.floater2 {
  position: fixed;
  z-index: 50;
  width: 230px;
  height: auto;
  display: flex;
  justify-content: center;
  align-items: center;
  transition: transform 0.3s ease-in-out;
  pointer-events: auto;
}

.sticker-img {
  width: 100%;
  height: auto;
  display: block;
}

.sticker-text {
  position: absolute;
  z-index: 10;
  color: white;
  font-weight: bold;
  font-size: 18px;
  text-decoration: none;
  text-transform: uppercase;
  letter-spacing: 1px;
  text-shadow: -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000,
    2px 2px 0 #000;
}

.sticker-container {
  padding: 40px;
}

.floater:hover {
  transform: scale(1.1) rotate(5deg);
  cursor: pointer;
}
.floater2:hover {
  transform: scale(1.1) rotate(-5deg);
  cursor: pointer;
}
.sticker-container:hover .sticker-text {
  color: #fac6ff;
}

/* Floater Positions */
.bottom-left {
  bottom: 10px;
  left: 10px;
  height: 220px;
}
.top-right {
  top: 50px;
  right: 50px;
  height: 210px;
}
.mid-right {
  top: 40%;
  right: 2%;
  height: 140px;
}
.mid-left {
  top: 38%;
  left: 10px;
  height: 200px;
}
.top-left {
  top: 0;
  left: 0;
  margin-top: 5px;
  margin-left: 10px;
  width: 300px;
}
.bottom-right {
  bottom: 10px;
  right: 30px;
  margin-bottom: 10px;
  margin-right: 10px;
  height: 230px;
}

/* Animations */
.swayer {
  animation: sway 3s infinite ease-in-out;
  transform-origin: center center;
}
@keyframes sway {
  0%,
  100% {
    transform: rotate(-8deg);
  }
  50% {
    transform: rotate(8deg);
  }
}

.counter-swayer {
  animation: counter-sway 3s infinite ease-in-out;
  transform-origin: center center;
}
@keyframes counter-sway {
  0%,
  100% {
    transform: rotate(8deg);
  }
  50% {
    transform: rotate(-8deg);
  }
}

/* Bottom Marquee */
.marquee-container {
  width: 100%;
  max-width: 100%;
  overflow: hidden;
}

.seamless-window {
  overflow: hidden;
  white-space: nowrap;
  width: 100%;
}
.track {
  display: inline-block;
  animation: scroll-left 12s linear infinite;
}
.track:hover {
  animation-play-state: paused;
}

.track img {
  margin: 5px 0px;
  vertical-align: middle;
  border: 1px solid #240046;
  opacity: 0.9;
  transition: 0.2s;
}
.track img:hover {
  opacity: 1;
  transform: scale(1.1);
  border-color: #7a1cac;
  box-shadow: 0 0 10px #ff00ff;
  cursor: pointer;
  position: relative;
  z-index: 10;
}

@keyframes scroll-left {
  0% {
    transform: translateX(0);
  }
  100% {
    transform: translateX(-50%);
  }
}

/* Media Queries */

@media screen and (max-width: 1300px) {
  html,
  body {
    height: auto;
    overflow-y: auto;
    overflow-x: hidden;
    padding-bottom: 50px;
  }
  
  .container {
    height: 85vh;
  }

  .background_stickers {
    display: none;
  }

  .mobile-nav {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr; /* 3 columns on tablet */
    gap: 10px;
    width: 100%;
    margin-bottom: 20px;
    padding-top: 10px;
  }

  .mobile-nav a {
    background: rgba(255, 255, 255, 0.6);
    border: 2px solid #240046;
    color: #7a1cac;
    padding: 8px;
    text-align: center;
    border-radius: 8px;
    font-size: 14px;
    font-weight: bold;
    transition: 0.2s;
  }
  .mobile-nav a:hover {
    background: var(--accent);
    color: white;
  }
}

@media screen and (max-width: 875px) {
  html,
  body {
    overflow: hidden;
    height: 100vh;
    position: fixed;
  }

  .container {
    flex-direction: column;
    height: 80vh ;
    border-radius: 0;
    margin: 5vh;
    overflow-y: auto ;
    display: block;
  }

  .small,
  .half,
  .main,
  .full {
    width: 100%;
    display: block;
    margin: 0 0 20px 0;
  }

  .information {
    padding-bottom: 30px;
  }

  .retro-box {
    height: 100px;
  }

  .background_stickers,
  .blinkie-grid,
  .button-cluster,
  .marquee-container {
    display: none;
  }

  .main section:nth-child(1),
  .main section:nth-child(2) {
    width: 100%; /* Reset width to full on mobile */
    flex: none;
  }

  .scrolling-text {
    width: 90%;
    font-size: 12px;
  }

  header {
    height: auto;
    min-height: 100px;
  }

  header span {
    font-size: 1.5rem;
    bottom: 0;
  }

  .mobile-nav {
    grid-template-columns: 1fr 1fr;
  }
}
