/*
Theme Name: 百龙霸业
Theme URI: https://www.bailongbaye.com
Author: YourName
Author URI: https://yourwebsite.com
Description: 专为《百龙霸业》手游定制的响应式主题，包含攻略、活动、兑换码、16:9 Hero背景图、115x115 LOGO。
Version: 1.0
License: GPL v2 or later
Text Domain: bailong-game
*/

/* ---------- 重置 & 全局 ---------- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
body {
    font-family: 'PingFang SC', 'Microsoft YaHei', sans-serif;
    background: #0b0a0c;
    color: #e0d6c8;
    line-height: 1.6;
}
a {
    color: #c9a86c;
    text-decoration: none;
    transition: color 0.2s;
}
a:hover {
    color: #e8c48a;
}
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}
img {
    max-width: 100%;
    height: auto;
    display: block;
}
.section-title {
    font-size: 2.2rem;
    font-weight: 700;
    text-align: center;
    color: #f0e0c0;
    letter-spacing: 2px;
    margin-bottom: 30px;
    position: relative;
}
.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: #b8863a;
    margin: 12px auto 0;
}

/* ---------- HEADER（导航栏） ---------- */
.site-header {
    background: rgba(10, 8, 12, 0.92);
    backdrop-filter: blur(6px);
    border-bottom: 1px solid #2a1f14;
    padding: 8px 0;
    position: sticky;
    top: 0;
    z-index: 999;
}
.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: nowrap;
}

/* ---- 左侧 LOGO ---- */
.site-branding {
    flex: 0 0 auto;
    display: flex;
    align-items: center;
}
.site-branding .custom-logo-link {
    display: block;
    line-height: 0;
}
.site-branding .custom-logo {
    width: 115px;
    height: 115px;
    object-fit: contain;
    border-radius: 12px;
}
/* 无 LOGO 时的文字替代 */
.logo-text-link {
    display: flex;
    align-items: baseline;
    gap: 8px;
}
.logo-text {
    font-size: 1.8rem;
    font-weight: 900;
    color: #f0d8a0;
    text-shadow: 0 0 10px rgba(200, 150, 60, 0.3);
    letter-spacing: 2px;
}
.logo-sub {
    font-size: 0.85rem;
    color: #b89a70;
    background: #2a1f14;
    padding: 2px 10px;
    border-radius: 20px;
    font-weight: 300;
}

/* ---- 右侧区域 ---- */
.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
    flex: 1 1 auto;
    justify-content: flex-end;
}

/* ---- 导航菜单 ---- */
.main-navigation {
    display: flex;
    align-items: center;
    gap: 12px;
}
.nav-menu {
    list-style: none;
    display: flex;
    gap: 24px;
    margin: 0;
    padding: 0;
}
.nav-menu li a {
    color: #d6cabc;
    font-size: 1rem;
    padding: 6px 0;
    border-bottom: 2px solid transparent;
    transition: 0.3s;
    font-weight: 500;
}
.nav-menu li a:hover,
.nav-menu li.current-menu-item a {
    border-bottom-color: #b8863a;
    color: #f0e0c0;
}

