/* ===== 九州娱乐(中文)官网 - ku游 完整样式表 ===== */
/* 全局重置 & 基础 */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, 'Noto Sans SC', sans-serif;
    background: #f8f9fa;
    color: #1a1a2e;
    line-height: 1.6;
    transition: background 0.4s ease, color 0.4s ease;
    min-height: 100vh;
}

body.dark-mode {
    background: #0f0f1a;
    color: #e0e0e0;
}

.container {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ===== 导航栏 ===== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    transition: background 0.4s ease, border-color 0.4s ease;
}

body.dark-mode .navbar {
    background: rgba(15, 15, 26, 0.85);
    border-bottom-color: rgba(255, 255, 255, 0.06);
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 72px;
}

.logo {
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #1a237e, #3949ab);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: 1px;
    user-select: none;
}

body.dark-mode .logo {
    background: linear-gradient(135deg, #7c8cf0, #a0b0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.nav-links {
    display: flex;
    gap: 28px;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: #333;
    font-size: 15px;
    font-weight: 500;
    transition: color 0.3s ease;
    position: relative;
    padding: 4px 0;
}

body.dark-mode .nav-links a {
    color: #ccc;
}

.nav-links a:hover,
.nav-links a:focus-visible {
    color: #1a237e;
    outline: none;
}

body.dark-mode .nav-links a:hover,
body.dark-mode .nav-links a:focus-visible {
    color: #7c8cf0;
}

.nav-links a.active {
    color: #1a237e;
}

body.dark-mode .nav-links a.active {
    color: #7c8cf0;
}

.nav-links a.active::after {
    content: '';
    position: absolute;
    bottom: -4px;
    left: 0;
    right: 0;
    height: 2px;
    background: #1a237e;
    border-radius: 2px;
    transition: background 0.3s ease;
}

body.dark-mode .nav-links a.active::after {
    background: #7c8cf0;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 16px;
}

.theme-toggle {
    background: none;
    border: 1px solid #ddd;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    font-size: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.3s ease, border-color 0.3s ease, transform 0.2s ease;
    line-height: 1;
}

body.dark-mode .theme-toggle {
    border-color: #444;
}

.theme-toggle:hover {
    background: #eee;
    transform: scale(1.05);
}

body.dark-mode .theme-toggle:hover {
    background: #222;
}

.search-trigger {
    background: none;
    border: none;
    font-size: 20px;
    cursor: pointer;
    color: #333;
    transition: color 0.3s ease, transform 0.2s ease;
    line-height: 1;
    padding: 4px;
}

body.dark-mode .search-trigger {
    color: #ccc;
}

.search-trigger:hover {
    transform: scale(1.1);
    color: #1a237e;
}

body.dark-mode .search-trigger:hover {
    color: #7c8cf0;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #333;
    transition: color 0.3s ease;
    line-height: 1;
    padding: 4px;
}

body.dark-mode .mobile-menu-btn {
    color: #ccc;
}

/* ===== 移动端菜单 ===== */
.mobile-menu {
    display: none;
    position: fixed;
    top: 72px;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    padding: 20px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.1);
    z-index: 999;
    max-height: calc(100vh - 72px);
    overflow-y: auto;
}

body.dark-mode .mobile-menu {
    background: rgba(15, 15, 26, 0.98);
}

.mobile-menu.open {
    display: block;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.mobile-menu a {
    display: block;
    padding: 12px 0;
    font-size: 16px;
    color: #333;
    text-decoration: none;
    border-bottom: 1px solid #eee;
    transition: color 0.3s ease, padding-left 0.3s ease;
}

body.dark-mode .mobile-menu a {
    color: #ccc;
    border-bottom-color: #222;
}

.mobile-menu a:hover {
    color: #1a237e;
    padding-left: 8px;
}

body.dark-mode .mobile-menu a:hover {
    color: #7c8cf0;
}

.mobile-menu a:last-child {
    border-bottom: none;
}

/* ===== 搜索弹窗 ===== */
.search-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    display: none;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}

.search-overlay.open {
    display: flex;
    animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.search-box {
    background: #fff;
    padding: 32px;
    border-radius: 16px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.15);
    animation: scaleIn 0.3s ease;
}

body.dark-mode .search-box {
    background: #1e1e2e;
}

