/* ============================================================
   首页美化 + 手机自适应 (Home Beautify)
   设计语言：深宇宙 + 金色点缀 + 玻璃拟态
   基于 starwaves_top_extra.css 保持一致
   ============================================================ */

/* ── 手机端英雄区域适配 ── */
@media (max-width: 767px) {
    .site-hero {
        min-height: auto !important;
        padding: 140px 0 60px !important;
    }
    
    .hero-content {
        padding-top: 30px !important;
        padding-bottom: 40px !important;
        flex-direction: column !important;
        align-items: center !important;
        gap: 24px !important;
    }
    
    .hero-copy {
        max-width: 100% !important;
        text-align: center !important;
    }
    
    .hero-copy h2 {
        font-size: 32px !important;
        line-height: 1.15 !important;
        letter-spacing: 1px !important;
    }
    
    .hero-copy p {
        font-size: 15px !important;
        line-height: 1.7 !important;
    }
    
    .hero-actions {
        justify-content: center !important;
        gap: 12px !important;
    }
    
    .hero-actions .hero-primary,
    .hero-actions .hero-secondary {
        width: 100% !important;
        text-align: center !important;
        padding: 14px 24px !important;
        font-size: 14px !important;
    }
    
    .hero-panel {
        width: 100% !important;
        max-width: 360px !important;
    }
    
    .hero-panel-card {
        padding: 20px !important;
        border-radius: 20px !important;
    }
    
    .hero-panel-card li strong {
        font-size: 18px !important;
    }
    
    .hero-kicker {
        font-size: 11px !important;
        padding: 6px 14px !important;
    }
}

/* ── 超小屏 (≤480px) ── */
@media (max-width: 480px) {
    .site-hero {
        padding: 120px 0 40px !important;
    }
    
    .hero-copy h2 {
        font-size: 26px !important;
    }
    
    .hero-copy p {
        font-size: 14px !important;
    }
}

/* ── Feature Strip 手机适配 ── */
@media (max-width: 767px) {
    .feature-strip {
        margin-top: -30px !important;
        padding: 0 12px !important;
    }
    
    .agileits_banner_bottom_left {
        width: 100% !important;
        padding: 0 !important;
    }
    
    .section-card {
        min-height: auto !important;
        padding: 20px 18px !important;
        border-radius: 20px !important;
        margin-bottom: 12px !important;
    }
    
    .wthree_banner_bottom_grid_left {
        width: 50px !important;
        padding: 0 !important;
        flex-shrink: 0;
    }
    
    .wthree_banner_bottom_grid_right {
        width: calc(100% - 60px) !important;
        padding: 0 !important;
    }
    
    .wthree_banner_bottom_grid_right h4 {
        font-size: 18px !important;
    }
    
    .wthree_banner_bottom_grid_right p {
        font-size: 13px !important;
        line-height: 1.6 !important;
    }
}

/* ── Service Matrix (3个功能卡片) 手机适配 ── */
@media (max-width: 991px) {
    .service-matrix-grid {
        grid-template-columns: 1fr !important;
        gap: 16px !important;
        margin-top: 1.5em !important;
    }
}

@media (max-width: 767px) {
    .service-matrix-zone {
        padding: 2.5em 0 3em !important;
    }
    
    .service-path-card {
        padding: 20px !important;
        border-radius: 18px !important;
    }
    
    .service-path-card h4 {
        font-size: 20px !important;
        margin: 14px 0 10px !important;
    }
    
    .service-path-card p,
    .service-path-card li {
        font-size: 14px !important;
        line-height: 1.7 !important;
    }
}

