/**
 * K4电竞 - 移动端菜单样式
 * 职责：手机端导航菜单（替换"快速选择"按钮）
 * 作用域：仅移动端显示
 */

/* ===== 移动端菜单按钮（替换"快速选择"） ===== */
.mobile-menu-btn {
  display: none; /* 默认隐藏，桌面端不显示 */
  flex-direction: column;
  gap: 4px;
  padding: 8px;
  background: transparent;
  border: none;
  cursor: pointer;
  z-index: 50;
}

.mobile-menu-btn span {
  display: block;
  width: 24px;
  height: 2px;
  background: rgba(229, 231, 235, 0.9);
  transition: all 0.3s ease;
  border-radius: 1px;
}

.mobile-menu-btn:hover span {
  background: rgba(0, 229, 255, 0.8);
}

/* 菜单打开状态 */
.mobile-menu-btn.active span:nth-child(1) {
  transform: rotate(45deg) translate(6px, 6px);
}

.mobile-menu-btn.active span:nth-child(2) {
  opacity: 0;
}

.mobile-menu-btn.active span:nth-child(3) {
  transform: rotate(-45deg) translate(6px, -6px);
}

/* ===== 移动端菜单面板 ===== */
.mobile-menu {
  display: none; /* 默认隐藏 */
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(5, 6, 7, 0.98);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  z-index: 45;
  padding: 80px 20px 20px;
  overflow-y: auto;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.mobile-menu.active {
  display: block;
  opacity: 1;
  visibility: visible;
}

.mobile-menu__content {
  max-width: 100%;
}

.mobile-menu__header {
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.mobile-menu__title {
  font-size: 1.25rem;
  font-weight: 600;
  color: rgba(245, 248, 255, 0.95);
  margin-bottom: 0.5rem;
}

.mobile-menu__subtitle {
  font-size: 0.875rem;
  color: rgba(156, 163, 175, 0.8);
}

.mobile-menu__nav {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.mobile-menu__link {
  display: block;
  padding: 1rem 1.25rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 0.75rem;
  color: rgba(229, 231, 235, 0.9);
  text-decoration: none;
  font-size: 0.9375rem;
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.mobile-menu__link::before {
  content: "";
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(0, 229, 255, 0.1), transparent);
  transition: left 0.5s ease;
}

.mobile-menu__link:hover,
.mobile-menu__link:active {
  background: rgba(255, 255, 255, 0.06);
  border-color: rgba(0, 229, 255, 0.3);
  color: rgba(0, 229, 255, 0.9);
  transform: translateX(4px);
}

.mobile-menu__link:hover::before,
.mobile-menu__link:active::before {
  left: 100%;
}

.mobile-menu__link .hot-badge {
  margin-left: 0.5rem;
}

.mobile-menu__footer {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  text-align: center;
}

.mobile-menu__footer-link {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.1), rgba(74, 245, 255, 0.05));
  border: 1px solid rgba(0, 229, 255, 0.2);
  border-radius: 0.75rem;
  color: rgba(0, 229, 255, 0.9);
  text-decoration: none;
  font-size: 0.9375rem;
  transition: all 0.3s ease;
}

.mobile-menu__footer-link:hover {
  background: linear-gradient(135deg, rgba(0, 229, 255, 0.2), rgba(74, 245, 255, 0.1));
  border-color: rgba(0, 229, 255, 0.4);
  box-shadow: 0 0 20px rgba(0, 229, 255, 0.2);
}

/* ===== 响应式：仅在移动端显示 ===== */
@media (max-width: 767px) {
  .mobile-menu-btn {
    display: flex;
  }
  
  /* 隐藏桌面端的"快速选择"按钮 */
  .desktop-quick-select {
    display: none;
  }
}

/* ===== 桌面端：隐藏移动端菜单 ===== */
@media (min-width: 768px) {
  .mobile-menu {
    display: none !important;
  }
  
  .mobile-menu-btn {
    display: none !important;
  }
}
