html {
    height: 100%;
    width: 100%;
    font-family: 'Microsoft YaHei', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    font-size: 18px;
}

p {
    line-height: 1.2em;
}

h3 {
    font-size: 28px;
    line-height: 30px;
    height: 30px;
    margin: 40px 0 10px 0;
    text-indent: 20px;
}


a {
    outline: none;
    text-decoration: none;
    color: blueviolet;
}

a:hover {
    text-decoration: none;
    color: goldenrod;
}

ul {
    line-height: 30px;
}

li {
    list-style: none;
    line-height: 2em;
}

code {
    font-family: 'Fira Code', 'JetBrains Mono', 'Consolas', monospace;
    line-height: 1.6;
    font-variant-ligatures: contextual;
}

code ul, code li{
    list-style: none;
    width: 97%;
}


.boldRed{
    color: red;
    font-weight: bold;
}

.paddle24px{
    padding-left:24px;
}

.txtBold{
    font-weight: bold;
}

.italic{
    font-style: italic;
}

#Header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 40px;
    background-color: #333;
    color: #fff;
    z-index: 999;
}

#Header a {
    color: #fff;
}

#Header a:hover {
    color: #fff;
}

#Header .logo {
    float: left;
    width: 200px;
    height: 40px;
    line-height: 40px;
    text-align: center;
}

#Container {
    position: relative;
    width: 95%;
    max-width: 1280px;
    min-width: 480px;
    margin: 0 auto;
    transition: margin-left 0.3s ease;    /* 添加过渡效果 */
}

#ErrorMessage {
    color: red;
    line-height: 40px;
}

.hidden {
    /* visibility: hidden; */
    display: none !important;
}


#question-container li {
    list-style-type: decimal;
}

#LectureTitle {
    text-indent: 10px;
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    /* 允许子元素换行 */
    padding: 30px 0;
    /* 容器内边距 */
}

#LectureName {
    font-size: 40px;
    font-weight: bold;
    margin: 0;
    /* 清除默认外边距 */
    min-width: 0;
    /* 允许内容缩小 */
    align-self: flex-end;
    /* 强制底部对齐 */
    flex-shrink: 0;
    /* 防止缩小 */
}

#LectureType {
    font-size: 32px;
    background-color: antiquewhite;
    margin: 0 15px;
    align-self: flex-end;
    /* 强制底部对齐 */
    flex-shrink: 0;
    /* 防止缩小 */
}

#QuestionLink,
#QuestionLink a {
    font-size: 18px;
    font-weight: bold;
    align-self: flex-end;   /* 强制底部对齐 */
    flex-shrink: 1;  /* 允许缩小以换行 */
}

#LectureAuthor, #LectureVersion, #LectureDes, #QuestionUpdatetime  {
    text-indent: 10px;
    line-height: 28px;
}

#LectureAuthor, #LectureVersion {
    color:blue;
}

#LectureDes {
    color:red;
}

#intro{
    margin-top:30px;
    color:indigo;
    font-size:20px;
    text-indent: 20px;
}

#QuestionUpdatetime {
    font-weight: 800;
    height: 40px;
    margin: 10px 0;
}

/************** 问题 ***************/
.question {
    margin: 20px;
    padding: 15px;
    border: 1px solid #ddd;
}

.title {
    font-weight: bold;
    margin-bottom: 10px;
    line-height: 32px;
    text-align: justify;
}

.answer {
    margin-top: 10px;
    margin: 20px 0 10px 0;
    font-weight: bold;
    /* display: none;   */
}

.explanation {
    margin: 10px 0;
    line-height: 32px;
    max-width: 99%;
    /* display: none; */
    text-align: justify;
}

.explanation li {
    list-style-type: disc;
    list-style-position: inside;
    line-height: 32px;
}



/* 表格基础样式 */
.explanation table, .title table {
    width: auto;
    border-collapse: collapse;
    /* 去掉单元格间的间隙 */
    margin: 20px 0;
    text-align: left;
    min-width: 300px;
}

/* 表格边框样式 */
.explanation th, .explanation td, .title th, .title td {
    border: 1px solid #ddd;    /* 单元格边框 */
    padding: 10px;    /* 内边距 */
    text-align: center;
    white-space: nowrap;    /* 可选：防止内容换行，使表格更紧凑 */
    min-width: 30px;
}

/* 表头样式 */
.explanation th, .title th{
    background-color: #f4f4f4;    /* 表头背景色 */
    font-weight: bold;    /* 表头文字加粗 */
}

/* 表格行隔色 */
.explanation tr:nth-child(even), .title tr:nth-child(even){
    background-color: #f9f9f9;    /* 偶数行背景色 */
}

.explanation tr:hover, .title tr:hover{
    background-color: #f1f1f1;    /* 鼠标悬停行背景色 */
    transition: background-color 0.3s ease;    /* 平滑过渡效果 */
}


/* 可选：让表格在小屏幕上也能正常显示 */
@media (max-width: 600px) {
    .explanation table, .explanation th, .explanation td, .title table, .title th, .title td {
        font-size: 14px;        /* 缩小字体 */
        padding: 8px;        /* 缩小内边距 */
    }
}


/******** 代码块 *************************/

.autoULOptions {
    font-weight: normal;
    background-color: whitesmoke;
    margin: 10px;
    padding: 10px;
    counter-reset: linenumber;   /* 定义并重置计数器 linenumber */
}

.autoULOptions ul {
    list-style: none;
    position: relative;
    margin: 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
}


.autoULOptions li {
    line-height: 28px;
    border-left: 1px solid silver; /* 添加一条灰色直线 */
    margin-left: 20px;
    text-indent: 14px;
    position: relative; /* 确保伪元素定位基于 li */
    list-style-type: none;
    white-space: nowrap;
}


.autoULOptions li::before {
    counter-increment: linenumber; /* 每次遇到 li 元素时，计数器加 1 */
    content: counter(linenumber); /* 显示计数器的值 */
    position: absolute; /* 将行号从正常流中分离 */
    left: -36px; /* 调整行号的位置，使其与灰色直线对齐 */
    text-align: right; /* 行号右对齐 */
    width: 20px;
    font-size: 14px; /* 行号的字体大小 */
    color: gray; /* 行号的颜色 */
    display: inline-block; /* 确保伪元素是一个块级容器，支持 text-align */
}

.annotation, .inline-annotation, .title-annotation {
    color:#666;
    flex:0 0 25%;
}

.title-annotation {
    font-style: italic;
    font-weight: bold;
    font-size:16px;
}

.annotation{
    font-size:20px;
}

.inline-annotation {
    padding-left: 50px;
    position: absolute;
    left: 350px;
}

.code-step ul, .code-step li {
    list-style: none;
}