/* ── STAR TOP 区域手机适配 ── */
@media (max-width: 767px) {
    .dynamic-upload-zone {
        padding: 3em 0 !important;
    }
    
    .topchart-home-head h3 {
        font-size: 22px !important;
        text-align: center;
    }
    
    .topchart-home-head h3 span {
        display: block !important;
        font-size: 13px !important;
        margin-top: 6px;
    }
    
    .topchart-home-head p {
        font-size: 13px !important;
        text-align: center !important;
    }
    
    /* 排行榜标签：手机上改为2列或单列紧凑 */
    .topchart-home-tabs {
        display: grid !important;
        grid-template-columns: 1fr 1fr !important;
        gap: 8px !important;
        margin: 16px 0 !important;
    }
    
    .topchart-home-tab {
        padding: 12px 14px !important;
        border-radius: 14px !important;
    }
    
    .topchart-home-tab span {
        font-size: 12px !important;
        padding: 3px 8px !important;
    }
    
    .topchart-home-tab strong {
        font-size: 13px !important;
    }
    
    .topchart-home-tab em {
        font-size: 11px !important;
    }
    
    /* 歌曲卡片 */
    .topchart-home-card {
        flex-direction: row !important;
        padding: 12px 14px !important;
        gap: 10px !important;
        border-radius: 16px !important;
    }
    
    .topchart-home-rank {
        font-size: 18px !important;
        min-width: 28px !important;
    }
    
    .topchart-home-avatar {
        width: 52px !important;
        height: 52px !important;
        border-radius: 12px !important;
    }
    
    .topchart-home-copy h4 {
        font-size: 15px !important;
        margin-bottom: 2px !important;
    }
    
    .topchart-home-copy p {
        font-size: 12px !important;
    }
    
    .topchart-home-copy span {
        font-size: 11px !important;
    }
    
    .topchart-home-actions .chart-play-all-btn {
        padding: 10px 14px !important;
        font-size: 13px !important;
    }
    
    .topchart-home-actions .chart-play-all-btn .chart-play-all-icon {
        width: 30px !important;
        height: 30px !important;
        font-size: 12px !important;
    }
    
    .topchart-home-list-head {
        margin: 0 0 10px !important;
    }
    
    .topchart-home-list {
        gap: 8px !important;
    }
    
    .topchart-home-cta {
        margin-top: 20px !important;
    }
    
    .topchart-home-cta a {
        width: 100% !important;
        text-align: center !important;
        padding: 14px 20px !important;
        font-size: 14px !important;
    }
}

/* ── 超小屏 STAR TOP ── */
@media (max-width: 480px) {
    .topchart-home-tabs {
        grid-template-columns: 1fr 1fr !important;
    }
    
    .topchart-home-card {
        padding: 10px 12px !important;
    }
    
    .topchart-home-avatar {
        width: 46px !important;
        height: 46px !important;
    }
    
    .topchart-home-copy h4 {
        font-size: 14px !important;
    }
}

/* ── Footer 手机适配 ── */
@media (max-width: 767px) {
    .footer {
        padding: 20px 0 !important;
    }
    
    .f-bg-w3l {
        padding: 0 !important;
    }
    
    .f-bg-w3l .container {
        padding: 0 16px !important;
    }
    
    .w3layouts_footer_grid {
        width: 100% !important;
        text-align: center !important;
        margin-bottom: 16px !important;
        padding: 0 !important;
    }
    
    .w3layouts_footer_grid h2 {
        font-size: 24px !important;
    }
    
    .w3l_footer_nav {
        display: flex !important;
        justify-content: center !important;
        flex-wrap: wrap !important;
        gap: 8px !important;
    }
    
    .w3l_footer_nav li {
        float: none !important;
        display: inline-block !important;
    }
    
    .w3l_footer_nav li a {
        padding: 6px 12px !important;
        font-size: 13px !important;
    }
    
    .f-bg-w3l p {
        font-size: 13px !important;
        line-height: 1.7 !important;
        margin-top: 12px !important;
    }
}

/* ── 底部播放器手机适配 ── */
@media (max-width: 767px) {
    body.has-song-bottom-player {
        padding-bottom: 130px !important;
    }
    
    .song-bottom-player {
        padding: 8px 12px calc(8px + env(safe-area-inset-bottom, 0px)) !important;
    }
    
    .song-bottom-player__inner {
        gap: 10px !important;
    }
    
    .song-bottom-player__meta {
        width: 100% !important;
    }
    
    .song-bottom-player__title {
        font-size: 14px !important;
    }
    
    .song-bottom-player__time {
        font-size: 12px !important;
    }
    
    .song-bottom-player__audio {
        width: 100% !important;
    }
}

