:root {
    --primary-color: #FFD700;  /* 主颜色 */
    --btn-color: #3e13af;  /* 按钮颜色 */
    --secondary-color: #2ecc71;  /* 绿色 */
    --text-color: #333333;  /* 文字颜色 */
    --background-color: #f4f4f4;  /* 背景颜色 */
}

html {
    width: 100%;
    height: 100%;
}

body {
    width: 100%;
    height: 100%;
    margin: 0;
    /* overflow: hidden; */
}

/* 侧边栏样式 */
.sidebar {
    height: 100%;
    width: 16%;
    position: fixed;
    top: 0;
    left: 0;
    background-color: var(--primary-color);
    padding: 1rem;
    transition: all 0.3s;
}
.sidebar .nav-link {
    color: #fff;
}
.sidebar .nav-link:hover {
    color: #ddd;
}
.sidebar .nav-item {
    margin-bottom: 15px;
}

.top-nav-bg {
    background-color: var(--primary-color) !important;
}

/* 页面主体内容 */
.content {
    /* padding: 0 1rem 1rem 1rem; */
    height: 100%;
}
/* 在小屏幕时隐藏左侧菜单，顶部导航栏代替 */
@media (max-width: 992px) {
    .sidebar {
        display: none;
    }
    .content {
        margin-left: 0;
    }
}

a {
    text-decoration: none;
}

.home-left-column {
    display: flex;               /* 启用 flexbox 布局 */
    flex-direction: column;      /* 使子元素垂直排列 */
    justify-content: space-between; /* 在容器中使内容分布在顶部和底部 */
    height: 100%;                /* 使容器占满父元素的高度 */
}

.home-left-column .title {
    text-align: center;
    padding: 20px;
    margin: 0;                   /* 去除默认的 margin 使标题紧贴顶部 */
}

.vertical-text {
    writing-mode: vertical-rl; /* 竖向排列，右到左 */
    text-align: center;        /* 文本居中对齐 */
    display: inline-block;     /* 确保它是行内块级元素 */
    font-size: 4rem;
    color: #000;
    letter-spacing: 0.2em;       /* 设置字间距 */
    white-space: nowrap;         /* 防止文本换行 */
}

.logo {
    margin-top: auto;            /* 使图片保持在容器的底部 */
    margin: auto;
}

canvas {
    display: block;
}

.container {
    height: 100vh;
}

.left-column {
    background-color: var(--primary-color);
}

/* Ensure the upper part has proper height */
.upper-part {
    height: 100%;
    padding: 0;
}

/* .main-part {
    height: 70vh;
    overflow: auto;
} */

.main-title {
    font-weight: bold;
    letter-spacing: .25rem;
    padding: .5rem;
    border-bottom: .3rem solid var(--primary-color);
    max-width: 100%;
    display: inline-block;
    white-space: nowrap;
    overflow-x: auto;
    text-overflow: ellipsis;
}

.main-title-no-border {
    font-weight: bold;
    letter-spacing: .25rem;
}

/* 搜索结果列表 */
ul {
    list-style-type: none;
    padding-left: 0;
}

.search-results h2 {
    font-size: 20px;
    margin-bottom: 20px;
    color: #495057;
}

.search-results h3,
.search-results h4 {
    color: #495057;
}

.sentence {
    cursor: pointer;
    font-size: 14px;
    font-family: Arial, Helvetica, sans-serif;
    color: #495057;
}

.sentence:hover {
    font-weight: bold;
    color: #000;
}

.srt {
    cursor: pointer;
    font-size: 14px;
    font-family: Arial, Helvetica, sans-serif;
    color: #495057;
}

.srt:hover {
    font-weight: bold;
    color: #000;
}

.highlight {
    text-decoration: underline solid var(--primary-color); /* 设置波浪线和颜色 */
    text-decoration-thickness: 4px; /* 调整波浪线的厚度 */
    margin: 0 5px;
}

em {
    background-color: var(--primary-color);
    text-decoration: underline;
    margin: 0 5px;
}

/* 双下划线样式 */
.double-underline {
    position: relative;
    display: inline-block;
    font-size: 20px; /* 设置字体大小 */
}

.double-underline::before,
.double-underline::after {
    content: '';
    position: absolute;
    left: 0;
    width: 100%;  /* 下划线的宽度与文字一致 */
    height: 1px;  /* 下划线的厚度 */
    background-color: black;  /* 下划线的颜色 */
}

.double-underline::before {
    bottom: 0;  /* 第一条下划线紧挨文字的底部 */
}

.double-underline::after {
    bottom: -4px;  /* 设置与文字之间的距离 */
}

/* 文章内容区域 */
.article-content {
    height: 100vh;
    overflow-y: auto; /* 只对文章内容区域启用滚动条 */
    padding: 20px;
}

.p {
    margin-bottom: 5px !important;
    display: inline-block; /* 使 p 标签的宽度根据内容自动调整 */
}

/* 优化高亮部分 */
.highlight-text {
    background-color: var(--primary-color);
    padding: 0 5px;
    font-weight: bold;
}

.no-results {
    font-size: 18px;
    color: #6c757d;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .left-column {
        display: none;
    }

    .col-10 {
        padding: 20px;
    }

    h2 {
        font-size: 20px;
    }

    .sentence {
        font-size: 14px;
    }
}

