* {
  margin: 0;
  padding: 0;
  -webkit-tap-highlight-color: transparent;
}
a {
  text-decoration: none;
}
#answer {
  background: linear-gradient(45deg, #FFECED, #FFEFEE, #FEEDEC);
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  height: 100%;
  width: 100%;
  overflow-x: hidden;
  /* -webkit-overflow-scrolling: auto;
  overflow-scrolling: auto; */
  border: 1px solid #FFA8AC;
  box-sizing: border-box;
}
header img {
  height: 0.6rem;
  display: block;
  margin: 0.2rem 0 0 0.3rem;
}
header aside {
  display: block;
  position: absolute;
  border-radius: 0.23rem;
  background: #FF3081;
  top: 0.25rem;
  right: 0.3rem;
  border: 0.02rem solid white;
  color: white;
  font-size: 0.26rem;
  text-align: center;
  width: 1.6rem;
  line-height: 0.45rem;
  z-index: 33;
}
.main {
  padding: 0.6rem 0 0 0;
}
.main h1 {
  text-align: center;
}
.main h1 img {
  width: 4.65rem;
  display: block;
  margin: 0.2rem auto 0.4rem;
}
.main section {
  margin: 1rem auto 0;
  width: 6.25rem;
  position: relative;
}
.main section div {
  width: 100%;
  height: 2rem;
  border: 0.02rem solid #DB505B;
  border-radius: 0.2rem;
  background: white;
  position: relative;
}
.main section div:before {
  position: absolute;
  content: '';
  width: 100%;
  height: 100%;
  left: 0;
  top: 0;
  border: 0.02rem solid #DB505B;
  border-radius: 0.2rem;
  background: #FAC5CA;
  transform: rotate(5deg);
  z-index: -1;
}
.main section div h5 {
  font-weight: normal;
  position: absolute;
  display: inline-block;
  font-size: 0.3rem;
  border: 0.02rem solid #EE4459;
  line-height: 0.5rem;
  width: 1rem;
  top: -0.25rem;
  left: calc(50% - .5rem);
  border-radius: 0.3rem;
  text-align: center;
  background: #FFFFFF;
}
.main section div h5 span {
  color: #ED4156;
}
.main section div h5 .totalNo {
  color: black;
}
.main section div p {
  font-size: 0.36rem;
  margin-top: 0.7rem;
  padding: 0 0.4rem;
  display: flex;
  box-sizing: border-box;
}
.main section div p b {
  margin-right: 0.1rem;
  margin-top: 0.02rem;
}
.main section div p span {
  font-size: 0.32rem;
  font-weight: 600;
}
.main section ul {
  padding: 0.35rem 0;
  list-style: none;
}
.main section ul li {
  font-size: 0.36rem;
  margin-bottom: 0.2rem;
  border: 0.02rem solid #EE4459;
  border-radius: 0.15rem;
  background: white;
  padding: 0.15rem 0.12rem;
  box-sizing: border-box;
  position: relative;
  display: flex;
}
.main section ul li:before {
  position: absolute;
  content: '';
  left: -0.02rem;
  top: 0.1rem;
  z-index: -1;
  width: 100%;
  height: 100%;
  border: 0.02rem solid #EE4459;
  border-radius: 0.2rem;
  background: white;
  background-image: url("../img/lineBg.png");
}
.main section ul li c {
  margin-right: 0.15rem;
  margin-top: 0.02rem;
}
.main section ul li a {
  font-size: 0.35rem;
  margin-left: 0.15rem;
  color: black;
}
.main section ul li.on {
  background: #FF748B;
  color: white;
}
.main section ul li.on a {
  color: white;
}
.main section > p.change {
  width: 4.2rem;
  display: block;
  margin: 0 auto;
  text-align: center;
  box-sizing: border-box;
  position: relative;
}
.main section > p.change img {
  margin: 0 auto;
  width: 100%;
  height: 100%;
}
.main section > p.change.fullfill .fullfillImg {
  display: block;
}
.main section > p.change.fullfill .nextImg {
  display: none;
}
.main section > p.change.next .nextImg {
  display: block;
}
.main section > p.change.next .fullfillImg {
  display: none;
}
.main section img.heart {
  position: absolute;
  width: 0.8rem;
  top: -1rem;
  left: 0.3rem;
}
.main section img.lover {
  position: absolute;
  height: 1.5rem;
  top: -1.5rem;
  right: 0.3rem;
}
.main section img.lover2 {
  display: none;
}
.main section.over img.heart {
  left: 25%;
  top: -0.8rem;
  transition: all 0.6s;
}
.main section.over img.lover1 {
  display: none;
}
.main section.over img.lover2 {
  display: block;
}
.ce {
  display: none;
  padding: 0 0.3rem 0;
  box-sizing: border-box;
  position: relative;
  height: 100%;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.ce .show {
  /* opacity: 0; 删除这行 */
  position: fixed;
  left: 0;
  padding: 0 0.3rem 0;
  box-sizing: border-box;
  right: 0;
  top: 0;
  bottom: 0;
  z-index: 100;
}
.ce .show > div {
  width: 100%;
  background: url("../img/ceBg.png") no-repeat;
  background-size: 100% 100%;
  border-radius: 0.2rem;
  margin-top: 0.8rem;
  position: relative;
  padding: 0.5rem 0.5rem 0.8rem;
  box-sizing: border-box;
}
.ce .show > div h5 {
  width: 2.6rem;
  height: 0.5rem;
  line-height: 0.5rem;
  border-radius: 0.25rem;
  border: 0.02rem solid black;
  display: block;
  position: absolute;
  top: -0.25rem;
  color: #B50029;
  text-align: center;
  font-size: 0.29rem;
  left: calc(50% - 1.3rem);
  background: white;
}
.ce .show > div h5 img {
  width: 0.35rem;
  vertical-align: -0.08rem;
}
.ce .show > div h6 {
  text-align: center;
  margin-top: 0.3rem;
  border-bottom: 0.02rem dashed #DC515C;
}
.ce .show > div h6 img {
  width: 2.9rem;
}
.ce .show > div .levelCe > img.header {
  width: 0.9rem;
  height: 0.9rem;
  display: block;
  margin: 0.2rem auto;
  border-radius: 50%;
  border: 1px solid #666666;
}
.ce .show > div .levelCe > img.code {
  width: 2.1rem;
  height: 2.1rem;
  display: block;
  margin: 0.4rem auto 0.15rem;
}
.ce .show > div .levelCe p {
  font-size: 0.3rem;
  line-height: 0.55rem;
}
.ce .show > div .levelCe p.testResult {
  font-size: 0.28rem;
  line-height: 0.4rem;
  margin-top: 0.1rem;
}
.ce .show > div .levelCe p:nth-of-type(1) span img {
  width: 0.34rem;
  vertical-align: -0.04rem;
}
.ce .show > div .levelCe p:nth-of-type(2) span {
  font-size: 0.4rem;
  color: #ED3F54;
}
.ce .show > div .levelCe p:nth-last-of-type(1) {
  text-align: center;
}
.ce .show > div .levelCe > .bl1 {
  position: absolute;
  left: 0;
  top: 1.35rem;
  width: 0.6rem;
  height: 0.4rem;
}
.ce .show > div .levelCe > .bl2 {
  position: absolute;
  left: 5.45rem;
  top: 6.2rem;
  width: 0.6rem;
  height: 0.4rem;
}
.ce .show > div .levelCe > .heart1 {
  position: absolute;
  left: 5rem;
  top: 1.8rem;
  width: 0.7rem;
  height: auto;
}
.ce .show > div .levelCe > .heart2 {
  position: absolute;
  left: 0.5rem;
  top: calc(100% - 1.2rem);
  width: 0.8rem;
  height: auto;
}
.ce > div {
  width: 100%;
  background: url("../img/ceBg.png") no-repeat;
  background-size: 100% 100%;
  border-radius: 0.2rem;
  margin-top: 0.4rem;
  position: relative;
  padding: 0.5rem 0.5rem 0.8rem;
  box-sizing: border-box;
}
.ce > div h5 {
  width: 2.6rem;
  height: 0.5rem;
  line-height: 0.5rem;
  border-radius: 0.25rem;
  border: 0.02rem solid black;
  display: block;
  position: absolute;
  top: -0.25rem;
  color: #B50029;
  text-align: center;
  font-size: 0.29rem;
  left: calc(50% - 1.3rem);
  background: white;
}
.ce > div h5 img {
  width: 0.35rem;
  vertical-align: -0.08rem;
}
.ce > div h6 {
  text-align: center;
  margin-top: 0.3rem;
  border-bottom: 0.02rem dashed #DC515C;
}
.ce > div h6 img {
  width: 2.9rem;
}
.ce > div .levelCe > img.header {
  width: 0.9rem;
  height: 0.9rem;
  display: block;
  margin: 0.2rem auto;
  border-radius: 50%;
}
.ce > div .levelCe > img.code {
  width: 2.1rem;
  height: 2.1rem;
  display: block;
  margin: 0.7rem auto 0.15rem;
}
.ce > div .levelCe p {
  font-size: 0.3rem;
  line-height: 0.55rem;
}
.ce > div .levelCe p.testResult {
  font-size: 0.28rem;
  line-height: 0.4rem;
  margin-top: 0.1rem;
}
.ce > div .levelCe p:nth-of-type(1) span img {
  width: 0.34rem;
  vertical-align: -0.04rem;
}
.ce > div .levelCe p:nth-of-type(2) span {
  font-size: 0.4rem;
  color: #ED3F54;
}
.ce > div .levelCe p:nth-last-of-type(1) {
  text-align: center;
}
.ce > div .levelCe > .bl1 {
  position: absolute;
  left: 0;
  top: 1.35rem;
  width: 0.6rem;
  height: 0.4rem;
}
.ce > div .levelCe > .bl2 {
  position: absolute;
  left: 5.45rem;
  top: 6.2rem;
  width: 0.6rem;
  height: 0.4rem;
}
.ce > div .levelCe > .heart1 {
  position: absolute;
  left: 5rem;
  top: 1.8rem;
  width: 0.7rem;
  height: auto;
}
.ce > div .levelCe > .heart2 {
  position: absolute;
  left: 0.5rem;
  top: calc(100% - 1.2rem);
  width: 0.8rem;
  height: auto;
}
.pressSave {
  width: 100%;
  text-align: center;
  font-size: 0.28rem;
  position: relative;
  z-index: 24;
  margin-top: -0.8rem;
  color: #FD6B84;
  display: none;
}
.tip {
  position: fixed;
  width: 4rem;
  height: 1rem;
  line-height: 1rem;
  left: calc(50% - 2rem);
  top: calc(50% - .5rem);
  border-radius: 0.1rem;
  display: none;
  background: rgba(0, 0, 0, 0.5);
}
.tip a {
  font-size: 0.32rem;
  display: block;
  text-align: center;
  color: white;
}
#index {
  position: fixed;
  left: 0;
  top: 0;
  right: 0;
  bottom: 0;
  /* border: 1px solid #FFA8AC; */
  overflow-y: hidden;
  background: linear-gradient(to bottom, #FBEAEA, #FBEAEA, #FBEAEA);
}
#index img.bg {
  width: 100%;
}
#index .btn-group {
  z-index: 22;
  width: 4.5rem;
  margin: -1rem auto;
}
#index .btn-group a {
  display: block;
}
#index .btn-group a img {
  width: 100%;
}
#index .btn-group a.reward {
  margin: -0.5rem 0.9rem 0;
}