/* ── 导航栏手机适配 (增强) ── */
@media (max-width: 767px) {
    .site-shell {
        position: relative !important;
    }
    
    .navbar-header {
        min-height: 56px !important;
    }
    
    .starwaves-brand {
        transform: translateY(-2px) !important;
    }
    
    .brand-mark {
        width: 40px !important;
        height: 40px !important;
        transform: translateY(-2px) scaleY(0.85) !important;
    }
    
    .brand-text-wrap strong {
        font-size: 18px !important;
    }
    
    .brand-text-wrap em {
        font-size: 10px !important;
        letter-spacing: 2px !important;
    }
    
    .navbar-toggle {
        margin-right: 4px !important;
    }
    
    .navbar-collapse {
        max-height: 80vh !important;
        overflow-y: auto !important;
    }
    
    .navbar-nav {
        margin: 4px 0 0 !important;
    }
    
    .navbar-nav > li {
        margin: 0 !important;
    }
    
    .navbar-nav > li > a {
        display: block !important;
        width: 100% !important;
        min-width: auto !important;
        margin: 3px 12px !important;
        padding: 10px 16px !important;
        font-size: 15px !important;
        text-align: left !important;
        border-radius: 10px !important;
    }
    
    .site-user-chip,
    .site-entry-actions {
        margin: 8px auto 12px !important;
        max-width: calc(100% - 24px) !important;
        justify-content: center !important;
    }
    
    .site-user-chip {
        padding: 8px 16px !important;
    }
    
    .site-entry-actions-single {
        margin-left: 0 !important;
    }
    
    .site-login-pill {
        padding: 10px 20px !important;
        font-size: 14px !important;
    }
}

/* ── 平板适配 (768-991px) ── */
@media (min-width: 768px) and (max-width: 991px) {
    .hero-copy h2 {
        font-size: 48px !important;
    }
    
    .hero-panel {
        width: 280px !important;
    }
    
    .topchart-home-tabs {
        grid-template-columns: 1fr 1fr !important;
    }
    
    .topchart-home-card {
        padding: 14px 18px !important;
    }
    
    .service-matrix-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }
}

/* ── 导航栏 sticky + 毛玻璃 (桌面) ── */
@media (min-width: 768px) {
    .site-shell {
        position: sticky !important;
        top: 0 !important;
        z-index: 1000 !important;
        background: rgba(9, 13, 22, 0.92) !important;
        backdrop-filter: blur(18px) !important;
        -webkit-backdrop-filter: blur(18px) !important;
        border-bottom: 1px solid rgba(255, 255, 255, 0.06) !important;
    }
}