.hot-search-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px; /* 每个项之间的间距 */
}

.hot-search-item,.group-list {
    display: inline-block;
    margin-right: 10px; /* 右边的间距 */
    color: #007bff; /* 设置链接颜色 */
    text-decoration: none; /* 去掉下划线 */
}

.hot-search-list a:not(:last-child)::after {
    content: "；"
}

.more-info {
    font-style: italic;
    color: gray;
}

.introduction {
    padding: 1rem 2rem;
    overflow: hidden;
}

.select-regular {
    cursor: pointer;
    padding-right: 1em;
    max-width: 100%;
    color: #fff;
    background-image: url(data:image/svg+xml;charset=utf-8;base64,PHN2ZyB2aWV3Qm94PScwIDAgMTAyNCAxMDI0JyB4bWxucz0naHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmcnIHdpZHRoPScyMDAnIGhlaWdodD0nMjAwJz48cGF0aCBkPSdNNzIxLjc5NCAzODQuMTE2bC02MC45NDMgNjAuOTQ0LTIxMS4xOS0yMTEuMTkgNjAuOTQ0LTYwLjk0M3onIGZpbGw9JyNmZmYnLz48cGF0aCBkPSdNMjk5LjMxNyAzODMuOTg4bDYwLjk0MyA2MC45NDMgMjExLjE5LTIxMS4xOS02MC45NDQtNjAuOTQyek0zMDEuOSA2MzkuNTk0bDYwLjk0NC02MC45NDQgMjExLjE4OSAyMTEuMTktNjAuOTQzIDYwLjk0M3onIGZpbGw9JyNmZmYnLz48cGF0aCBkPSdNNzI0LjM5MSA2MzkuNzNsLTYwLjk0My02MC45NDMtMjExLjE5IDIxMS4xODkgNjAuOTQ0IDYwLjk0M3onIGZpbGw9JyNmZmYnLz48L3N2Zz4=);
    background-repeat: no-repeat;
    background-position: center right;
    background-size: 1em;
    margin-right: .5em;
}

.select-regular:hover, .select-regular:focus {
    font-weight: bolder;
}

select {
    border-style: none;
    border-radius: .25em;
    background-color: #fff;
    line-height: 200%;
    font-size: 100%;
    -moz-appearance: none;
    -webkit-appearance: none;
    appearance: none;
}

select:focus {
    outline: none; /* 去掉焦点时的默认边框 */
  }

#search input {
    background: #e1e2e1;
}

/* #searchNav {
    padding: .5rem 0;
} */

input:not([type=radio]), button, textarea {
    border-style: none;
    border-radius: .25rem;
    background-color: #e1e2e1;
    padding: 0 .5rem;
    line-height: 200%;
    font-size: 100%;
    -moz-appearance: none;
    -webkit-appearance: none;
    appearance: none;
}
input {
    border: 1px rgba(0, 0, 0, .1) solid !important;
    line-height: calc(2em - 2px) !important;
}

#search button:hover {
    font-weight: bold;
}
#search button {
    color: #fff;
    background-color: var(--btn-color);
    position: relative;
}
input:not([type=radio]), button, textarea {
    border-style: none;
    border-radius: .25rem;
    background-color: #e1e2e1;
    padding: 0 .5rem;
    line-height: 200%;
    font-size: 100%;
    -moz-appearance: none;
    -webkit-appearance: none;
    appearance: none;
}

.flex {
    display: flex;
}

.main-part .others a:not(:last-of-type) {
    padding-right: 1rem;
}

.main-part .external_links a:not(:last-of-type) {
    padding-right: 1rem;
}

.main-part a {
    line-height: 200%;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    letter-spacing: .25rem;
    font-family: 'Hei';
    text-decoration: none;
    color: var(--btn-color);
}

.main-part a:visited {
    color: #24096b
}

.main-part a:hover {
    font-weight: 600;
}

.nav-list a {
    line-height: 200%;
    white-space: nowrap;
    text-overflow: ellipsis;
    overflow: hidden;
    letter-spacing: .25rem;
    font-family: 'Hei';
    text-decoration: none;
    color: var(--btn-color);
}

.nav-list a:visited {
    color: #24096b
}

.nav-list a:hover {
    font-weight: 600;
}

.nav-title {
    color: #000;
    letter-spacing: 0.2em;
    white-space: nowrap;
}

.nav-title a {
    color: #000;
    letter-spacing: 0.2em;
    white-space: nowrap;
}

.icp {
    color: #000 !important;
    display: block;
    width: 100%;
    white-space: nowrap !important;
    text-overflow: ellipsis !important;
    overflow: hidden !important;
    letter-spacing: 0 !important;
    font-size: 80%;
    border-radius: .5rem;
    margin: .15rem 0 0 -0.25rem;
    padding: .25rem;
    text-align: center;
}

.text-right {
    text-align: right;
}

#download * a {
    text-decoration: none;
    color: var(--btn-color);
    cursor: pointer;
    border-radius: 0.25em;
    display: inline-block;
}

#download * a:hover {
    background-color: #f5f5f6;
    margin-top: -0.25em !important;
    padding-top: 0.25em !important;
    margin-bottom: -0.25em !important;
    padding-bottom: 0.25em !important;
}

#download * a:active {
    background-color: var(--primary-color);
    color: #ffffff;
}