/* ---- 桌面端下载按钮 ---- */
.nav-download-desktop {
    display: flex;
    gap: 8px;
    align-items: center;
}
.nav-download-mobile {
    display: none;
}
.btn-download-nav {
    background: #b8863a;
    color: #1a1410;
    padding: 6px 16px;
    border-radius: 30px;
    font-weight: 600;
    font-size: 0.8rem;
    transition: 0.3s;
    white-space: nowrap;
}
.btn-download-nav:hover {
    background: #dba859;
    color: #0b0a0c;
}
.btn-code-nav {
    background: linear-gradient(135deg, #e8a838, #c88020);
    color: #1a1410;
}
.btn-code-nav:hover {
    background: linear-gradient(135deg, #f0c050, #d89030);
}

/* ---- 移动端汉堡菜单 ---- */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    flex-direction: column;
    gap: 5px;
    cursor: pointer;
    padding: 5px;
    order: 10;
}
.nav-toggle .bar {
    display: block;
    width: 28px;
    height: 3px;
    background: #e0d6c8;
    border-radius: 3px;
    transition: 0.3s;
}

/* ---------- HERO（16:9 背景图） ---------- */
.hero-section {
    position: relative;
    padding: 80px 0 100px;
    overflow: hidden;
    min-height: 500px;
    display: flex;
    align-items: center;
    background-size: cover !important;
    background-position: center !important;
}
.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 0;
}
.hero-content {
    position: relative;
    z-index: 1;
    display: flex;
    align-items: center;
    gap: 40px;
    flex-wrap: wrap;
}
.hero-text {
    flex: 1 1 400px;
}
.hero-text h1 {
    font-size: 3.5rem;
    font-weight: 900;
    color: #f0d8a0;
    line-height: 1.2;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.8);
}
.hero-sub {
    font-size: 1.4rem;
    font-weight: 400;
    color: #e8d5b0;
    margin-top: 6px;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.7);
}
.hero-desc {
    font-size: 1.1rem;
    color: #d0c0b0;
    margin: 16px 0 28px;
    text-shadow: 0 2px 8px rgba(0, 0, 0, 0.6);
}
.hero-cta {
    display: flex;
    gap: 16px;
    flex-wrap: wrap;
}
.btn-hero {
    padding: 14px 40px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    text-align: center;
    transition: 0.3s;
    border: none;
}
.btn-android {
    background: #3c9b3e;
    color: #fff;
}
.btn-android:hover {
    background: #4fb852;
    color: #fff;
}
.btn-ios {
    background: #2a2a2e;
    color: #fff;
    border: 1px solid #555;
}
.btn-ios:hover {
    background: #3a3a40;
    color: #fff;
}
.btn-code {
    background: linear-gradient(135deg, #e8a838, #c88020);
    color: #1a1410;
    border: none;
}
.btn-code:hover {
    background: linear-gradient(135deg, #f0c050, #d89030);
    color: #0b0a0c;
    transform: scale(1.05);
}
.hero-mockup {
    flex: 0 0 280px;
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.7);
    border: 2px solid #4a3a2a;
}
.hero-mockup img {
    width: 100%;
    height: auto;
    aspect-ratio: 720/1280;
    object-fit: cover;
}

/* ---------- FEATURES ---------- */
.features-section {
    padding: 80px 0;
    background: #131011;
}
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}
.feature-item {
    background: #1f181a;
    padding: 30px 20px;
    border-radius: 16px;
    text-align: center;
    border: 1px solid #2f2620;
    transition: 0.3s;
}
.feature-item:hover {
    transform: translateY(-6px);
    border-color: #b8863a;
}
.feature-icon {
    font-size: 2.8rem;
    margin-bottom: 12px;
}
.feature-item h3 {
    color: #f0d8a0;
    font-size: 1.2rem;
    margin-bottom: 8px;
}
.feature-item p {
    color: #b0a090;
    font-size: 0.95rem;
}

/* ---------- VIDEO ---------- */
.video-section {
    padding: 80px 0;
    background: #0e0c0e;
}
.video-wrapper {
    position: relative;
    padding-bottom: 56.25%; /* 16:9 */
    height: 0;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
}
.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    border: none;
}

/* ---------- SCREENSHOTS ---------- */
.screenshots-section {
    padding: 80px 0;
    background: #131011;
}
.screenshots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 20px;
}
.screenshot-item {
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #2f2620;
    transition: 0.3s;
    aspect-ratio: 720/1280;
}
.screenshot-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.screenshot-item:hover {
    border-color: #b8863a;
    transform: scale(1.02);
}

/* ---------- LATEST POSTS ---------- */
.latest-section {
    padding: 80px 0;
    background: #0e0c0e;
}
.latest-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}
.latest-col {
    background: #1a1416;
    padding: 30px 25px;
    border-radius: 16px;
    border: 1px solid #2f2620;
}
.col-title {
    font-size: 1.5rem;
    color: #f0d8a0;
    margin-bottom: 20px;
    border-bottom: 2px solid #2f2620;
    padding-bottom: 12px;
}
.post-list {
    list-style: none;
    padding: 0;
}
.post-list li {
    padding: 10px 0;
    border-bottom: 1px solid #2a1f1a;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
}
.post-list li a {
    color: #d6cabc;
    font-weight: 500;
}
.post-list li a:hover {
    color: #e8c48a;
}
.post-date {
    color: #8a7a6a;
    font-size: 0.85rem;
}
.empty-tip {
    color: #6a5a4a;
    padding: 10px 0;
}
.more-link {
    display: inline-block;
    margin-top: 16px;
    font-weight: 600;
    color: #b8863a;
}
.more-link:hover {
    color: #dba859;
}

