html {
    scroll-behavior: smooth;
}

:root {
    --faq-primary: #0066ff;
    --faq-primary-dark: #0050cc;
    --faq-accent: #4da1ff;
    --faq-soft: #eef5ff;
    --text-strong: #0f172a;
    --text-main: #334155;
    --text-muted: #64748b;
    --border: rgba(148, 163, 184, 0.24);
    --surface: #ffffff;
    --surface-muted: #f8fbff;
    --shadow-lg: 0 24px 60px rgba(15, 23, 42, 0.12);
    --shadow-md: 0 14px 36px rgba(15, 23, 42, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'MiSans', 'PingFang SC', 'Microsoft YaHei', sans-serif;
    color: var(--text-strong);
    background: linear-gradient(180deg, #f7fbff 0, #ffffff 240px);
}

a {
    color: inherit;
    text-decoration: none;
}

.mobile-overlay {
    display: none;
}

header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(18px);
    border-bottom: 1px solid rgba(148, 163, 184, 0.18);
}

.container,
.nav-wrapper,
.footer-content,
.copyright {
    width: min(1200px, calc(100% - 48px));
    margin: 0 auto;
}

.nav-wrapper {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo,
.drawer-logo {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 24px;
    font-weight: 700;
    color: var(--faq-primary);
}

.logo i,
.drawer-logo i {
    font-size: 28px;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: 40px;
    height: 100%;
    list-style: none;
}

.nav-item {
    position: relative;
    display: flex;
    align-items: center;
    font-size: 16px;
    font-weight: 500;
    color: #333333;
    cursor: pointer;
    height: 100%;
    transition: color 0.3s;
    text-decoration: none;
}

.nav-item:hover,
.nav-item.active {
    color: var(--faq-primary);
    background: transparent;
}

.nav-item .arrow {
    margin-left: 6px;
    font-size: 14px;
    transition: transform 0.3s;
}

.nav-item:hover .arrow,
.nav-item.sub-open .arrow {
    transform: rotate(180deg);
}

.dropdown {
    position: absolute;
    top: 100%;
    left: -20px;
    width: 200px;
    background: #ffffff;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
    padding: 10px 0;
    border-top: 2px solid var(--faq-primary);
    z-index: 100;
}

.nav-item:hover .dropdown,
.nav-item.sub-open .dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-item {
    display: block;
    padding: 12px 24px;
    font-size: 15px;
    color: var(--text-main);
    transition: all 0.2s;
}

.dropdown-item:hover,
.dropdown-item.active {
    background-color: #f5f9ff;
    color: var(--faq-primary);
    padding-left: 30px;
}

.drawer-header,
.drawer-close,
.mobile-menu-btn {
    display: none;
}

.page-main {
    padding-top: 104px;
}

.faq-shell {
    padding-top: 24px;
}

.hero {
    padding: 24px 0 30px;
}

.hero-panel {
    position: relative;
    overflow: hidden;
    display: grid;
    grid-template-columns: minmax(0, 1.35fr) minmax(280px, 0.65fr);
    gap: 28px;
    padding: 40px;
    border-radius: 36px;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(255, 255, 255, 0.88));
    border: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: var(--shadow-lg);
}

.hero-panel::before,
.hero-panel::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    z-index: 0;
}

.hero-panel::before {
    width: 320px;
    height: 320px;
    right: -80px;
    top: -80px;
    background: radial-gradient(circle, rgba(77, 161, 255, 0.24) 0, rgba(77, 161, 255, 0) 70%);
}

.hero-panel::after {
    width: 280px;
    height: 280px;
    left: -120px;
    bottom: -140px;
    background: radial-gradient(circle, rgba(0, 102, 255, 0.12) 0, rgba(0, 102, 255, 0) 72%);
}

.hero-copy,
.hero-stats {
    position: relative;
    z-index: 1;
}

.hero-copy {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    width: fit-content;
    padding: 10px 16px;
    border-radius: 999px;
    background: var(--faq-soft);
    color: var(--faq-primary);
    font-size: 14px;
    font-weight: 700;
}

