/* ============================================
   НАВИГАЦИОННОЕ МЕНЮ
   ============================================ */
.site-menu {
  position: relative;
  z-index: var(--z-dropdown);
  margin-bottom: 15px;
  display: flex;
  justify-content: flex-end;
}

.menu-list {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 20px;
}

.menu-link {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  text-decoration: none;
  color: var(--text-dark);
  font-weight: 600;
  font-size: 1rem;
  transition: all var(--transition-base);
  border-radius: 30px;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(5px);
  box-shadow: var(--shadow-sm);
}

.menu-link i {
  font-size: 1.1rem;
  transition: transform var(--transition-base);
}

.menu-link:hover {
  color: #0074d9;
  background: rgba(255, 255, 255, 1);
  box-shadow: 0 4px 12px rgba(0, 116, 217, 0.2);
  transform: translateY(-2px);
}

.menu-link:hover i {
  transform: translateY(-2px);
}

.menu-link.active {
  color: #0074d9;
  background: rgba(0, 116, 217, 0.1);
}

/* ============================================
   КНОПКА ТРЕНЕРА
   ============================================ */
.trainer-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: white;
  font-size: 1rem;
  font-weight: 600;
  margin: 5px 0;
  padding: 10px 20px;
  background: linear-gradient(135deg, #0088cc, #005a8e);
  border-radius: 30px;
  text-decoration: none;
  transition: all var(--transition-base);
  box-shadow: 0 4px 15px rgba(0, 136, 204, 0.4);
  border: 2px solid rgba(255, 255, 255, 0.2);
  position: relative;
  overflow: hidden;
}

.trainer-link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.2),
    transparent
  );
  transition: left 0.5s ease;
}

.trainer-link:hover::before {
  left: 100%;
}

.trainer-link:hover {
  background: linear-gradient(135deg, #005a8e, #003d5c);
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(0, 136, 204, 0.6);
  color: white;
}

/* ============================================
   БЛОК SHORTS
   ============================================ */
.shorts-block {
  position: absolute;
  bottom: 20px;
  left: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: var(--z-dropdown);
  gap: 8px;
}

.shorts-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: 0.9rem;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  margin: 0;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  white-space: nowrap;
}

.shorts-buttons {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: center;
}

.shorts-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: white;
  font-weight: 600;
  font-size: 0.85rem;
  transition: all var(--transition-base);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  position: relative;
  overflow: hidden;
}

.shorts-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s ease;
}

.shorts-btn:hover::before {
  left: 100%;
}

.shorts-btn.rutube {
  background: linear-gradient(135deg, #00bfff, #008080);
}

.shorts-btn.youtube {
  background: linear-gradient(135deg, #ff0000, #cc0000);
}

.shorts-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
  filter: brightness(1.1);
}

/* ============================================
   БЛОК ПРИЛОЖЕНИЙ В ШАПКЕ
   ============================================ */
.apps-block {
  position: absolute;
  bottom: 20px;
  right: 20px;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: var(--z-dropdown);
  gap: 8px;
}

.apps-title {
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: 0.85rem;
  color: white;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
  margin: 0;
  padding: 4px 10px;
  background: rgba(0, 0, 0, 0.2);
  border-radius: 12px;
  white-space: nowrap;
}

.apps-buttons {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: center;
}

.apps-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: white;
  font-weight: 600;
  font-size: 0.8rem;
  transition: all var(--transition-base);
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  border: 2px solid rgba(255, 255, 255, 0.3);
  position: relative;
  overflow: hidden;
  min-width: 75px;
}

.apps-btn::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    90deg,
    transparent,
    rgba(255, 255, 255, 0.3),
    transparent
  );
  transition: left 0.5s ease;
}

.apps-btn:hover::before {
  left: 100%;
}