/* ── Hero 区域增强 ── */
.hero-copy h2 {
    background: linear-gradient(135deg, #fff 0%, #f0e8d8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    filter: drop-shadow(0 4px 20px rgba(242, 196, 104, 0.15));
}

.hero-copy h2 span {
    background: linear-gradient(135deg, #f2c468, #e8a030);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ── 歌曲卡片与STAR.AI一致的尺寸 ── */
/* STAR.AI 工作台卡片风格：圆角24px, 卡片高度统一 */
.topchart-home-card {
    display: flex !important;
    align-items: center !important;
    gap: 16px !important;
    padding: 16px 22px !important;
    margin-bottom: 12px !important;
    background: linear-gradient(135deg, rgba(255,255,255,0.04), rgba(255,255,255,0.01)) !important;
    border: 1px solid rgba(255,255,255,0.06) !important;
    border-radius: 24px !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.15) !important;
    transition: all 0.3s ease !important;
    min-height: 72px;
}

.topchart-home-card:hover {
    background: linear-gradient(135deg, rgba(255,255,255,0.07), rgba(255,255,255,0.02)) !important;
    border-color: rgba(242, 196, 104, 0.2) !important;
    transform: translateY(-2px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.2) !important;
}

.topchart-home-list {
    display: flex !important;
    flex-direction: column !important;
    gap: 12px !important;
}

/* ── 排行榜标签样式统一 ── */
.topchart-home-tabs {
    display: flex !important;
    gap: 12px !important;
    margin: 24px 0 !important;
    flex-wrap: wrap !important;
}

.topchart-home-tab {
    flex: 1 !important;
    min-width: 140px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 6px !important;
    padding: 16px 20px !important;
    border-radius: 20px !important;
    background: rgba(18, 24, 48, 0.7) !important;
    border: 1px solid rgba(242, 196, 104, 0.08) !important;
    color: #f0ece4 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    position: relative;
    overflow: hidden;
}

.topchart-home-tab:hover {
    border-color: rgba(242, 196, 104, 0.3) !important;
    background: rgba(24, 32, 60, 0.85) !important;
    transform: translateY(-3px);
    box-shadow: 0 8px 32px rgba(0,0,0,0.3) !important;
}

.topchart-home-tab span {
    display: inline-flex !important;
    padding: 4px 10px !important;
    border-radius: 6px !important;
    background: rgba(242, 196, 104, 0.12) !important;
    color: #f2c468 !important;
    font-size: 11px !important;
    font-weight: 800 !important;
    letter-spacing: 1.5px !important;
}

.topchart-home-tab strong {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #f0ece4 !important;
}

.topchart-home-tab em {
    font-style: normal !important;
    font-size: 12px !important;
    color: rgba(240, 236, 228, 0.65) !important;
}

/* ── STAR TOP 标题 ── */
.topchart-home-head {
    text-align: center !important;
    margin-bottom: 20px !important;
}

.topchart-home-head h3 {
    font-size: 28px !important;
    font-weight: 800 !important;
    color: #f2c468 !important;
    letter-spacing: 1px !important;
}

.topchart-home-head h3 span {
    display: block !important;
    font-size: 14px !important;
    font-weight: 400 !important;
    color: rgba(240, 236, 228, 0.65) !important;
    margin-top: 8px !important;
}

.topchart-home-head p {
    font-size: 14px !important;
    color: rgba(240, 236, 228, 0.45) !important;
    margin-top: 8px !important;
}

/* ── 排名数字 ── */
.topchart-home-rank {
    font-size: 24px !important;
    font-weight: 800 !important;
    color: rgba(242, 196, 104, 0.4) !important;
    min-width: 36px !important;
    text-align: center !important;
    font-feature-settings: "tnum";
}

/* ── 歌曲头像 ── */
.topchart-home-avatar {
    width: 60px !important;
    height: 60px !important;
    border-radius: 16px !important;
    object-fit: cover !important;
    border: 2px solid rgba(242, 196, 104, 0.15) !important;
    flex-shrink: 0;
}

/* ── 歌曲信息 ── */
.topchart-home-main {
    display: flex !important;
    align-items: center !important;
    gap: 14px !important;
    flex: 1 !important;
    min-width: 0 !important;
}

.topchart-home-copy {
    min-width: 0 !important;
    flex: 1;
}

.topchart-home-copy h4 {
    font-size: 17px !important;
    font-weight: 700 !important;
    color: #f0ece4 !important;
    margin-bottom: 4px !important;
    white-space: nowrap !important;
    overflow: hidden !important;
    text-overflow: ellipsis !important;
}

.topchart-home-copy p {
    font-size: 13px !important;
    color: rgba(240, 236, 228, 0.65) !important;
    margin-bottom: 2px !important;
}

.topchart-home-copy span {
    font-size: 12px !important;
    color: rgba(240, 236, 228, 0.45) !important;
}

/* ── 操作按钮 ── */
.topchart-home-actions {
    flex-shrink: 0;
}

.topchart-home-actions .chart-play-all-btn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
    border: none !important;
    border-radius: 999px !important;
    background: linear-gradient(135deg, #f2c468, #e8a030) !important;
    color: #0a0e17 !important;
    font-weight: 800 !important;
    font-size: 14px !important;
    padding: 10px 22px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 20px rgba(242, 196, 104, 0.2) !important;
}

.topchart-home-actions .chart-play-all-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 32px rgba(242, 196, 104, 0.35) !important;
}

.topchart-home-actions .chart-play-all-btn .chart-play-all-icon {
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(10, 14, 23, 0.15) !important;
    font-size: 12px !important;
}

/* ── 全部播放按钮 ── */
#homePlayAllBtn {
    display: inline-flex !important;
    align-items: center !important;
    gap: 10px !important;
    border: none !important;
    border-radius: 999px !important;
    background: linear-gradient(135deg, #f2c468, #e8a030) !important;
    color: #0a0e17 !important;
    font-weight: 800 !important;
    font-size: 15px !important;
    padding: 14px 32px !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 20px rgba(242, 196, 104, 0.2) !important;
    margin: 0 auto !important;
    letter-spacing: 0.5px;
}

#homePlayAllBtn:hover:not(:disabled) {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 8px 32px rgba(242, 196, 104, 0.35) !important;
}

/* ── 榜单查看全部CTA ── */
.topchart-home-cta {
    text-align: center !important;
    margin-top: 28px !important;
}

.topchart-home-cta a {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px !important;
    border-radius: 999px !important;
    padding: 14px 32px !important;
    font-size: 15px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px !important;
    background: rgba(242, 196, 104, 0.1) !important;
    border: 1px solid rgba(242, 196, 104, 0.25) !important;
    color: #f2c468 !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
}

.topchart-home-cta a:hover {
    background: rgba(242, 196, 104, 0.18) !important;
    border-color: rgba(242, 196, 104, 0.4) !important;
    color: #f7d88a !important;
}

