/* ========== 移动端全局样式 ========== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body {
    background-color: #f5f7fb;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    font-size: 14px;
    line-height: 1.5;
    color: #1e2a3a;
    padding-bottom: 20px;
}

.mobile-container {
    max-width: 640px;
    margin: 0 auto;
    background-color: #f5f7fb;
}

/* 顶部导航（固定网格） */
.nav-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px 8px;
    background: #fff;
    margin: 12px 16px;
    padding: 12px 8px;
    border-radius: 24px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}
.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    padding: 8px 4px;
    border-radius: 16px;
    transition: all 0.2s;
}
.nav-item img {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 24px;
    background: #f0f2f5;
    margin-bottom: 6px;
}
.nav-item span {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 500;
    text-align: center;
}
.nav-item:active {
    background: #f0f2f5;
    transform: scale(0.96);
}

/* 通用标题 */
.section-title {
    font-size: 20px;
    font-weight: 700;
    padding-left: 16px;
    margin: 20px 0 12px;
    border-left: 4px solid #3b82f6;
    color: #1e293b;
}

/* ========== 热门院校推荐 ========== */
.hot-university-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    margin: 12px 8px 20px 8px;
    border-radius: 24px;
    padding: 16px 4px 20px 4px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.08);
}
.hot-university-section .section-title {
    color: white;
    border-left-color: #ffd966;
    margin-top: 0;
    margin-bottom: 15px;
    padding-left: 12px;
}
.uni-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
    justify-content: center;
}
.uni-tab-btn {
    background: rgba(255,255,255,0.2);
    border: none;
    color: white;
    padding: 6px 16px;
    border-radius: 40px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}
.uni-tab-btn.active,
.uni-tab-btn:active {
    background: white;
    color: #764ba2;
}
.uni-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
    padding: 0 2px;
}
.uni-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    transition: transform 0.2s;
}
.uni-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    padding: 10px 8px;
    gap: 10px;
}
.uni-img {
    flex-shrink: 0;
    width: 60px;
    height: 60px;
    border-radius: 30px;
    overflow: hidden;
    background: #f1f5f9;
}
.uni-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.uni-info {
    flex: 1;
    min-width: 0;
}
.uni-name {
    font-size: 18px;
    font-weight: normal;
    color: #1e293b;
    line-height: 1.3;
    margin-bottom: 4px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.uni-remark {
    font-size: 12px;
    color: #64748b;
    line-height: 1.3;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}
.uni-card:active {
    transform: scale(0.98);
}
.no-data {
    grid-column: span 2;
    text-align: center;
    color: rgba(255,255,255,0.8);
    padding: 20px;
}

/* ========== 热门资讯 & 志愿填报 图文列表 ========== */
.news-list-image {
    margin: 0 16px;
    background: white;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0,0,0,0.03);
}
.news-item-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    padding: 14px 16px;
    border-bottom: 1px solid #f0f2f8;
    gap: 12px;
}
.news-item-row:last-child {
    border-bottom: none;
}
.news-info {
    flex: 1;
    min-width: 0;
}
.news-title {
    font-size: 18px;
    font-weight: normal;
    color: #222;
    text-decoration: none;
    display: block;
    line-height: 1.4;
    margin-bottom: 6px;
    word-break: break-word;
    white-space: normal;
}
.news-title:active {
    color: #3b82f6;
}
.news-time {
    font-size: 12px;
    color: #94a3b8;
}
.news-thumb {
    flex-shrink: 0;
    width: 80px;
    height: 60px;
    border-radius: 12px;
    overflow: hidden;
    background: #e2e8f0;
}
.news-thumb img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #f8fafc;
}
.news-thumb:active img {
    transform: scale(1.02);
}

/* 查看更多按钮 */
.more-btn-wrap {
    text-align: center;
    margin: 20px 16px 10px;
}
.more-btn {
    display: inline-block;
    background: #f1f5f9;
    color: #3b82f6;
    padding: 10px 28px;
    border-radius: 40px;
    font-size: 16px;
    font-weight: 500;
    text-decoration: none;
    border: 1px solid #e2e8f0;
    transition: all 0.2s;
}
.more-btn:active {
    background: #e2e8f0;
    transform: scale(0.96);
}

/* 热门专业推荐 */
.hot-major-section {
    margin: 20px 16px;
}
.major-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 16px;
}
.major-card {
    background: white;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.04);
    transition: all 0.2s;
}
.major-card a {
    text-decoration: none;
    display: block;
}
.major-img {
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
    background: #f1f5f9;
}
.major-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.major-card:active img {
    transform: scale(1.05);
}
.major-name {
    font-size: 16px;
    font-weight: 500;
    color: #1e293b;
    text-align: center;
    padding: 10px 5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    background: white;
}

/* 志愿填报区块边距 */
.volunteer-section {
    margin-bottom: 24px;
}

/* 友情链接 */
.link {
    margin: 16px;
    padding: 12px 0;
    border-top: 1px solid #eef2f6;
    font-size: 13px;
    color: #555;
    overflow-x: auto;
    white-space: nowrap;
}
.link a {
    display: inline-block;
    margin: 0 12px 0 0;
    color: #555;
    text-decoration: none;
}
.link a:active {
    color: #3b82f6;
}

/* 底部版权 */
.bottomtext {
    background: #f8fafc;
    padding: 16px;
    text-align: center;
    font-size: 12px;
    color: #94a3b8;
    border-top: 1px solid #eef2f6;
}
.bottomtext a {
    color: #94a3b8;
    text-decoration: none;
}

/* 响应式调整 */
@media (max-width: 480px) {
    .nav-grid {
        gap: 8px 4px;
        padding: 8px 4px;
    }
    .nav-item img {
        width: 44px;
        height: 44px;
    }
    .uni-name {
        font-size: 17px;
    }
    .news-title {
        font-size: 17px;
    }
    .major-name {
        font-size: 14px;
        white-space: normal;
        line-height: 1.3;
        padding: 8px 4px;
    }
    .news-thumb {
        width: 70px;
        height: 55px;
    }
}
@media (max-width: 380px) {
    .major-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}