/* 针对iPhone滚动问题的特殊修复 */
@supports (-webkit-touch-callout: none) {
  /* 重置全局设置 */  
  div.container {
    position: relative !important;
    height: auto !important;
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
  }
  
  /* 修复聊天界面滚动 */
  .chatArea {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    height: auto !important;
    padding-bottom: 180px !important; /* 确保底部有足够空间 */
    width: 100% !important;
    max-width: 100vw !important;
  }
  
  /* 确保消息容器可滚动 */
  .messages {
    overflow-y: auto !important;
    -webkit-overflow-scrolling: touch !important;
    width: 100% !important;
  }
  
  /* 修复容器尺寸 */
  .container {
    height: auto !important;
    min-height: calc(100vh - 60px) !important;
    overflow: visible !important;
    width: 100% !important;
    max-width: 100vw !important;
  }
  
  /* 确保输入框位置正确 */
  .inputContainer {
    position: fixed !important;
    bottom: 0 !important;
    left: 0 !important;
    right: 0 !important;
    z-index: 1000 !important;
    background: white !important;
    width: 100% !important;
    max-width: 100vw !important;
  }

  /* 修复侧边栏定位问题 */
  .sidebar {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    height: 100% !important;
    z-index: 2000 !important;
    transform: translateX(-100%) !important;
    -webkit-overflow-scrolling: touch !important;
    overflow-y: auto !important;
  }

  .sidebar.open {
    transform: translateX(0) !important;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.3) !important;
  }
  
} 