@keyframes scaleIn {
    from {
        opacity: 0;
        transform: scale(0.92);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.search-box input {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid #ddd;
    border-radius: 10px;
    font-size: 16px;
    outline: none;
    transition: border-color 0.3s ease;
    background: #fff;
    color: #1a1a2e;
}

body.dark-mode .search-box input {
    background: #2a2a3e;
    border-color: #444;
    color: #fff;
}

.search-box input:focus {
    border-color: #1a237e;
}

body.dark-mode .search-box input:focus {
    border-color: #7c8cf0;
}

.search-box .close-search {
    margin-top: 16px;
    text-align: right;
    cursor: pointer;
    color: #666;
    font-size: 14px;
    transition: color 0.3s ease;
}

body.dark-mode .search-box .close-search {
    color: #aaa;
}

.search-box .close-search:hover {
    color: #1a237e;
}

body.dark-mode .search-box .close-search:hover {
    color: #7c8cf0;
}

/* ===== 通用标题 ===== */
.section-title {
    text-align: center;
    margin-bottom: 48px;
}

.section-title h2 {
    font-size: 36px;
    font-weight: 700;
    background: linear-gradient(135deg, #1a237e, #3949ab);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.3;
}

body.dark-mode .section-title h2 {
    background: linear-gradient(135deg, #7c8cf0, #a0b0ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.section-title p {
    color: #666;
    margin-top: 8px;
    font-size: 16px;
}

body.dark-mode .section-title p {
    color: #aaa;
}

/* ===== 卡片 ===== */
.card {
    background: #fff;
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

body.dark-mode .card {
    background: #1a1a2e;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
}

body.dark-mode .card:hover {
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.card h3 {
    margin-bottom: 12px;
    font-size: 20px;
    font-weight: 700;
    color: #1a237e;
}

body.dark-mode .card h3 {
    color: #7c8cf0;
}

.card p {
    color: #555;
    line-height: 1.7;
}

body.dark-mode .card p {
    color: #bbb;
}

/* ===== 毛玻璃 ===== */
.glass {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 16px;
}

body.dark-mode .glass {
    background: rgba(15, 15, 26, 0.5);
    border-color: rgba(255, 255, 255, 0.08);
}

/* ===== 按钮 ===== */
.btn-primary {
    display: inline-block;
    padding: 12px 32px;
    background: linear-gradient(135deg, #1a237e, #3949ab);
    color: #fff;
    border: none;
    border-radius: 50px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    text-decoration: none;
    text-align: center;
    line-height: 1.4;
}

.btn-primary:hover {
    transform: scale(1.04);
    box-shadow: 0 8px 24px rgba(26, 35, 126, 0.3);
}

.btn-primary:focus-visible {
    outline: 2px solid #3949ab;
    outline-offset: 2px;
}

body.dark-mode .btn-primary {
    background: linear-gradient(135deg, #4a5ad0, #7c8cf0);
}

body.dark-mode .btn-primary:hover {
    box-shadow: 0 8px 24px rgba(74, 90, 208, 0.4);
}

/* ===== 网格系统 ===== */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
}

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

/* ===== Hero 区域 ===== */
.hero {
    padding: 140px 0 80px;
    background: linear-gradient(135deg, #e8eaf6 0%, #c5cae9 100%);
    position: relative;
    overflow: hidden;
    transition: background 0.8s ease;
}

body.dark-mode .hero {
    background: linear-gradient(135deg, #0d0d1a 0%, #1a1a3e 100%);
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(26, 35, 126, 0.05) 0%, transparent 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero-inner {
    display: flex;
    align-items: center;
    gap: 48px;
    position: relative;
    z-index: 1;
}

.hero-text {
    flex: 1;
}

.hero-text h1 {
    font-size: 48px;
    font-weight: 800;
    line-height: 1.2;
    margin-bottom: 16px;
    color: #1a1a2e;
}

body.dark-mode .hero-text h1 {
    color: #e0e0e0;
}

.hero-text p {
    font-size: 18px;
    color: #555;
    margin-bottom: 24px;
    max-width: 540px;
}

body.dark-mode .hero-text p {
    color: #bbb;
}

.hero-visual {
    flex: 1;
    text-align: center;
}

.hero-visual svg {
    width: 100%;
    max-width: 500px;
    height: auto;
}

.hero-badges {
    display: flex;
    gap: 12px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.hero-badges span {
    background: rgba(26, 35, 126, 0.1);
    padding: 6px 16px;
    border-radius: 50px;
    font-size: 14px;
    color: #1a237e;
    font-weight: 500;
    transition: background 0.3s ease, transform 0.2s ease;
}

body.dark-mode .hero-badges span {
    background: rgba(124, 140, 240, 0.15);
    color: #a0b0ff;
}

.hero-badges span:hover {
    background: rgba(26, 35, 126, 0.2);
    transform: translateY(-2px);
}

body.dark-mode .hero-badges span:hover {
    background: rgba(124, 140, 240, 0.25);
}

/* ===== 轮播指示器 ===== */
.carousel-dots {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 32px;
    position: relative;
    z-index: 1;
}

.carousel-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #bbb;
    cursor: pointer;
    transition: all 0.3s ease;
    border: none;
    padding: 0;
}

.carousel-dot.active {
    background: #1a237e;
    width: 30px;
    border-radius: 6px;
}

body.dark-mode .carousel-dot.active {
    background: #7c8cf0;
}

.carousel-dot:hover {
    background: #999;
}

body.dark-mode .carousel-dot:hover {
    background: #888;
}

/* ===== 数据展示 ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 24px;
    text-align: center;
}

.stat-item {
    padding: 24px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.06);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

body.dark-mode .stat-item {
    background: #1a1a2e;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.stat-item:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.1);
}

.stat-item h3 {
    font-size: 40px;
    font-weight: 800;
    color: #1a237e;
    line-height: 1.2;
}

body.dark-mode .stat-item h3 {
    color: #7c8cf0;
}

.stat-item p {
    color: #666;
    margin-top: 4px;
    font-size: 15px;
}

body.dark-mode .stat-item p {
    color: #aaa;
}

/* ===== FAQ ===== */
.faq-item {
    border-bottom: 1px solid #eee;
    padding: 16px 0;
    cursor: pointer;
    transition: border-color 0.3s ease;
}

body.dark-mode .faq-item {
    border-bottom-color: #222;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
    font-size: 17px;
    color: #1a1a2e;
    user-select: none;
}

body.dark-mode .faq-question {
    color: #e0e0e0;
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease, padding 0.3s ease, opacity 0.3s ease;
    padding-top: 0;
    opacity: 0;
    color: #555;
    line-height: 1.7;
}

body.dark-mode .faq-answer {
    color: #bbb;
}

.faq-item.open .faq-answer {
    max-height: 200px;
    padding-top: 12px;
    opacity: 1;
}

.faq-toggle {
    font-size: 20px;
    transition: transform 0.3s ease;
    font-weight: 300;
    line-height: 1;
}

.faq-item.open .faq-toggle {
    transform: rotate(45deg);
}

/* ===== 合作伙伴 ===== */
.partner-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 16px;
    align-items: center;
}

.partner-item {
    text-align: center;
    padding: 16px;
    font-weight: 600;
    font-size: 15px;
    color: #1a237e;
}

body.dark-mode .partner-item {
    color: #7c8cf0;
}

/* ===== Footer ===== */
.footer {
    background: #0d0d1a;
    color: #ccc;
    padding: 60px 0 20px;
    margin-top: 60px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 32px;
}

.footer a {
    color: #aaa;
    text-decoration: none;
    display: block;
    margin: 6px 0;
    font-size: 14px;
    transition: color 0.3s ease, padding-left 0.3s ease;
}

.footer a:hover {
    color: #fff;
    padding-left: 4px;
}

.footer h4 {
    color: #fff;
    margin-bottom: 12px;
    font-size: 16px;
    font-weight: 700;
}

.footer p {
    font-size: 14px;
    color: #aaa;
    line-height: 1.7;
}

.footer-bottom {
    border-top: 1px solid #222;
    margin-top: 32px;
    padding-top: 20px;
    text-align: center;
    font-size: 13px;
    color: #666;
}

.footer-bottom p {
    font-size: 13px;
    color: #666;
}

/* ===== 回到顶部 ===== */
.back-to-top {
    position: fixed;
    bottom: 32px;
    right: 32px;
    width: 48px;
    height: 48px;
    background: #1a237e;
    color: #fff;
    border: none;
    border-radius: 50%;
    font-size: 22px;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
    z-index: 999;
    transition: all 0.3s ease;
    line-height: 1;
}

body.dark-mode .back-to-top {
    background: #4a5ad0;
}

.back-to-top.show {
    display: flex;
    animation: fadeInUp 0.3s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.back-to-top:hover {
    transform: scale(1.1) translateY(-2px);
    box-shadow: 0 6px 20px rgba(26, 35, 126, 0.4);
}

body.dark-mode .back-to-top:hover {
    box-shadow: 0 6px 20px rgba(74, 90, 208, 0.4);
}

/* ===== 滚动动画 ===== */
.fade-in {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== 响应式设计 ===== */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }

    .hero-text h1 {
        font-size: 40px;
    }
}

@media (max-width: 768px) {
    .nav-links {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .hero-inner {
        flex-direction: column;
        text-align: center;
    }

    .hero-text {
        text-align: center;
    }

    .hero-text p {
        margin-left: auto;
        margin-right: auto;
    }

    .hero-text h1 {
        font-size: 32px;
    }

    .hero-badges {
        justify-content: center;
    }

    .btn-primary {
        display: inline-block;
    }

    .grid-2,
    .grid-3 {
        grid-template-columns: 1fr;
    }

    .partner-grid {
        grid-template-columns: repeat(3, 1fr);
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .section-title h2 {
        font-size: 28px;
    }

    .stat-item h3 {
        font-size: 32px;
    }

    .hero {
        padding: 120px 0 60px;
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .partner-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .grid-4 {
        grid-template-columns: 1fr;
    }

    .hero-text h1 {
        font-size: 28px;
    }

    .container {
        padding: 0 16px;
    }

    .section-title h2 {
        font-size: 24px;
    }

    .back-to-top {
        bottom: 20px;
        right: 20px;
        width: 42px;
        height: 42px;
        font-size: 18px;
    }
}

/* ===== 暗色模式额外调整 ===== */
body.dark-mode .glass {
    background: rgba(15, 15, 26, 0.6);
}

body.dark-mode .hero-text h1 {
    color: #e0e0e0;
}

body.dark-mode .hero-badges span {
    background: rgba(124, 140, 240, 0.15);
    color: #a0b0ff;
}

/* ===== 特殊组件 ===== */
/* 网站地图链接 */
.grid-4 a {
    color: #1a237e;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-block;
    margin: 4px 0;
}

body.dark-mode .grid-4 a {
    color: #7c8cf0;
}

.grid-4 a:hover {
    color: #3949ab;
    text-decoration: underline;
}

body.dark-mode .grid-4 a:hover {
    color: #a0b0ff;
}

/* 友情链接卡片 */
.partner-grid a.card {
    text-decoration: none;
    color: inherit;
    display: block;
}

.partner-grid a.card:hover {
    color: #1a237e;
}

body.dark-mode .partner-grid a.card:hover {
    color: #7c8cf0;
}

/* 联系卡片 */
.card p strong {
    color: #1a237e;
}

body.dark-mode .card p strong {
    color: #7c8cf0;
}

/* ===== 打印样式 ===== */
@media print {
    .navbar,
    .mobile-menu,
    .search-overlay,
    .back-to-top,
    .footer {
        display: none !important;
    }

    body {
        background: #fff;
        color: #000;
    }

    .hero {
        padding: 40px 0;
        background: #f0f0f0 !important;
    }

    .card,
    .glass,
    .stat-item {
        box-shadow: none;
        border: 1px solid #ddd;
    }

    .fade-in {
        opacity: 1;
        transform: none;
    }
}

/* ===== 辅助功能 ===== */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* 焦点样式 */
a:focus-visible,
button:focus-visible,
input:focus-visible {
    outline: 2px solid #1a237e;
    outline-offset: 2px;
}

body.dark-mode a:focus-visible,
body.dark-mode button:focus-visible,
body.dark-mode input:focus-visible {
    outline-color: #7c8cf0;
}

/* 选中文本样式 */
::selection {
    background: rgba(26, 35, 126, 0.2);
    color: #1a1a2e;
}

body.dark-mode ::selection {
    background: rgba(124, 140, 240, 0.3);
    color: #fff;
}