@font-face {
  font-family: 'Bitcount Grid Double';
  src: url('fonts/BitcountGridDouble-Regular.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

body {
  margin: 0;
  padding: 40px;
  background: #000;
  color: #fff;
  font-family: 'IBM Plex Mono', monospace;
  transition: none !important;
  overflow-x: hidden;
}

/* Заголовок */
header h1 {
  font-family: 'Bitcount Grid Double', monospace;
  font-size: 86px;
  margin-bottom: 20px;
  animation: blink 4s infinite;
  cursor: pointer;
  background-color: transparent;
}

/* Подсветка заголовка при инвертированных цветах */
body.invert-colors header h1 {
  color: #fff !important;
  background-color: transparent !important;
  text-shadow:
    0 0 10px #fff,
    0 0 20px #fff,
    0 0 30px #fff,
    0 0 40px #fff;
}

/* Анимация мигания */
@keyframes blink {
  0%, 50%, 100% { opacity: 1; }
  25%, 75% { opacity: 0; }
}

/* Меню */
nav ul {
  list-style: none;
  padding: 0;
  margin-bottom: 45px;
}

nav li {
  display: inline;
  margin-right: 20px;
}

nav a {
  color: #800080;
  text-decoration: underline;
  background-color: transparent;
}

nav a:hover,
nav a:visited {
  color: #800080;
}

nav a:active {
  color: red;
}

/* Текст описания */
main p {
  font-size: 13px;
  line-height: 1.3;
  max-width: 700px;
  margin-bottom: 12px;
  background-color: transparent;
}

/* Крестик в углу */
.corner-cross {
  position: fixed;
  bottom: 40px;
  right: 40px;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 80px;
  color: #800080;
  text-decoration: none;
  background-color: transparent;
  z-index: 10;
}

.corner-cross:active {
  color: red;
}

/* Класс для инвертированных цветов */
body.invert-colors {
  color: #fff !important;
  background-color: #000 !important;
}

body.invert-colors * {
  background-color: transparent !important;
  color: #fff !important;
}

body.invert-colors nav a,
body.invert-colors .corner-cross {
  color: #800080 !important;
}

/* Фоновое фото с красным фильтром */
#red-bg-photo {
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  background:
    linear-gradient(rgba(255, 0, 0, 0.75), rgba(255, 0, 0, 0.75)),
    url('/image2.jpg') center center / cover no-repeat;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  z-index: -1;
}

/* Эффект шума поверх фото */
#red-bg-photo::after {
  content: "";
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: repeating-linear-gradient(
      0deg,
      rgba(255, 255, 255, 0.02) 0px,
      rgba(255, 255, 255, 0.02) 1px,
      transparent 1px,
      transparent 2px
  ),
  repeating-linear-gradient(
      90deg,
      rgba(255, 255, 255, 0.02) 0px,
      rgba(255, 255, 255, 0.02) 1px,
      transparent 1px,
      transparent 2px
  );
  mix-blend-mode: overlay;
  opacity: 0.15;
  pointer-events: none;
}

/* Белое свечение под мышью */
#glow-dot {
  position: fixed;
  pointer-events: none;
  width: 0;
  height: 0;
  border-radius: 25%;
  background: transparent;
  box-shadow:
    0 0 10px 10px rgba(255, 255, 255, 0.7),
    0 0 25px 20px rgba(255, 255, 255, 0.5),
    0 0 40px 35px rgba(255, 255, 255, 0.3),
    0 0 60px 55px rgba(255, 255, 255, 0.15),
    0 0 80px 75px rgba(255, 255, 255, 0.07);
  opacity: 0;
  transition: opacity 0.3s ease;
  transform: translate(-50%, -50%);
  z-index: 9999;
}
