feat(frontend): 首页广告位网格溢出根治(minmax(0,1fr) minmax(0,1.2fr)+min-width:0) + 精选推荐对接平台广告接口 GET /app/api/market/ads

This commit is contained in:
QihuAI Design committed 2026-07-13 20:01:13 +08:00
1 parent e38e18fbe7
commit 9b87012248
3 files changed
+74 -7

No files matched your search

+14 -4
View File
@@ -73,8 +73,13 @@
}
.lp-hero-grid {
max-width: 1200px; margin: 0 auto; padding: 0 var(--space-2xl);
display: grid; grid-template-columns: 1fr 2fr; gap: 0; align-items: center;
display: grid;
/* minmax(0,..) 锁死轨道最小宽=0,防止右侧轮播的 flex 内容把列撑破而"超出免费注册边框" */
grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr);
gap: var(--space-4xl); align-items: center;
}
/* 左右两列都允许收缩,杜绝内容撑破网格导致的水平溢出 */
.lp-hero-text { min-width: 0; }
.lp-eyebrow {
display: inline-block; font-size: var(--text-sm); font-weight: 600; color: var(--color-accent);
background: var(--color-accent-light); padding: 4px 12px; border-radius: var(--radius-full); margin-bottom: var(--space-lg);
@@ -89,12 +94,17 @@
.lp-stat-num { font-size: var(--text-xl); font-weight: 800; color: var(--color-text-primary); }
.lp-stat-label { font-size: var(--text-sm); color: var(--color-text-tertiary); margin-top: 2px; }
.lp-hero-ad { display: flex; flex-direction: column; padding-right: var(--space-3xl); }
/* 右侧广告位:min-width:0 让其严格贴合网格右轨道,右边框与顶栏"免费注册"垂直对齐、绝不外溢 */
.lp-hero-ad { display: flex; flex-direction: column; min-width: 0; }
.lp-ad-head { display: flex; align-items: baseline; gap: var(--space-md); margin-bottom: var(--space-lg); flex-wrap: wrap; }
.lp-ad-title { font-size: var(--text-lg); font-weight: 700; color: var(--color-text-primary); }
.lp-ad-sub { font-size: var(--text-sm); color: var(--color-text-tertiary); }
.lp-hero-ad .lp-carousel-card { min-height: 300px; }
.lp-hero-ad .lp-cc-content { max-width: 64%; }
.lp-hero-ad .lp-carousel { width: 100%; }
.lp-hero-ad .lp-carousel-card { min-height: 340px; }
.lp-hero-ad .lp-cc-content { max-width: 62%; }
.lp-hero-ad .lp-cc-cover { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 0; }
.lp-hero-ad .lp-cc-cover + .lp-cc-content { color: #fff; }
.lp-hero-ad .lp-cc-scrim { position: absolute; inset: 0; z-index: 1; background: linear-gradient(90deg, rgba(0,0,0,.55) 0%, rgba(0,0,0,.15) 60%, rgba(0,0,0,0) 100%); }
/* ===== 轮播广告位 ===== */
.lp-band { padding: var(--space-4xl) 0; }