/* style.css */

/* 设置页面整体样式（保持正常流，不用 flex！！！） */
body {
  margin: 0;
  padding: 0;

  overflow-x: auto;
  overflow-y: auto;
  min-height: 100%;

  background-image: url('resources/pplstar.gif');
  background-size: 350px 350px;
  background-position: center;
  background-repeat: repeat;
}

/* ⚠️ 把你的 html, body flex 居中删掉，不要加任何 flex！ */

/* 宠物容器（这才是你应该居中的地方） */
.pet-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  min-height: 100vh; /* 保证占满整个屏幕 */
  padding: 20px;
  box-sizing: border-box;
}

/* iframe 宠物框 */
.pet {
  width: 314px;
  height: 321px;
  border: none;
  display: block;
  margin: 0 auto;
}

/* 返回主页 GIF */
.back-gif {
  width: 140px;
  height: auto;
  cursor: pointer;
  margin-top: 10px;
  transition: transform 0.2s;
}

.back-gif:hover {
  transform: scale(1.2);
}


/* 手机端样固定宽度：390px（iPhone 默认宽度） */
@media (max-width: 1000px) {
  body {
    width: 1000px;
    margin: 0 auto;
    padding: 0;
    overflow-x: hidden;
    background-color: #000;
  }

  /* 所有内容的容器——关键！所有元素都必须放进这个容器 */
  .mobile-wrapper {
    width: 420px;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
  }
  
    /* 宠物 */
     .pet {
       align-items: center;      /* 水平居中 */
       justify-content: center;
  }
  
 /* 跳转gif */
  .back-gif {
    width: 100px;  /* 手机端稍大一点 */
    margin-top: 10px;
  }

    
    
}