/* ---------- CTA ---------- */
.cta-section {
    padding: 60px 0 80px;
    background: linear-gradient(135deg, #1f1510, #2f1f16);
}
.cta-box {
    background: rgba(0, 0, 0, 0.5);
    border: 1px solid #4a3a2a;
    border-radius: 30px;
    padding: 50px 30px;
    text-align: center;
    backdrop-filter: blur(4px);
}
.cta-box h2 {
    font-size: 2.5rem;
    color: #f0e0c0;
}
.cta-box h2 strong {
    color: #dba859;
}
.cta-box p {
    font-size: 1.1rem;
    color: #c0b0a0;
    margin: 16px 0 30px;
}
.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}
.btn-cta {
    padding: 16px 48px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1.1rem;
    transition: 0.3s;
}
.btn-cta.btn-android {
    background: #3c9b3e;
    color: #fff;
}
.btn-cta.btn-android:hover {
    background: #4fb852;
}
.btn-cta.btn-ios {
    background: #2a2a2e;
    color: #fff;
    border: 1px solid #555;
}
.btn-cta.btn-ios:hover {
    background: #3a3a40;
}
.btn-cta.btn-code {
    background: linear-gradient(135deg, #e8a838, #c88020);
    color: #1a1410;
    border: none;
}
.btn-cta.btn-code:hover {
    background: linear-gradient(135deg, #f0c050, #d89030);
}

/* ---------- FOOTER ---------- */
.site-footer {
    background: #0b0a0c;
    border-top: 1px solid #1f181a;
    padding: 40px 0 20px;
}
.footer-inner {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}
.footer-brand .footer-logo {
    font-size: 1.8rem;
    font-weight: 900;
    color: #f0d8a0;
}
.footer-desc {
    color: #8a7a6a;
    margin-top: 6px;
}
.footer-links ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
}
.footer-links ul li a {
    color: #b0a090;
}
.footer-links ul li a:hover {
    color: #dba859;
}
.footer-bottom {
    border-top: 1px solid #1f181a;
    padding-top: 20px;
    margin-top: 30px;
    text-align: center;
    font-size: 0.9rem;
    color: #6a5a4a;
}
.footer-bottom a {
    color: #b8863a;
}

/* ---------- 响应式 ---------- */
@media (max-width: 992px) {
    .nav-download-desktop {
        display: none;
    }
    .nav-download-mobile {
        display: flex;
        gap: 8px;
        flex-wrap: wrap;
        justify-content: center;
        margin-top: 12px;
    }
    .nav-toggle {
        display: flex;
    }
    .main-navigation {
        display: none;
        flex-direction: column;
        width: 100%;
        align-items: stretch;
        background: #0b0a0c;
        padding: 20px 0;
        border-top: 1px solid #2a1f14;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        z-index: 999;
    }
    .main-navigation.active {
        display: flex;
    }
    .nav-menu {
        flex-direction: column;
        gap: 6px;
        padding: 0 20px;
    }
    .nav-menu li a {
        display: block;
        padding: 10px 0;
        border-bottom: none;
    }
    .nav-menu li a:hover {
        border-bottom: none;
        color: #f0e0c0;
    }
    .header-right {
        flex-wrap: wrap;
        justify-content: flex-end;
    }
    .site-branding .custom-logo {
        width: 80px;
        height: 80px;
    }
    .logo-text {
        font-size: 1.4rem;
    }
    .logo-sub {
        font-size: 0.7rem;
    }
    .hero-content {
        flex-direction: column-reverse;
        text-align: center;
    }
    .hero-text h1 {
        font-size: 2.4rem;
    }
    .hero-sub {
        font-size: 1.1rem;
    }
    .hero-cta {
        justify-content: center;
    }
    .hero-mockup {
        flex: 0 0 200px;
        max-width: 240px;
        margin: 0 auto;
    }
    .latest-grid {
        grid-template-columns: 1fr;
    }
    .screenshots-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    .section-title {
        font-size: 1.8rem;
    }
    .cta-box h2 {
        font-size: 1.8rem;
    }
    .hero-section {
        padding: 50px 0 60px;
        min-height: 400px;
    }
}

@media (max-width: 480px) {
    .site-branding .custom-logo {
        width: 60px;
        height: 60px;
    }
    .logo-text {
        font-size: 1.1rem;
    }
    .logo-sub {
        font-size: 0.6rem;
        padding: 1px 8px;
    }
    .screenshots-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .btn-hero {
        padding: 12px 24px;
        font-size: 0.95rem;
    }
    .btn-cta {
        padding: 12px 28px;
        font-size: 1rem;
    }
    .hero-text h1 {
        font-size: 1.8rem;
    }
    .hero-sub {
        font-size: 0.95rem;
    }
    .hero-desc {
        font-size: 0.9rem;
    }
    .hero-mockup {
        flex: 0 0 150px;
        max-width: 180px;
    }
    .hero-section {
        padding: 30px 0 40px;
        min-height: 300px;
    }
    .cta-box h2 {
        font-size: 1.4rem;
    }
    .cta-box p {
        font-size: 0.95rem;
    }
}