.apps-btn.apk {
  background: linear-gradient(135deg, #3ddc84, #28a745);
  animation: appPulse 3s ease-in-out infinite;
}

.apps-btn.exe {
  background: linear-gradient(135deg, #0078d4, #005a9e);
}

.apps-btn:hover {
  transform: translateY(-3px) scale(1.05);
  box-shadow: 0 8px 15px rgba(0, 0, 0, 0.3);
  filter: brightness(1.1);
}

@keyframes appPulse {
  0%,
  100% {
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
  }
  50% {
    box-shadow: 0 4px 20px rgba(61, 220, 132, 0.5);
  }
}

/* ============================================
   ЦИФРОВЫЕ ЧАСЫ LEGO
   ============================================ */
.lego-clock {
  position: absolute;
  top: 20px;
  left: 20px;
  font-family: "Montserrat", sans-serif;
  font-weight: 700;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 8px;
  z-index: var(--z-dropdown);
}

.clock-digits {
  display: flex;
  align-items: center;
  gap: 2px;
}

.clock-digit {
  display: inline-block;
  width: 20px;
  height: 28px;
  text-align: center;
  line-height: 28px;
  border-radius: 4px;
  position: relative;
  overflow: hidden;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  animation: digitColorChange 24s infinite;
}

.clock-separator {
  display: inline-block;
  width: 8px;
  height: 28px;
  text-align: center;
  line-height: 28px;
  color: #ffffff;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.5);
  animation:
    blink 1s infinite,
    digitColorChange 24s infinite;
}

@keyframes digitColorChange {
  0% {
    color: #ffffff;
  }
  12.5% {
    color: #001f3f;
  }
  25% {
    color: #0074d9;
  }
  37.5% {
    color: #39cccc;
  }
  50% {
    color: #3d9970;
  }
  62.5% {
    color: #7fdbff;
  }
  75% {
    color: #01ff70;
  }
  87.5% {
    color: #003366;
  }
  100% {
    color: #ffffff;
  }
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.3;
  }
}

/* ============================================
   QR-КОД
   ============================================ */
.qr-code-container {
  position: absolute;
  top: 30px;
  right: 30px;
  width: 120px;
  height: 120px;
  background: rgba(255, 255, 255, 0.95);
  border-radius: var(--radius-lg);
  padding: 8px;
  box-shadow:
    0 10px 30px rgba(0, 0, 0, 0.4),
    0 0 40px rgba(255, 255, 255, 0.6);
  transform: perspective(1000px) rotateY(15deg) translateZ(30px);
  transition: all var(--transition-slow);
  cursor: pointer;
  overflow: hidden;
  z-index: var(--z-default);
  animation: qrFloatSlow 60s ease-in-out infinite;
}

@keyframes qrFloatSlow {
  0% {
    top: 30px;
    right: 30px;
    transform: perspective(1000px) rotateY(15deg) translateZ(30px) rotate(0deg);
  }
  12.5% {
    top: 25px;
    right: calc(50% - 60px);
    transform: perspective(1000px) rotateY(10deg) translateZ(40px) rotate(45deg);
  }
  25% {
    top: 30px;
    right: 20px;
    transform: perspective(1000px) rotateY(20deg) translateZ(35px) rotate(90deg);
  }
  37.5% {
    top: calc(100% - 140px);
    right: calc(50% - 60px);
    transform: perspective(1000px) rotateY(5deg) translateZ(45px) rotate(135deg);
  }
  50% {
    top: calc(100% - 150px);
    right: 30px;
    transform: perspective(1000px) rotateY(15deg) translateZ(30px)
      rotate(180deg);
  }
  62.5% {
    top: calc(100% - 140px);
    right: calc(100% - 150px);
    transform: perspective(1000px) rotateY(25deg) translateZ(35px)
      rotate(225deg);
  }
  75% {
    top: calc(50% - 60px);
    right: calc(100% - 160px);
    transform: perspective(1000px) rotateY(10deg) translateZ(40px)
      rotate(270deg);
  }
  87.5% {
    top: 25px;
    right: calc(100% - 150px);
    transform: perspective(1000px) rotateY(5deg) translateZ(45px) rotate(315deg);
  }
  100% {
    top: 30px;
    right: 30px;
    transform: perspective(1000px) rotateY(15deg) translateZ(30px)
      rotate(360deg);
  }
}

.qr-code {
  width: 100%;
  height: 100%;
  background: url("https://z-cdn-media.chatglm.cn/files/291908e3-1d03-44d2-a82a-d29f516c99ce.png?auth_key=1865830317-13812ba0d8354507a38e320c137a2547-0-a27c0d3115148ac50869baa6f99f6bdf")
    center/contain no-repeat;
  position: relative;
  z-index: 2;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.qr-tooltip {
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 8px 15px;
  border-radius: var(--radius-sm);
  font-size: 0.8rem;
  white-space: nowrap;
  opacity: 0;
  transition: opacity var(--transition-base);
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.qr-code-container:hover .qr-tooltip {
  opacity: 1;
}
