/* --- Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Press+Start+2P&display=swap');

body {
  font-family: 'Press Start 2P', monospace;
  background-color: #000;
  background-image: url('/logos/Inet Circuit Pattern Black.svg');
  background-repeat: no-repeat;
  background-size: 200%;
  background-position: center;
  color: white;
  margin: 0;
  padding: 0;
}

/* --- Layout --- */
.homepage-container {
  background: rgba(0, 0, 0, 0.85);
  border: 4px double #d10000;
  box-shadow: 0 0 15px #d10000;
  padding: 3rem 2rem;
  margin: 4rem auto;
  max-width: 600px;
  text-align: center;
  position: relative;
  overflow: hidden;
  animation: crtFlicker 1.5s infinite;
}

.homepage-container::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-image: repeating-linear-gradient(
    to bottom,
    rgba(255, 255, 255, 0.03),
    rgba(255, 255, 255, 0.03) 1px,
    transparent 1px,
    transparent 3px
  );
  pointer-events: none;
  z-index: 5;
  mix-blend-mode: overlay;
}

@keyframes crtFlicker {
  0% { opacity: 1; }
  50% { opacity: 0.97; }
  100% { opacity: 1; }
}

.logo {
  width: 300px;
  max-width: 80%;
  margin-bottom: 2rem;
}

.logo-small {
  width: 300px;
  max-width: 80%;
  margin-bottom: 2rem;
}

h1 {
  font-size: 2rem;
  color: #d10000;
  margin-bottom: 1.5rem;
}

.tagline {
  font-size: 0.8rem;
  margin-bottom: 2rem;
  color: #ccc;
}

/* --- Buttons --- */
.game-buttons {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  width: 100%;
  max-width: 400px;
  margin: 0 auto;
}

.game-button {
  background-color: #d10000;
  color: white;
  padding: 1rem;
  text-decoration: none;
  font-size: 1rem;
  border-radius: 8px;
  transition: all 0.2s ease-in-out;
  box-shadow: 0 0 10px #d10000;
}


.game-button:hover {
  background-color: #d10000;
  color: black;
  transform: scale(1.05);
  cursor: pointer;
  box-shadow: 0 0 20px #ff1a1a;
}


/* --- Nickname Form --- */
.nickname-form {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  margin-top: 2rem;
}

.nickname-form input {
  padding: 0.5rem;
  font-size: 1rem;
  width: 250px;
  border: 2px solid #d10000;
  background-color: #111;
  color: white;
  text-align: center;
}

.nickname-form input:focus {
  outline: none;
  box-shadow: 0 0 8px #d10000;
  border-color: #d10000;
}

.nickname-form button {
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  background-color: #ff1a1a;
  border: none;
  color: black;
  font-weight: bold;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.nickname-form button:hover {
  background-color: #e60000;
}

/* --- Footer --- */
.site-footer {
  text-align: center;
  padding: 2rem 1rem;
  font-size: 0.75rem;
  color: #777;
}

/* --- Guessing Game --- */
.guessing-container {
  max-width: 600px;
  margin: 4rem auto;
  text-align: center;
  padding: 1rem;
}

.guessing-container .tagline {
  font-size: 1.25rem;
  margin-bottom: 2rem;
  color: #ccc;
}

.guess-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  margin-bottom: 2rem;
}

.guess-form input {
  padding: 0.75rem;
  font-size: 1rem;
  border: 2px solid #d10000;
  background-color: #111;
  color: white;
  text-align: center;
}

.guess-form input:focus {
  outline: none;
  box-shadow: 0 0 8px #d10000;
  border-color: #d10000;
}

.guess-form button {
  background-color: #d10000;
  color: black;
  font-weight: bold;
  padding: 0.75rem;
  border: none;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.guess-form button:hover {
  background-color: #e60000;
}

.note {
  font-size: 0.85rem;
  color: #888;
}
.alert-box {
  margin-top: 1rem;
  padding: 1rem;
  font-size: 0.85rem;
  border-radius: 6px;
  text-align: center;
  font-weight: bold;
  position: relative;
  opacity: 0;
  transform: scale(0.95);
  transition: opacity 0.3s ease, transform 0.3s ease;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
}

.alert-box.show {
  opacity: 1;
  transform: scale(1);
}

.alert-box.hidden {
  display: none;
}

.alert-success {
  background-color: #00cc66;
  color: black;
  box-shadow: 0 0 8px #00cc66;
}

.alert-error {
  background-color: #ff0033;
  color: white;
  box-shadow: 0 0 8px #ff0033;
}

.alert-close {
  position: absolute;
  right: 10px;
  top: 5px;
  font-size: 1.2rem;
  cursor: pointer;
  user-select: none;
}

/* --- Guess History --- */
.guess-history {
  margin-top: 2rem;
  padding: 1rem;
  background-color: #111;
  border: 2px dashed #d10000;
  font-size: 0.75rem;
  color: #ccc;
  max-width: 500px;
  margin-left: auto;
  margin-right: auto;
  border-radius: 6px;
  box-shadow: 0 0 6px #d10000;
}

.guess-entry {
  margin-bottom: 0.5rem;
}
.hidden {
  display: none !important;
}
