/* =========================================
   全局基础与重置
   ========================================= */
* { 
    margin: 0; 
    padding: 0; 
    box-sizing: border-box; 
}

body {
    font-family: "PingFang SC", "微软雅黑", "Microsoft YaHei", "Inter", sans-serif;
    background-color: #FFFFFF;
    color: #1E293B;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

::-webkit-scrollbar { width: 6px; height: 6px; }
::-webkit-scrollbar-track { background: #F1F5F9; }
::-webkit-scrollbar-thumb { background: #CBD5E1; border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: #94A3B8; }

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

/* =========================================
   顶部导航栏 (Header)
   ========================================= */
.app-header {
    background-color: #FFFFFF;
    border-bottom: 1px solid #E2E8F0;
    height: 56px; 
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 40px;
    z-index: 1000; 
    position: sticky;
    top: 0;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.logo-area {
    display: flex;
    align-items: center;
    height: 100%;
}
.logo-img {
    height: 26px; 
    max-width: 320px;
    width: auto;
    object-fit: contain;
    display: block;
}
.logo-text-fallback {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1E293B;
    letter-spacing: 1px;
    background: linear-gradient(90deg, #E63946, #F59E0B, #10B981, #3B82F6);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.nav-area { display: flex; align-items: center; gap: 32px; height: 100%; }

.nav-primary-item {
    position: relative; display: flex; align-items: center; height: 100%;
    cursor: pointer; 
    font-size: 14px; 
    font-weight: 600; 
    color: #1E293B; 
    transition: all 0.2s; padding: 0 4px;
}

.nav-primary-item:hover { color: #E63946; }
.nav-primary-active { color: #E63946; font-weight: 600; }
.nav-primary-active::after {
    content: ''; position: absolute; bottom: 0; left: 0;
    width: 100%; height: 3px; background-color: #E63946;
}

/* 下拉菜单 */
.dynamic-submenu-wrapper {
    position: absolute; top: 56px; left: 50%; transform: translateX(-50%);
    background: #FFFFFF; min-width: 160px;
    box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 8px 10px -6px rgba(0, 0, 0, 0.1);
    border: 1px solid #E2E8F0; border-top: none;
    display: flex; flex-direction: column; z-index: 100;
    animation: fadeInDown 0.2s ease;
}

.submenu-item {
    padding: 12px 20px; font-size: 14px; color: #1E293B;
    cursor: pointer; transition: all 0.2s; white-space: nowrap; text-align: center;
}
.submenu-item:hover { background-color: #F8FAFC; color: #E63946; }
.submenu-active { color: #E63946; font-weight: 500; background-color: #FEF2F2; }

/* 右侧操作区 */
.header-actions { display: flex; align-items: center; gap: 20px; font-size: 14px; font-weight: 600; }

.action-item {
    display: flex;
    align-items: center;
    gap: 6px;
    color: #1E293B;
    cursor: pointer;
    transition: color 0.2s;
    font-weight: 600;
    font-size: 14px;
}
.action-item:hover { color: #E63946; }
.action-item .action-icon { font-size: 15px; }

.action-ai { color: #1E293B; font-weight: 600; }
.action-ai:hover { color: #E63946; }

.action-login { color: #1E293B; cursor: pointer; font-weight: 600; font-size: 14px; }
.action-login:hover { color: #E63946; }

/* 服务按钮与面板 */
.service-dropdown-container { position: relative; }

.service-btn {
    background-color: #F8FAFC;
    color: #1E293B;
    padding: 7px 16px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    border: 1px solid #E2E8F0;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.2s;
}
.service-btn:hover {
    background-color: #F1F5F9;
    border-color: #CBD5E1;
}

.service-panel {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 400px;
    background: #FFFFFF;
    border-radius: 12px;
    box-shadow: 0 10px 40px -10px rgba(0, 0, 0, 0.15), 0 4px 12px rgba(0, 0, 0, 0.05);
    border: 1px solid #E2E8F0;
    padding: 16px 0 8px;
    display: none;
    flex-direction: column;
    z-index: 1000;
    animation: fadeInDown 0.2s ease;
    max-height: 85vh;
    overflow-y: auto;
}
.service-panel.show { display: flex; }

.panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0 20px 16px;
    border-bottom: 1px solid #F1F5F9;
    margin-bottom: 8px;
}
.panel-header-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 16px;
    color: #1E293B;
}
.panel-close-btn {
    background: transparent;
    border: none;
    color: #94A3B8;
    cursor: pointer;
    font-size: 16px;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.2s;
}
.panel-close-btn:hover {
    background: #F1F5F9;
    color: #1E293B;
}

.panel-group {
    padding: 8px 0;
    border-bottom: 1px solid #F1F5F9;
}
.panel-group:last-child { border-bottom: none; }
.group-title {
    font-size: 12px;
    color: #94A3B8;
    padding: 4px 20px 8px;
    font-weight: 500;
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 10px 20px;
    cursor: pointer;
    transition: background 0.2s;
    color: inherit;
    text-decoration: none;
}
.menu-item:hover { background-color: #F8FAFC; }
.menu-icon-box {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: #F8FAFC;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 14px;
    color: #1E293B;
    font-size: 16px;
    flex-shrink: 0;
}
.menu-item-content { flex: 1; }
.menu-item-title { font-size: 14px; font-weight: 600; color: #1E293B; }
.menu-item-desc { font-size: 12px; color: #94A3B8; margin-top: 2px; }
.menu-item-arrow { color: #CBD5E1; font-size: 12px; }
.badge {
    background: #F1F5F9;
    color: #475569;
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 12px;
    font-weight: 600;
}

/* =========================================
   通用动画
   ========================================= */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* 跑马灯动画 */
@keyframes marquee {
    0% { transform: translateX(0); }
    100% { transform: translateX(-50%); }
}
.marquee-content {
    display: inline-flex;
    white-space: nowrap;
    animation: marquee 20s linear infinite;
}
.marquee-content:hover {
    animation-play-state: paused;
}

/* 隐藏滚动条 */
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* =========================================
   详情页专用排版 (Event Detail)
   ========================================= */
.article-container {
    max-width: 800px; /* 修正了原来的 max-w 错误 */
    margin: 0 auto;
    padding: 40px 20px 80px;
}
.article-title {
    font-size: 28px;
    font-weight: bold;
    text-align: center;
    line-height: 1.4;
    margin-bottom: 20px;
    color: #1E293B;
}
.article-meta {
    text-align: center;
    font-size: 14px;
    color: #64748B;
    margin-bottom: 40px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
}
.article-content p {
    font-size: 16px;
    line-height: 1.8;
    color: #334155;
    margin-bottom: 20px;
}
.article-content img {
    width: 60%; 
    max-width: 100%;
    border-radius: 8px;
    margin: 30px auto;
    display: block;
}
.article-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 60px;
    padding-top: 20px;
    border-top: 1px solid #E2E8F0;
}
.author-info { display: flex; align-items: center; gap: 12px; }
.author-avatar { width: 40px; height: 40px; border-radius: 50%; background: #E2E8F0; display: flex; align-items: center; justify-content: center; font-weight: bold; color: #64748B;}
.btn-follow {
    background-color: #10B981; color: white; font-size: 12px; padding: 4px 10px; border-radius: 4px; font-weight: bold;
}
.action-icons { display: flex; gap: 24px; color: #64748B; font-size: 14px; }
.action-icons span { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.action-icons span:hover { color: #1E293B; }