.hero-title-en {
    font-size: 14px;
    letter-spacing: 0.24em;
    color: var(--text-muted);
    text-transform: uppercase;
}

.hero-title {
    font-size: clamp(34px, 4vw, 48px);
    line-height: 1.16;
    letter-spacing: -0.03em;
}

.hero-desc {
    max-width: 680px;
    font-size: 17px;
    line-height: 1.8;
    color: var(--text-main);
}

.hero-note {
    display: inline-flex;
    align-items: flex-start;
    gap: 10px;
    width: fit-content;
    max-width: 720px;
    padding: 14px 16px;
    border-radius: 18px;
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.hero-note i {
    margin-top: 2px;
    color: var(--faq-primary);
}

.hero-stats {
    display: grid;
    gap: 16px;
}

.stat-card {
    padding: 22px 24px;
    border-radius: 24px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(255, 255, 255, 0.9));
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: 0 12px 30px rgba(15, 23, 42, 0.06);
}

.stat-value {
    display: block;
    margin-bottom: 8px;
    font-size: 32px;
    line-height: 1;
    font-weight: 800;
    color: var(--faq-primary);
}

.stat-label {
    font-size: 14px;
    color: var(--text-muted);
}

.faq-layout {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
    padding-bottom: 84px;
}

.side-card,
.faq-panel {
    background: rgba(255, 255, 255, 0.94);
    border-radius: 30px;
    border: 1px solid rgba(148, 163, 184, 0.16);
    box-shadow: var(--shadow-md);
}

.side-card {
    position: sticky;
    top: 108px;
    padding: 26px;
}

.side-title {
    margin-bottom: 8px;
    font-size: 22px;
}

.side-desc {
    margin-bottom: 20px;
    line-height: 1.8;
    color: var(--text-muted);
    font-size: 14px;
}

.search-box {
    position: relative;
    margin-bottom: 14px;
}

.search-box i {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 18px;
}

.search-input {
    width: 100%;
    height: 52px;
    padding: 0 18px 0 46px;
    border-radius: 16px;
    border: 1px solid rgba(148, 163, 184, 0.22);
    background: #fff;
    color: var(--text-strong);
    font-size: 15px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-input:focus {
    border-color: rgba(0, 102, 255, 0.35);
    box-shadow: 0 0 0 4px rgba(0, 102, 255, 0.08);
}

.search-meta {
    display: none;
}

.category-nav {
    display: grid;
    gap: 12px;
}

.category-link,
.category-empty {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 15px 16px;
    border-radius: 18px;
    background: var(--surface-muted);
    border: 1px solid transparent;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.category-link:hover,
.category-link.is-active {
    transform: translateY(-1px);
    border-color: rgba(0, 102, 255, 0.18);
    background: var(--faq-soft);
    box-shadow: 0 10px 20px rgba(0, 102, 255, 0.08);
}

.category-link span,
.category-empty {
    font-size: 15px;
    color: var(--text-main);
}

.category-link em {
    min-width: 30px;
    height: 30px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-style: normal;
    color: var(--faq-primary);
    background: rgba(255, 255, 255, 0.88);
}

.faq-panel {
    padding: 28px;
}

.panel-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin-bottom: 22px;
}

.panel-title {
    font-size: 26px;
    margin-bottom: 8px;
}

.panel-desc {
    color: var(--text-muted);
    line-height: 1.7;
}

.toolbar-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    border-radius: 999px;
    background: var(--faq-soft);
    color: var(--faq-primary);
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.faq-sections {
    display: grid;
    gap: 20px;
}

.faq-section {
    padding: 22px;
    border-radius: 26px;
    background: linear-gradient(180deg, #fff, #fcfdff);
    border: 1px solid rgba(148, 163, 184, 0.16);
    scroll-margin-top: 120px;
}

.section-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.section-overline {
    display: none;
}

.section-header h3 {
    margin-bottom: 6px;
    font-size: 24px;
}

.section-header p {
    color: var(--text-muted);
    line-height: 1.75;
}

.section-count {
    display: inline-flex;
    align-items: center;
    height: 36px;
    padding: 0 14px;
    border-radius: 999px;
    background: var(--faq-soft);
    color: var(--faq-primary);
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
}

.question-list {
    display: grid;
    gap: 12px;
}

.question-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    padding: 18px 20px;
    border-radius: 20px;
    border: 1px solid rgba(148, 163, 184, 0.18);
    background: #fff;
    transition: transform 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.question-card:hover {
    transform: translateY(-2px);
    border-color: rgba(0, 102, 255, 0.24);
    box-shadow: 0 16px 28px rgba(15, 23, 42, 0.08);
}

.question-text {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-strong);
}

.question-text i {
    flex: 0 0 auto;
    color: var(--faq-primary);
    font-size: 18px;
}

.question-meta {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--faq-primary);
    font-size: 14px;
    font-weight: 700;
    white-space: nowrap;
}

