/* ================= 全局基础 ================= */
body {
    background: #f7f7fa;
    margin: 0;
}

.header-wrap {
    display: flex;
    max-width: 600px;
    align-items: center;
    justify-content: space-between;
    background: #ff2e7a;
    padding: 8px 12px;
    margin: 0 auto;
}

.header-wrap .logo img {
    height: 50px;
    max-width: 120px;
}

.marquee {
    flex: 1;
    margin-left: 12px;
    background: #fff;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 14px;
    color: #333;
    overflow: hidden;
    white-space: nowrap;
}

.marquee marquee {
    display: block;
    width: 100%;
}

.main-body {
    margin-bottom: 20px;
}

/* =================文字广告================= */
.text-ad-wrap {
    padding: 60px 12px 10px 12px;
    
    max-width: 600px;
    margin: 0 auto;
    box-sizing: border-box;
}

.text-ad-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.text-ad-item {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 8px 2px;
    
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.text-ad-item span {
    margin-right: 4px;
}

/* 消除原本的中间大空白 */
.dingbu {
    margin-top: 0px;
}

.top-links-box {
    display: flex;
    flex-direction: column;
    gap: 8px; /* 保持原参数 */
    padding: 12px 12px 4px 12px; /* 保持原参数 */
    width: 100%;
    margin: 0 auto;
    box-sizing: border-box;
    z-index: 1;
    position: relative;
}

.top-link-item {
    display: block;
    text-align: center;
    background: #fff;
    color: #ff2e7a;
    font-weight: 600;
    
    /* 严格保持您提供的原参数 */
    border: 1.5px solid #ff2e7a; 
    border-radius: 16px;         
    padding: 6px 12px;           
    
    font-size: 15px;
    text-decoration: none;
    box-shadow: 0 1px 4px rgba(0,0,0,0.03);
    transition: all 0.2s ease-in-out;
}

.top-link-item:hover {
    background-color: #ff2e7a;
    color: #fff;
}

/* 分类导航tab */
.tab-nav {
    display: flex;
    justify-content: space-around;
    align-items: center;
    margin: 0px auto;
    width: 100%;
    font-size: 16px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 8px rgba(0,0,0,0.03);
}

.tab-nav div {
    flex: 1;
    text-align: center;
    padding: 8px 0 6px 0;
    color: #333;
    cursor: pointer;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: color 0.15s, border-color 0.15s;
}

.tab-nav .active {
    color: #ff2e7a;
    border-bottom: 2px solid #ff2e7a;
    background: #fff;
}

/* 图标区 */
.icon-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 18px 8px;
    padding: 18px 8px 0 8px;
    width: 100%;
    box-sizing: border-box;
}

.icon-grid .icon-item {
    text-align: center;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.04);
    padding: 0px 0 8px 0;
    transition: box-shadow 0.18s;
}

.icon-grid .icon-item:hover {
    box-shadow: 0 4px 18px rgba(255,46,122,0.10);
}

.icon-grid img {
    width: 62px;
    height: 62px;
    border-radius: 12px;
    display: block;
    margin: 0 auto 8px auto;
    background: #f5f5f5;
}

.icon-grid .icon-title {
    font-size: 15px;
    color: #444;
    margin-top: 4px;
    font-weight: 500;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 横向banner */
.horizontal-ad {
    margin: 12px auto 0 auto;
    width: 100%;
}

/* 下载区 */
.app-download-list {
    padding: 10px 0;
    width: 100%;
    margin: 0 auto 18px auto;
}

.app-download-list a {
    text-decoration: none;
}

.app-download-list .app-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 12px;
    padding: 10px;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.app-download-list .app-info {
    display: flex;
    align-items: center;
}

.app-download-list img {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    margin-right: 10px;
}

.app-download-list .app-name {
    font-weight: bold;
    color: #333;
}

.app-download-list .app-down {
    font-size: 12px;
    color: gray;
}

.app-download-list .app-btn {
    background: #ff2e7a;
    color: #fff;
    padding: 6px 10px;
    border-radius: 20px;
    font-size: 14px;
}

@media (max-width: 600px) {
    .icon-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px 2px;
        padding: 10px 2px 0 2px;
    }
}