/* ── Creator Showcase 区域深色背景适配 ── */
.creator-showcase {
    background: var(--sw-bg-deep, #06080f) !important;
    color: var(--sw-text-primary, #f0ece4) !important;
}

/* ── Service Matrix 区域深色适配 ── */
.service-matrix-zone {
    background: #0a0e1a !important;
}

.service-path-card {
    background: linear-gradient(180deg, rgba(18, 24, 48, 0.8), rgba(12, 16, 32, 0.8)) !important;
    border: 1px solid rgba(242, 196, 104, 0.1) !important;
    box-shadow: 0 4px 24px rgba(0,0,0,0.2) !important;
}

.service-path-card h4 {
    color: #f0ece4 !important;
}

.service-path-card p,
.service-path-card li {
    color: rgba(240, 236, 228, 0.65) !important;
}

.service-path-tag {
    background: rgba(242, 196, 104, 0.12) !important;
    color: #f2c468 !important;
}

/* ── Feature Strip 深色适配 ── */
.feature-strip .section-card {
    background: rgba(18, 24, 48, 0.7) !important;
    backdrop-filter: blur(12px) !important;
    -webkit-backdrop-filter: blur(12px) !important;
    border: 1px solid rgba(242, 196, 104, 0.08) !important;
}

.feature-strip .section-card h4 a {
    color: #f2c468 !important;
}

.feature-strip .section-card p {
    color: rgba(240, 236, 228, 0.65) !important;
}

.feature-strip .agile_banner_bottom_grid_left_grid {
    background: rgba(242, 196, 104, 0.1) !important;
}

.feature-strip .agile_banner_bottom_grid_left_grid i {
    color: #f2c468 !important;
}

/* ── Footer 深色适配 ── */
.footer {
    background: #06080f !important;
}

.f-bg-w3l {
    background: #080c18 !important;
}

.w3layouts_footer_grid h2 {
    color: #f0ece4 !important;
}

.w3layouts_footer_grid h2 span {
    color: #f2c468 !important;
}

.w3layouts_footer_grid p {
    color: rgba(240, 236, 228, 0.5) !important;
}

.w3l_footer_nav li a {
    color: rgba(240, 236, 228, 0.6) !important;
}

.w3l_footer_nav li a:hover {
    color: #f2c468 !important;
}

/* ── 背景色兼容 ── */
.songs-preview,
.recent-upload-showcase {
    background: #0a0e1a !important;
}

.song-card,
.song-detail-card,
.songs-empty {
    background: rgba(18, 24, 48, 0.7) !important;
    border: 1px solid rgba(242, 196, 104, 0.08) !important;
}

.song-card p,
.songs-empty p {
    color: rgba(240, 236, 228, 0.65) !important;
}

.song-card-head h4,
.song-detail-card h1,
.songs-empty h4 {
    color: #f0ece4 !important;
}

.song-meta li {
    color: rgba(240, 236, 228, 0.65) !important;
}

/* ── 标题样式 ── */
.wthree_head_section h3 {
    color: var(--sw-gold) !important;
}

/* ── 容器内边距调整 ── */
@media (max-width: 767px) {
    .container {
        padding-left: 16px !important;
        padding-right: 16px !important;
    }
}

/* ── 登录页面手机适配 ── */
@media (max-width: 767px) {
    .agileits_w3layouts_banner_nav {
        width: 100% !important;
        padding: 0 16px !important;
    }
}
/* ── Base overrides for style.css compatibility ── */
/* These override old Bootstrap theme styles from style.css */
body {
    background: #06080f;
    color: #f0ece4;
}

h1, h2, h3, h4, h5, h6 {
    color: #f0ece4;
}

p, ul, ol {
    color: rgba(240, 236, 228, 0.65);
    letter-spacing: 0.5px;
}

a {
    color: #f2c468;
}

a:hover {
    color: #f7d88a;
}

/* ── Navbar overrides ── */
.navbar-default .navbar-nav > li > a {
    color: rgba(240, 236, 228, 0.7) !important;
}

.navbar-default .navbar-nav > li > a:hover {
    color: #f2c468 !important;
    background: rgba(242, 196, 104, 0.08) !important;
}

/* ── Hero gradient text ── */
.hero-copy h2 {
    background: linear-gradient(135deg, #fff 0%, #f0e8d8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-copy h2 span {
    background: linear-gradient(135deg, #f2c468, #e8a030);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}
