/* ==========================================
   手机端导航强制修复 - 独立文件
   必须在 tooplate-graphite-creative.css 之后加载
   ========================================== */
@media (max-width: 768px) {
  /* 强制显示汉堡按钮 */
  .menu-toggle {
    display: flex !important;
    flex-direction: column !important;
    justify-content: center !important;
    align-items: center !important;
    gap: 5px !important;
    width: 44px !important;
    height: 44px !important;
    cursor: pointer !important;
    background: none !important;
    border: none !important;
    padding: 8px !important;
    z-index: 10001 !important;
    position: relative !important;
  }

  .menu-toggle span {
    display: block !important;
    width: 24px !important;
    height: 2px !important;
    background-color: #2f2a24 !important;
    border-radius: 1px !important;
    transition: all 0.3s ease !important;
  }

  /* 汉堡按钮动画 */
  .menu-toggle.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px) !important;
  }
  .menu-toggle.active span:nth-child(2) {
    opacity: 0 !important;
  }
  .menu-toggle.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px) !important;
  }

  /* header 布局 */
  header {
    display: flex !important;
    flex-direction: row !important;
    align-items: center !important;
    justify-content: space-between !important;
    height: auto !important;
    min-height: 50px !important;
    padding: 8px 12px !important;
    position: relative !important;
  }

  .header-container {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    flex-wrap: nowrap !important;
  }

  /* 导航菜单默认隐藏 */
  nav {
    display: none !important;
    position: absolute !important;
    top: 100% !important;
    right: 8px !important;
    left: auto !important;
    background: #3e342c !important;
    flex-direction: column !important;
    padding: 8px !important;
    gap: 4px !important;
    border-radius: 8px !important;
    border: 1px solid #6e6050 !important;
    max-height: calc(100vh - 80px) !important;
    overflow-y: auto !important;
    z-index: 10000 !important;
    min-width: 160px !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.3) !important;
    width: auto !important;
  }

  /* 菜单展开时显示 */
  nav.active {
    display: flex !important;
  }

  /* 导航链接样式 */
  nav a {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    min-width: 140px !important;
    height: 40px !important;
    padding: 0 14px !important;
    font-size: 14px !important;
    color: #f5efe2 !important;
    background: rgba(255,248,237,0.1) !important;
    border: 1px solid rgba(176,138,87,0.3) !important;
    border-radius: 6px !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    clip-path: none !important;
    transform: none !important;
    flex-shrink: 0 !important;
  }

  nav a:hover,
  nav a.active {
    background: rgba(255,250,242,0.2) !important;
    color: #f5efe2 !important;
  }

  /* 搜索按钮隐藏或缩小 */
  .nav-search-btn {
    display: none !important;
  }
}