/* =========================================
   【最终完美版】大屏适配 (Surface Duo, iPad, PC)
   ========================================= */
@media screen and (min-width: 500px) {
    
    /* 1. 开启原生滚动，并修补底部白边 */
    html {
        font-size: 60px !important;    
        overflow-y: scroll !important; 
        height: auto !important;
        /* 【关键修复】给浏览器底层加粉色背景，彻底消灭底部白边 */
        background-color: #FBEAEA !important; 
    }

    /* 2. 让 body 自适应 */
    body {
        overflow: visible !important;
        height: auto !important;
        background: none !important;   
    }

    /* 3. 解除 #index 固定定位 */
    #index {
        position: relative !important;  
        height: auto !important;        
        min-height: 100vh;              
        overflow: visible !important;   
        
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
        margin: 0 !important;
        max-width: none !important;     
        
        transform: none !important;     
    }

    /* 4. 修复弹窗居中 */
    .rewardWindow section, 
    .ruleWindow section {
        position: fixed !important; 
        top: 50% !important;
        left: 50% !important;
        transform: translate(-50%, -50%);
        margin: 0 !important;
    }
    
}

    /* --- 适配移动端 H5 的转盘样式 (修正版) --- */
    .wheel-wrapper {
        margin: 0.2rem auto 0; /* 增加顶部间距 */
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        position: relative;
        z-index: 200; /* 提高层级 */
        width: 100%;
    }
    
    .wheel-container { 
        position: relative; 
        /* 放大转盘容器，使其更清晰 */
        width: 5.5rem;  
        height: 5.5rem; 
        margin: 0 auto; 
    }
    
    #wheel { 
        width: 100%; 
        height: 100%; 
        border-radius: 50%; 
        /* 加上白色边框让它更像一个贴纸 */
        border: 0.1rem solid #fff;
        box-shadow: 0 0.1rem 0.3rem rgba(0, 0, 0, 0.2); 
        background-color: #fff;
    }
    
    /* 指针样式 (居中) */
    .pointer {
        position: absolute;
        top: 50%;
        left: 50%;
        transform: translate(-50%, -50%);
        width: 0.8rem;
        height: 0.8rem;
        z-index: 201;
    }
    /* 中心圆点 */
    .pointer::before {
        content: '';
        position: absolute;
        top: 0; left: 0; right: 0; bottom: 0;
        background: #ff5722;
        border-radius: 50%;
        border: 0.05rem solid #fff;
        box-shadow: 0 0 0.1rem rgba(0,0,0,0.3);
    }
    /* 向上箭头 */
    .pointer::after {
        content: '';
        position: absolute;
        top: -0.5rem; /* 向上偏移 */
        left: 50%;
        transform: translateX(-50%);
        border-left: 0.25rem solid transparent;
        border-right: 0.25rem solid transparent;
        border-bottom: 0.7rem solid #ff5722;
    }

    /* 抽奖按钮 */
    .spin-btn {
        background: linear-gradient(to bottom, #ff8a00, #e52e71); 
        color: white; 
        border: 0.04rem solid #fff;
        padding: 0.15rem 0.6rem; 
        font-size: 0.32rem; 
        border-radius: 50px; 
        cursor: pointer;
        box-shadow: 0 0.1rem 0.2rem rgba(0, 0, 0, 0.3); 
        margin-top: 0.3rem;
        outline: none;
        font-weight: bold;
        letter-spacing: 1px;
    }
    .spin-btn:active { transform: translateY(2px); }
    .spin-btn:disabled { background: #ccc; cursor: default; }

    
    /* 确保弹窗样式正确 (防止 answer.css 没覆盖到) */
.rewardWindow {
        position: fixed;
        display: none;
        left: 0;
        top: 0;
        right: 0;
        bottom: 0;
        z-index: 999; /* 提高层级，确保覆盖转盘 */
        background: rgba(0, 0, 0, 0.5);
    }
    .rewardWindow section {
        width: 6.4rem;
        max-height: 7rem;
        border: 0.02rem solid #DC535E;
        border-radius: 0.2rem;
        background: #FAC5CA;
        position: absolute;
        left: 50%;
        top: 50%;
        transform: translate(-50%, -50%); /* 居中定位 */
        padding: 0.5rem;
        box-sizing: border-box;
    }
    /* 粉色倾斜背景层 */
    .rewardWindow section:before {
        position: absolute;
        content: '';
        width: 100%;
        height: 100%;
        left: 0;
        top: 0;
        border: 0.02rem solid #DC535E;
        border-radius: 0.2rem;
        background: white;
        transform: rotate(355deg);
        z-index: -1;
    }
    .rewardWindow section h6 {
        text-align: center;
        border-bottom: 0.02rem dashed #DC535E;
        /* margin-bottom: 0.3rem; */
        position: relative;
    }
    .rewardWindow section h6 img.title {
        height: 1rem;
        display: inline-block; /* 修复可能得不到宽度的问题 */
    }
    .rewardWindow section h6 img.heart {
        height: 0.5rem;
        position: absolute;
        right: 0;
        top: 0;
    }
    .rewardWindow section ul {
        list-style: none;
        max-height: 3.5rem;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
        padding: 0; /* 清除默认padding */
    }
    .rewardWindow section ul li {
        border-bottom: 1px dashed #e4e4e4;
        padding: 0.1rem 0.3rem;
        font-size: 0.28rem;
        color: #333;
        display: flex;
        justify-content: space-between;
    }

    /* --- 评价区域包裹层 --- */
    .result-wrapper {
        position: relative; /* 关键：作为定位基准 */
        width: 100%;
        min-height: 1.2rem; /* 稍微加高一点，给爱心留位置 */
        display: flex;
        align-items: center;     /* 文字垂直居中 */
        justify-content: center; /* 文字水平居中 */
        margin-top: 0.2rem;
        /* 【关键】右边多留点空隙给爱心，防止文字重叠 */
        padding: 0.1rem 0.8rem 0.1rem 0.2rem; 
        box-sizing: border-box;
    }

    /* 评价文字 */
    .testResult {
        flex: 1;
        text-align: center;
        margin: 0 !important;
        z-index: 10;
        /* 如果文字太多，允许换行 */
        white-space: normal;
        word-break: break-all;
    }

    /* --- 爱心样式 (固定在右上角) --- */
    .result-wrapper .heart1 {
        position: absolute !important;
        /* 【关键】靠右定位 */
        right: 0 !important;       
        /* 【关键】靠上定位 (可微调这个数值，比如 -0.1rem 让它稍微探出头) */
        top: 0 !important;         
        
        left: auto !important;     /* 覆盖掉原来的 left: 5rem */
        transform: none !important;/* 清除居中偏移 */
        
        width: 0.7rem !important;  /* 保持原大小 */
        height: auto !important;
        display: block !important;
        z-index: 11;
    }

    /* 让列表项变为垂直布局 */
.rewardList li {
    height: auto; /* 取消固定高度，改为自适应 */
    padding: 10px;
    flex-direction: column; /* 如果原来是 flex 布局，这行很重要 */
    display: block; /* 或者用 block 确保换行 */
}

/* 原有的第一行样式调整 */
.top-row {
    display: flex;
    justify-content: space-between; /* 奖品在左，VIP在右 */
    margin-bottom: 5px;
}

/* 1. 外层容器：改为横向排列 */
.extra-info {
    background-color: #f8f8f8;
    padding: 1px;
    border-radius: 6px;
    /* margin-top: 8px; */
    
    /* --- 布局核心 --- */
    display: flex;
    flex-direction: row;    /* 【关键】横向排列：左边是图，右边是文 */
    align-items: center;    /* 垂直居中：让图片和文字在垂直方向对齐 */
    justify-content: flex-start; /* 内容从左开始 */
}

/* 2. 图片样式：左侧展示，固定宽度，防止被挤压 */
.extra-info .info-img {
    width: 80px;            /* 根据需要调整图片大小，建议 60px-80px */
    height: auto;           /* 保持比例 */
    border-radius: 4px;
    
    /* --- 间距调整 --- */
    margin-right: 12px;     /* 【关键】图片右边加间距，把文字推开 */
    margin-bottom: 0;       /* 去掉之前的底部间距 */
    
    flex-shrink: 0;         /* 【保险】防止文字太长时把图片挤扁 */
}

/* 3. 文案样式：右侧展示，自动填充剩余空间 */
.extra-info .info-text {
    font-size: 12px;
    color: #666;
    margin: 0;
    
    /* --- 对齐调整 --- */
    text-align: left;       /* 文字左对齐 */
    line-height: 1.4;
    flex: 1;                /* 【关键】让文字占据右侧所有剩余宽度 */
}

/* ========================================
   完美解决方案：独立的 extra-info 样式
   ======================================== */

/* 1. 弹窗容器 - 无需改变 */
.rewardWindow section {
    width: 6.4rem;
    max-height: 10rem; /* 稍微增加一点 */
    /* 其他样式保持不变 */
}

/* 2. 列表样式 - 保持简洁 */
.rewardWindow section ul {
    list-style: none;
    max-height: 2.5rem; /* 减小列表高度，给下方信息块留空间 */
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    padding: 0;
    margin-bottom: 0.05rem; /* 与下方信息块的间距 */
}

.rewardWindow section ul li {
    border-bottom: 1px dashed #e4e4e4;
    padding: 0.05rem 0.3rem;
    font-size: 0.3rem;
    color: #333;
}

.rewardWindow section ul li a {
    color: #DB1422;
    font-weight: 1000;
    display: block; /* 确保完整显示 */
}

/* VIP 编号样式 - 在奖品名右侧 */
.rewardWindow section ul li a .vip-code {
    color: #000000;
    font-size: 0.26rem;
    font-weight: 700;
    margin-left: 0.1rem; /* 与奖品名之间的小间距 */
}

/* 3. 独立的信息块 - 不在列表内，完美显示 */
.extra-info-independent {
    background-color: #fff5f6;
    padding: 0.25rem;
    border-radius: 0.15rem;
    border: 1px solid #ffe0e3;
    margin: 0 0 0.3rem 0;
    
    display: flex;
    flex-direction: column; /* ← 改这里 */
    align-items: stretch; /* ← 改这里 */
    gap: 0.25rem;
    
    width: 100%;
    box-sizing: border-box;
}

/* 顶部内容：左列（图片+按钮）和右列（文字） */
.extra-info-independent .top-content {
    display: flex;
    flex-direction: row; /* 横向排列 */
    align-items: flex-start; /* 顶部对齐 */
    gap: 0.1rem; /* 左右两列之间的间距 */
    width: 100%;
}

/* 左侧列：包含图片和按钮 */
.extra-info-independent .top-content .left-column {
    display: flex;
    flex-direction: column; /* 垂直排列 */
    align-items: center; /* 让图片和按钮居中对齐 */
    gap: 0.1rem; /* 图片和按钮之间的间距 */
    flex-shrink: 0; /* 防止被文字挤压 */
}

/* 按钮图片样式 - 控制大小 */
.extra-info-independent .top-content .left-column .btn-img {
    width: 100%; /* 宽度与图片一致（占满左侧列） */
    max-width: 2rem; /* 最大宽度限制，与上方图片一致 */
    height: auto; /* 高度自动，保持图片比例 */
    display: block; /* 作为块级元素显示 */
    margin: 0; /* 移除默认边距 */
    border-radius: 0.1rem; /* 可选：圆角 */
    cursor: pointer; /* 鼠标悬停时显示手型 */
}

/* 4. 图片样式 - 保持原有大小 */
.extra-info-independent .info-img {
    width: 2.1rem; /* 约130px，清晰可见 */
    height: auto;
    object-fit: cover;
    border-radius: 0.1rem;
    border: 2px solid #ffcdd2;
    box-shadow: 0 2px 8px rgba(219, 20, 34, 0.1);
}

/* 5. 文字样式 - 保持原有大小 */
.extra-info-independent .top-content .info-text {
    flex: 1;
    font-size: 0.25rem; /* 约24px，适中大小 */
    color: #333;
    line-height: 1.7;
    margin: 0;
    text-align: left;
    word-break: break-word;
}

/* 底部横跨整行的文字 */
.extra-info-independent .bottom-text {
    width: 100%;
    font-size: 0.24rem; /* 可以根据需要调整 */
    color: #DB1422; /* 可以用不同颜色突出显示 */
    line-height: 1.5;
    margin: 0;
    padding-top: 0.15rem; /* 与上方内容的间距 */
    text-align: center; /* 居中显示，也可以改为 left */
    border-top: 1px dashed #ffe0e3; /* 可选：添加分隔线 */
}

/* 6. 隐藏列表滚动条（可选） */
.rewardWindow section ul::-webkit-scrollbar {
    width: 0; /* 完全隐藏 */
}

/* 7. 移动端响应式 */
@media screen and (max-width: 500px) {
    .extra-info-independent .info-img {
        width: 2rem;
        height: auto;
    }
    
    .extra-info-independent .info-text {
        font-size: 0.26rem;
    }
}

/* 8. 大屏优化 */
@media screen and (min-width: 500px) {
    .rewardWindow section {
        width: 7rem;
    }
    
    .extra-info-independent .info-img {
        width: 3rem;
        height: auto;
    }
    
    .extra-info-independent .info-text {
        font-size: 0.28rem;
    }
}

/* =========================================
   移动端滚动修复 + 防止横向溢出 (< 500px)
   ========================================= */
@media screen and (max-width: 499px) {
    /* 1. 控制 html 和 body 宽度,防止溢出 */
    html {
        height: auto !important;
        min-height: 100vh;
        overflow-y: auto !important;
        overflow-x: hidden !important; /* 禁止横向滚动 */
        width: 100%;
        -webkit-overflow-scrolling: touch;
    }

    body {
        height: auto !important;
        min-height: 100vh;
        overflow-y: auto !important;
        overflow-x: hidden !important; /* 禁止横向滚动 */
        width: 100%;
        margin: 0;
        padding: 0;
    }

    /* 2. 解除 #index 的固定定位 */
    #index {
        position: relative !important;
        height: auto !important;
        min-height: 100vh;
        overflow-x: hidden !important; /* 禁止横向滚动 */
        overflow-y: visible !important;
        width: 100%;
        max-width: 100vw; /* 限制最大宽度为视口宽度 */
        
        /* 清除固定定位的位置属性 */
        top: auto !important;
        left: auto !important;
        right: auto !important;
        bottom: auto !important;
    }

    /* 3. 确保背景图不会溢出 */
    #index img.bg {
        width: 100%;
        max-width: 100%;
        display: block;
        position: relative;
        height: auto;
    }

    /* 4. 按钮组调整 */
    #index .btn-group {
        position: relative;
        z-index: 10;
        margin: -1rem auto 0;
        max-width: 90%; /* 防止按钮过宽 */
    }

    /* 5. Footer 宽度和内容控制 */
    #footer {
        position: relative;
        width: 100%;
        max-width: 100vw;
        overflow: hidden; /* 防止内容溢出 */
        box-sizing: border-box;
        padding: 20px 15px 30px; /* 减少左右padding */
    }

    #footer .inner {
        width: 100%;
        max-width: 100%;
        box-sizing: border-box;
    }

    /* 6. Footer 文字换行控制 */
    #footer .info li {
        font-size: 11px !important; /* 缩小字体 */
        line-height: 1.5;
        word-wrap: break-word; /* 强制换行 */
        word-break: break-word; /* 单词内断行 */
        white-space: normal; /* 允许换行 */
        overflow-wrap: break-word;
        margin-bottom: 5px;
    }

    #footer .info li:first-child {
        font-size: 13px !important;
    }

    /* 7. Footer 社交媒体图标调整 */
    #footer .sns ul {
        gap: 12px; /* 减小间距 */
        flex-wrap: wrap;
        justify-content: center;
    }

    #footer .sns li img.large-icon {
        width: 18px; /* 缩小图标 */
        height: 18px;
    }

    /* 8. 确保所有容器不溢出 */
    * {
        max-width: 100%;
        box-sizing: border-box;
    }
}