|
| 1 | +/* 其他 CSS 样式 */ |
| 2 | +@import url('./highlight/styles/stackoverflow-dark.min.css'); |
| 3 | + |
| 4 | +@font-face { |
| 5 | + font-family: 'Noto Serif SC'; |
| 6 | + src: url('./font/NotoSerifSC-VariableFont_wght.ttf') format('truetype'); |
| 7 | + font-weight: normal; |
| 8 | + font-style: normal; |
| 9 | +} |
| 10 | + |
| 11 | +body { |
| 12 | + font-family: 'Noto Serif SC', sans-serif; |
| 13 | + line-height: 1.6; |
| 14 | + margin: 0 auto; |
| 15 | + max-width: 85%; |
| 16 | + padding: 30px; |
| 17 | + background-color: #1a1a1a; |
| 18 | + /* Dark background color */ |
| 19 | + color: #e0e0e0; |
| 20 | + /* Light text color */ |
| 21 | +} |
| 22 | + |
| 23 | + |
| 24 | + |
| 25 | +pre { |
| 26 | + background-color: #2b2b2b; |
| 27 | + /* Darker background for code blocks */ |
| 28 | + border-left: 5px solid #c365df; |
| 29 | + margin-bottom: 20px; |
| 30 | + border-radius: 5px; |
| 31 | + box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); |
| 32 | + overflow-x: auto; |
| 33 | + position: relative; |
| 34 | +} |
| 35 | + |
| 36 | +code { |
| 37 | + font-family: Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace; |
| 38 | + font-size: 14px; |
| 39 | + color: #e0e0e0; |
| 40 | + /* Light text color for code */ |
| 41 | +} |
| 42 | + |
| 43 | +blockquote { |
| 44 | + border-radius: 5px; |
| 45 | + background-color: #333333; |
| 46 | + border-left: 5px solid #ccc; |
| 47 | + padding: 10px; |
| 48 | + margin-left: 0; |
| 49 | +} |
| 50 | + |
| 51 | +table { |
| 52 | + width: 100%; |
| 53 | + border-collapse: collapse; |
| 54 | + margin-bottom: 20px; |
| 55 | + border: 1px solid #555; |
| 56 | + /* Border color for tables */ |
| 57 | + border-radius: 10px; |
| 58 | +} |
| 59 | + |
| 60 | +.directory-menu li { |
| 61 | + color: #e0e0e0; |
| 62 | + /* White text color for list items */ |
| 63 | +} |
| 64 | + |
| 65 | +th, |
| 66 | +td { |
| 67 | + border: 1px solid #555; |
| 68 | + /* Border color for table cells */ |
| 69 | + padding: 8px; |
| 70 | + text-align: left; |
| 71 | + color: #e0e0e0; |
| 72 | + /* Light text color for table cells */ |
| 73 | +} |
| 74 | + |
| 75 | +img { |
| 76 | + max-width: 90%; |
| 77 | + max-height: 90%; |
| 78 | + height: auto; |
| 79 | + display: block; |
| 80 | + margin: auto; |
| 81 | + border-radius: 5px; |
| 82 | + box-shadow: 0 0 5px rgba(0, 0, 0, 0.1); |
| 83 | +} |
| 84 | + |
| 85 | +hr { |
| 86 | + border: none; |
| 87 | + border-top: 2px dashed #a5a4ad; |
| 88 | + height: 1px; |
| 89 | + margin: 20px 0; |
| 90 | + border-color: #555; |
| 91 | + /* Color for dashed horizontal rule */ |
| 92 | +} |
| 93 | + |
| 94 | +.md-p { |
| 95 | + display: block; |
| 96 | + margin-block-start: 1em; |
| 97 | + margin-block-end: 1em; |
| 98 | + margin-inline-start: 0px; |
| 99 | + margin-inline-end: 0px; |
| 100 | + unicode-bidi: isolate; |
| 101 | +} |
| 102 | + |
| 103 | +.hljs-ln { |
| 104 | + position: absolute; |
| 105 | + left: -16px; |
| 106 | + padding: 8px 0 8px 0; |
| 107 | + pointer-events: none; |
| 108 | + user-select: none; |
| 109 | +} |
| 110 | + |
| 111 | +.hljs-ln td { |
| 112 | + padding-right: 10px; |
| 113 | + text-align: right; |
| 114 | +} |
| 115 | + |
| 116 | +/* 暗黑主题下白色目录 */ |
| 117 | +/* New styles for sidebar links */ |
| 118 | +.col-md-4 a { |
| 119 | + color: #e0e0e0; |
| 120 | + /* White text color */ |
| 121 | + text-decoration: none; |
| 122 | + display: block; |
| 123 | +} |
| 124 | + |
| 125 | + |
| 126 | +.col-md-4 a:hover, |
| 127 | +.col-md-4 a:focus { |
| 128 | + color: #e0e0e0; |
| 129 | +} |
| 130 | + |
| 131 | +/* Style for specific link */ |
| 132 | +.col-md-4 a.d-flex span { |
| 133 | + color: #e0e0e0; |
| 134 | +} |
| 135 | + |
| 136 | +/* Style for list item links */ |
| 137 | +.col-md-4 li a { |
| 138 | + color: #e0e0e0; |
| 139 | + /* White text color */ |
| 140 | + text-decoration: none; |
| 141 | + display: block; |
| 142 | +} |
| 143 | + |
| 144 | +.col-md-4 li a:hover, |
| 145 | +.col-md-4 li a:focus { |
| 146 | + color: #e0e0e0; |
| 147 | + /* Gray text color on hover/focus */ |
| 148 | + background-color: #333; |
| 149 | + /* Background color on hover/focus */ |
| 150 | +} |
| 151 | + |
| 152 | +/* Style for collapse links */ |
| 153 | +.btn-toggle-nav li a { |
| 154 | + color: #e0e0e0 !important; |
| 155 | + /* White text color */ |
| 156 | + text-decoration: none; |
| 157 | +} |
| 158 | + |
| 159 | +.btn-toggle-nav li a:hover, |
| 160 | +.btn-toggle-nav li a:focus { |
| 161 | + color: #e0e0e0 !important; |
| 162 | + /* Gray text color on hover/focus */ |
| 163 | + background-color: #333; |
| 164 | + /* Background color on hover/focus */ |
| 165 | + border-radius: 5px; |
| 166 | +} |
| 167 | + |
| 168 | +.text-body-secondary { |
| 169 | + --bs-text-opacity: 1; |
| 170 | + color: #e0e0e0 !important; |
| 171 | +} |
| 172 | + |
| 173 | +/* 鼠标悬停灰色 */ |
| 174 | +.col-md-4 a.d-inline-flex:hover, |
| 175 | +.col-md-4 a.d-inline-flex:focus { |
| 176 | + color: #e0e0e0; |
| 177 | + /* White text color on hover/focus */ |
| 178 | + background-color: #6c757d; |
| 179 | + /* Gray background color on hover/focus */ |
| 180 | + border-radius: 5px; |
| 181 | +} |
| 182 | + |
| 183 | +/* Additional style for specific button */ |
| 184 | +.col-md-4 a.d-inline-flex.active, |
| 185 | +.col-md-4 a.d-inline-flex:active { |
| 186 | + background-color: #6c757d; |
| 187 | + /* Gray background color on active state */ |
| 188 | + color: #e0e0e0; |
| 189 | + /* White text color on active state */ |
| 190 | +} |
| 191 | + |
| 192 | +.btn.d-inline-flex.align-items-center.rounded.border-0:hover { |
| 193 | + background-color: #6c757d; |
| 194 | +} |
| 195 | + |
| 196 | +/* p 标签内容剧中 */ |
| 197 | +.md-p { |
| 198 | + display: block; |
| 199 | + margin-block-start: 1em; |
| 200 | + margin-block-end: 1em; |
| 201 | + margin-inline-start: 0px; |
| 202 | + margin-inline-end: 0px; |
| 203 | + unicode-bidi: isolate; |
| 204 | +} |
| 205 | + |
| 206 | +/* 目录菜单悬浮 */ |
| 207 | +.col-md-4 { |
| 208 | + position: -webkit-sticky; |
| 209 | + position: sticky; |
| 210 | + top: 0; |
| 211 | + height: 100%; |
| 212 | + overflow-y: auto; |
| 213 | +} |
| 214 | + |
| 215 | +/* Media Queries for Responsive Design */ |
| 216 | +@media (max-width: 768px) { |
| 217 | + body { |
| 218 | + max-width: 100%; |
| 219 | + padding: 10px; |
| 220 | + } |
| 221 | + |
| 222 | + .container { |
| 223 | + display: flex; |
| 224 | + flex-direction: column; |
| 225 | + } |
| 226 | + |
| 227 | + .col-md-4 { |
| 228 | + position: relative; |
| 229 | + height: auto; |
| 230 | + overflow-y: visible; |
| 231 | + width: 100%; |
| 232 | + padding: 10px; |
| 233 | + margin-bottom: 20px; |
| 234 | + } |
| 235 | + |
| 236 | + .flex-shrink-0 { |
| 237 | + display: block; |
| 238 | + } |
| 239 | + |
| 240 | + .content { |
| 241 | + width: 100%; |
| 242 | + } |
| 243 | + |
| 244 | + .col-md-8 { |
| 245 | + width: 100%; |
| 246 | + } |
| 247 | +} |
0 commit comments