/* 全局样式 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: "Songti SC", /* macOS 首选 */ "SimSun", /* Windows 备用 */ "Noto Serif SC", /* Android/现代系统 */ "Georgia", /* 英文首选 */ "Times New Roman", /* 英文备用 */ serif; /* 最终回退 */
    /*font-family: Georgia, Roboto, system-ui, -apple-system, "Segoe UI", Arial, sans-serif;*/
    background: #0d1b2a;
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden; /* 防止水平滚动 */
    position: relative;
}

/* 数字流动背景 */
#digital-rain {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 100; /* 与现有保持一致 */
    opacity: 0.1;
    pointer-events: none;
}

/* 导航栏 */
.navbar {
    background: transparent;
    backdrop-filter: blur(10px);
    padding: 1rem 2rem;
    transition: all 0.3s ease;
    z-index: 200;
}

.navbar-logo {
    width: 180px;
    height: auto;
    transition: transform 0.3s ease;
}

.navbar-logo:hover {
    transform: scale(1.05);
}

.nav-link {
    color: #ff5a00 !important;
    font-size: 1.1rem;
    margin: 0 1rem;
    transition: color 0.3s ease;
}

.nav-link:hover {
    color: #ffea00 !important;
}

/* 下拉菜单 */
.dropdown-menu {
    background: rgba(0, 0, 0, 0.9);
    border: none;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
    padding: 0.5rem 0;
}

.dropdown-item {
    color: #ffffff;
    padding: 0.5rem 1rem;
    transition: background 0.3s ease, color 0.3s ease;
}

.dropdown-item:hover {
    background: #00d4ff;
    color: #0d1b2a;
}

/* 鼠标悬浮显示二级菜单 */
.nav-item.dropdown:hover .dropdown-menu {
    display: block;
}

/* 三级菜单样式 */
.submenu-parent {
    position: relative;
}

.submenu {
    position: absolute;
    top: 0;
    left: 100%;
    background: rgba(0, 0, 0, 0.9);
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0, 212, 255, 0.3);
    display: none;
    min-width: 200px;
    padding: 0.5rem 0;
}

.submenu-parent:hover .submenu {
    display: block;
}

.dropdown-submenu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.dropdown-submenu .dropdown-item {
    padding-left: 2rem; /* 缩进区分层级 */
}

.text-bg-info {
    background: #00d4ff !important;
    color: #0d1b2a !important;
}


/* Footer */
.footer {
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #888;
    font-size: 0.8rem;
}

.footer .tagline {
    justify-content: center;
}

@media (min-width: 1400px) {
    .footer .tagline img {
        width: 40%; /* 或者根据需要调整 */
        max-width: 100%; /* 确保图片不会超出父容器 */
    }
}

@media (max-width: 992px) {
    .footer .tagline img {
        width: 60%; /* 或者根据需要调整 */
        max-width: 100%; /* 确保图片不会超出父容器 */
    }
}
@media (max-width: 512px) {
    .footer .tagline img {
        width: 80%; /* 或者根据需要调整 */
        max-width: 100%; /* 确保图片不会超出父容器 */
    }
}
.footer span {
    margin-left: 8px;
    /*font-size: 26px;*/
    /*font-weight: bold;*/
    /*color: #00ffff;*/
    /*text-shadow: 0 0 10px rgba(255, 255, 220, 0.7);*/
    /*display: flex;*/
    align-items: center;
}

.social-links {
    margin: 20px 0;
}

.social-link {
    display: inline-block;
    width: 40px;
    height: 40px;
    line-height: 40px;
    text-align: center;
    margin: 0 10px;
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transition: all 0.3s;
}

.social-link:hover {
    background: black;
    color: #ff5a00;
    transform: translateY(-3px);
    cursor: pointer;
}

/* 文本提示样式（用于手机和邮箱） */
.social-link:not([data-type="image"])::after {
    content: attr(data-info);
    position: absolute;
    top: -40px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    white-space: nowrap;
}

/* 图片提示样式（用于微信） */
.social-link[data-type="image"]::after {
    content: '';
    position: absolute;
    top: -168px;
    left: 50%;
    transform: translateX(-50%);
    width: 150px;
    height: 168px;
    background-image: url('/static/img/wx.jpg'); /* 替换为实际微信二维码图片URL */
    background-size: cover;
    background-position: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
    border-radius: 5px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.social-link:hover::after {
    opacity: 1;
    visibility: visible;
}


.post-cover-image {
    max-height: 400px;
    width: 100%;
    object-fit: cover;
    display: block; /* 将图片设置为块级元素 */
    margin: 0 auto; /* 水平，垂直居中 */
}

/* 响应式调整 */
@media (max-width: 991px) {
    .dropdown-menu {
        background: rgba(0, 0, 0, 0.8);
    }

    .submenu {
        position: static;
        box-shadow: none;
        padding-left: 1rem;
    }
}

/* 导航栏用户头像和信息 */
.user-info {
    margin: 0 1rem;
    display: flex; /* 改为 inline-flex 与导航项同行 */
    align-items: center; /* 垂直居中 */
    gap: 0.5rem;
    height: 100%;
}

.user-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.user-avatar:hover {
    transform: scale(1.2);
}

.user-name {
    color: #ff5a00;
    font-size: 1.1rem;
    font-weight: 500;
}