.empty-state {
    padding: 48px 24px;
    border-radius: 24px;
    background: var(--surface-muted);
    text-align: center;
    color: var(--text-muted);
}

.hidden {
    display: none !important;
}

.footer {
    background: #0f172a;
    color: #94a3b8;
    padding: 58px 0 30px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    gap: 24px;
    padding-bottom: 34px;
    border-bottom: 1px solid rgba(148, 163, 184, 0.16);
}

.footer-col {
    flex: 1;
}

.footer-col:first-child {
    flex: 1.6;
}

.footer-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    font-size: 26px;
    color: #fff;
    font-weight: 800;
}

.footer-col p,
.footer-col li,
.footer-col a {
    font-size: 14px;
    line-height: 1.9;
    color: #94a3b8;
}

.footer-col h4 {
    margin-bottom: 14px;
    color: #fff;
    font-size: 16px;
}

.footer-col ul {
    list-style: none;
}

.footer-col a:hover {
    color: #fff;
}

.copyright {
    padding-top: 24px;
    text-align: center;
    font-size: 13px;
    line-height: 1.8;
    color: #94a3b8;
}

.copyright a {
    color: #94a3b8;
}

.back-to-top {
    position: fixed;
    right: 28px;
    bottom: 28px;
    z-index: 999;
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    color: #fff;
    background: linear-gradient(135deg, var(--faq-primary), var(--faq-accent));
    box-shadow: 0 14px 30px rgba(0, 102, 255, 0.28);
    cursor: pointer;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity 0.2s ease, visibility 0.2s ease, transform 0.2s ease;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

@media (max-width: 1100px) {
    .faq-layout {
        grid-template-columns: 1fr;
    }

    .side-card {
        position: static;
    }

    .hero-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 1024px) {
    .mobile-overlay {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(0, 0, 0, 0.4);
        z-index: 1000;
        opacity: 0;
        transition: opacity 0.3s;
        pointer-events: none;
    }

    .mobile-overlay.open {
        opacity: 1;
        pointer-events: auto;
    }

    .nav-wrapper {
        width: 100% !important;
        padding: 0 24px;
    }

    .nav-menu {
        display: flex;
        position: fixed;
        top: 0;
        right: 0;
        width: 280px;
        height: 100vh;
        padding: 0;
        flex-direction: column;
        align-items: stretch;
        gap: 0;
        background: #fff;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
        transform: translateX(100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        z-index: 1001;
        overflow-y: auto;
    }

    .nav-menu.open {
        transform: translateX(0);
    }

    .drawer-header {
        display: flex;
        align-items: center;
        justify-content: space-between;
        padding: 20px 20px 16px;
        border-bottom: 1px solid #f0f0f0;
        flex-shrink: 0;
    }

    .drawer-logo {
        display: flex;
        align-items: center;
        gap: 8px;
        font-size: 16px;
        font-weight: 700;
        color: var(--faq-primary);
        text-decoration: none;
    }

    .drawer-logo i {
        font-size: 20px;
    }

    .drawer-close,
    .mobile-menu-btn {
        display: flex;
        align-items: center;
        justify-content: center;
        border: none;
        background: none;
        cursor: pointer;
    }

    .drawer-close {
        width: 32px;
        height: 32px;
        border-radius: 50%;
        color: #666;
        background: none;
        font-size: 20px;
        transition: background 0.2s;
    }

    .drawer-close:hover {
        background: #f5f5f5;
    }

    .mobile-menu-btn {
        display: flex;
        flex-direction: column;
        justify-content: space-between;
        width: 28px;
        height: 20px;
        background: none;
        border: none;
        cursor: pointer;
        padding: 0;
        z-index: 1001;
    }

    .mobile-menu-btn span {
        display: block;
        width: 100%;
        height: 2px;
        background: #333;
        border-radius: 2px;
        transition: all 0.3s;
    }

    .nav-item {
        display: block;
        height: auto;
        padding: 16px 20px;
        border-bottom: 1px solid #f5f5f5;
        width: 100%;
        box-sizing: border-box;
    }

    .nav-item .arrow {
        float: right;
        margin-left: auto;
    }

    .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        border: none;
        border-top: 1px solid #f0f0f0;
        padding: 5px 0 5px 20px;
        display: none;
        width: 100%;
        background: #fafafa;
        min-width: 0;
        margin-top: 0;
        left: 0;
        border-radius: 0;
    }

    .nav-item:hover .dropdown {
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none;
    }

    .nav-item.sub-open .dropdown {
        display: block;
    }

    .dropdown-item {
        padding: 12px 24px;
        border-radius: 0;
    }

    .panel-toolbar {
        flex-direction: column;
        align-items: flex-start;
    }

    .footer-content {
        flex-direction: column;
    }
}

@media (max-width: 768px) {
    .container,
    .nav-wrapper,
    .footer-content,
    .copyright {
        width: min(100% - 28px, 1200px);
    }

    .page-main {
        padding-top: 92px;
    }

    .faq-shell {
        padding-top: 18px;
    }

    .hero {
        padding: 18px 0 24px;
    }

    .hero-panel,
    .faq-panel,
    .side-card {
        padding: 22px;
        border-radius: 24px;
    }

    .side-card,
    .faq-panel,
    .faq-section {
        min-width: 0;
    }

    .hero-title {
        font-size: 30px;
    }

    .hero-desc,
    .section-header p,
    .panel-desc {
        font-size: 15px;
    }

    .section-header,
    .question-card {
        flex-direction: column;
        align-items: flex-start;
    }

    .search-meta {
        flex-wrap: wrap;
        gap: 8px;
    }

    .category-nav {
        display: flex;
        overflow-x: auto;
        gap: 10px;
        padding-bottom: 4px;
        scroll-snap-type: x proximity;
        -webkit-overflow-scrolling: touch;
    }

    .category-nav::-webkit-scrollbar {
        display: none;
    }

    .category-link,
    .category-empty {
        flex: 0 0 auto;
        min-width: 140px;
        scroll-snap-align: start;
    }

    .panel-toolbar .toolbar-link {
        width: 100%;
        justify-content: center;
    }

    .section-header h3 {
        font-size: 22px;
    }

    .question-text {
        width: 100%;
        font-size: 15px;
    }

    .question-meta {
        width: 100%;
        justify-content: flex-end;
    }

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

@media (max-width: 480px) {
    .container,
    .nav-wrapper,
    .footer-content,
    .copyright {
        width: calc(100% - 20px);
    }

    .hero-panel,
    .faq-panel,
    .side-card,
    .faq-section {
        padding: 18px;
        border-radius: 20px;
    }

    .hero-title {
        font-size: 26px;
    }

    .panel-title {
        font-size: 22px;
    }

    .question-card {
        padding: 16px;
    }

    .question-text {
        font-size: 14px;
    }
}
