Files
Docs-Viewer/styles.css

419 lines
8.7 KiB
CSS

:root {
--doc-sidebar-width: 300px;
--doc-outline-width: 240px;
--ifm-color-primary: #2196f3;
--ifm-color-primary-dark: #1976d2;
--ifm-background-color: #1a1a1a;
--ifm-background-surface-color: #252526;
--ifm-color-content: #e0e0e0;
--ifm-color-content-secondary: #a0a0a0;
--ifm-link-color: #2196f3;
--ifm-border-color: #404040;
--title-bar-height: 48px;
--sidebar-transition: transform 0.3s ease;
}
body {
margin: 0;
padding: 0;
font-family: system-ui, -apple-system, Segoe UI, Roboto, Ubuntu, Cantarell, Noto Sans, sans-serif;
background: var(--ifm-background-color);
color: var(--ifm-color-content);
}
.container {
display: flex;
flex-direction: column;
height: 100vh;
}
.title-bar {
height: var(--title-bar-height);
background-color: var(--ifm-background-surface-color);
border-bottom: 1px solid var(--ifm-border-color);
display: flex;
align-items: center;
padding: 0 1rem;
font-size: 1.1rem;
font-weight: 500;
color: var(--ifm-color-content);
flex-shrink: 0;
justify-content: space-between;
}
.menu-button {
display: none;
background: none;
border: none;
color: var(--ifm-color-content);
padding: 8px;
cursor: pointer;
font-size: 1.2rem;
}
.menu-button:hover {
color: var(--ifm-color-primary);
}
.content-container {
display: flex;
flex: 1;
overflow: hidden;
}
.sidebar {
background-color: var(--ifm-background-surface-color);
color: var(--ifm-color-content);
overflow-y: auto;
border-color: var(--ifm-border-color);
height: calc(100vh - var(--title-bar-height));
}
.left-sidebar {
width: var(--doc-sidebar-width);
border-right: 1px solid var(--ifm-border-color);
display: flex;
flex-direction: column;
}
#file-index {
flex: 1;
overflow-y: auto;
}
#file-index a {
color: var(--ifm-color-content);
text-decoration: none;
display: block;
padding: 0.4rem 1.2rem;
font-size: 0.875rem;
border-left: 2px solid transparent;
}
#file-index a:hover {
background-color: rgba(0, 0, 0, 0.05);
color: var(--ifm-color-primary);
border-left: 2px solid var(--ifm-color-primary);
}
#file-index a.active {
color: var(--ifm-color-primary);
background-color: rgba(33, 150, 243, 0.1);
border-left: 2px solid var(--ifm-color-primary);
}
.social-links {
padding: 1rem 1rem 0.5rem;
border-top: 1px solid var(--ifm-border-color);
display: flex;
justify-content: center;
gap: 1rem;
flex-wrap: wrap;
}
.social-links a {
color: var(--ifm-color-content-secondary);
font-size: 1.2rem;
transition: color 0.2s;
}
.social-links a:hover {
color: var(--ifm-color-primary);
}
.subtitle {
text-align: center;
padding: 0 1rem 1rem;
font-size: 0.8rem;
color: var(--ifm-color-content-secondary);
border-top: none;
}
.subtitle .name {
color: var(--ifm-color-content);
font-weight: 500;
}
.subtitle .role {
display: block;
font-size: 0.75rem;
margin-top: 0.2rem;
}
.right-sidebar {
width: var(--doc-outline-width);
border-left: none;
background-color: var(--ifm-background-color);
}
.content {
flex: 1;
background-color: var(--ifm-background-color);
padding: 2rem 3rem;
overflow-y: auto;
min-width: 0; /* Fix flexbox content overflow */
color: var(--ifm-color-content);
}
#file-index a, #document-outline a {
color: var(--ifm-color-content);
text-decoration: none;
display: block;
padding: 0.4rem 0.8rem;
font-size: 0.875rem;
}
#file-index a:hover, #document-outline a:hover {
background-color: rgba(0, 0, 0, 0.05);
color: var(--ifm-color-primary);
}
#document-outline a {
color: var(--ifm-color-content-secondary);
border-left: 2px solid transparent;
margin: 2px 0;
}
#document-outline a:hover {
background-color: transparent;
color: var(--ifm-color-primary);
border-left: 2px solid var(--ifm-color-primary);
}
/* Markdown content styling */
.markdown-content {
line-height: 1.7;
font-size: 1rem;
max-width: 130ch;
margin: 0 auto;
}
.markdown-content h1 {
font-size: 2.5rem;
font-weight: 700;
margin-bottom: 1.5rem;
text-align: left; /* Explicitly set left alignment */
}
.markdown-content h2 {
font-size: 1.8rem;
margin-top: 2.5rem;
margin-bottom: 1rem;
font-weight: 600;
text-align: left;
}
.markdown-content h3 {
font-size: 1.5rem;
margin-top: 2rem;
font-weight: 600;
text-align: left;
}
.markdown-content a {
color: var(--ifm-link-color);
text-decoration: none;
}
.markdown-content a:hover {
text-decoration: underline;
}
.markdown-content p {
margin: 1rem 0;
}
.markdown-content img {
max-width: 100%;
height: auto;
border-radius: 8px;
}
.markdown-content table {
border-collapse: separate;
border-spacing: 0;
width: 100%;
margin: 1em 0;
font-size: 0.9rem;
}
.markdown-content th {
background-color: rgba(255, 255, 255, 0.15); /* Change header background to 15% white */
font-weight: 600;
border: none;
border-bottom: 1px solid var(--ifm-border-color);
text-align: left; /* Add this line to left-align table headers */
padding: 0.75rem;
}
.markdown-content th:first-child {
border-top-left-radius: 10px;
}
.markdown-content th:last-child {
border-top-right-radius: 10px;
}
.markdown-content td {
border: none;
border-bottom: 1px solid var(--ifm-border-color);
padding: 0.75rem;
background-color: rgba(255, 255, 255, 0.03); /* Lighter background for cells */
}
.markdown-content tr:last-child td {
border-bottom: none;
}
.markdown-content tr:last-child td:first-child {
border-bottom-left-radius: 10px;
}
.markdown-content tr:last-child td:last-child {
border-bottom-right-radius: 10px;
}
.markdown-content code:not([class*="language-"]) {
background-color: rgba(255, 255, 255, 0.1);
padding: 0.2em 0.4em;
border-radius: 1px;
font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
font-size: 0.9em;
color: #e0e0e0;
border: 1px solid rgba(255, 255, 255, 0.1);
}
.markdown-content blockquote {
border-left: 4px solid var(--ifm-color-primary);
margin: 1rem 0;
padding: 0.5rem 1rem;
background-color: var(--ifm-background-surface-color);
border-radius: 4px;
color: var(--ifm-color-content-secondary);
}
.markdown-content video {
max-width: 100%;
height: auto;
margin: 1rem 0;
border-radius: 8px;
box-shadow: 0 2px 12px rgba(0, 0, 0, 0.4);
}
.markdown-content hr {
margin: 3rem 0;
border: none;
border-bottom: 1px solid var(--ifm-border-color);
}
.error {
color: #ff6b6b;
padding: 20px;
border: 1px solid #ff6b6b;
border-radius: 4px;
margin: 20px 0;
}
/* Custom Scrollbar */
::-webkit-scrollbar {
width: 7px;
height: 7px;
}
::-webkit-scrollbar-track {
background: var(--ifm-background-color);
}
::-webkit-scrollbar-thumb {
background-color: #505050;
border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
background-color: #606060;
}
/* Completely remove scrollbar buttons */
::-webkit-scrollbar-button {
display: none !important;
width: 0 !important;
height: 0 !important;
background: transparent !important;
}
::-webkit-scrollbar-corner {
background-color: transparent;
}
/* Firefox scrollbar - hide buttons */
* {
scrollbar-width: thin;
scrollbar-color: #505050 var(--ifm-background-color);
}
/* Highlight animation */
@keyframes highlight {
0% { background-color: rgba(33, 150, 243, 0.2); }
100% { background-color: transparent; }
}
.markdown-content h1.highlight,
.markdown-content h2.highlight,
.markdown-content h3.highlight,
.markdown-content h4.highlight,
.markdown-content h5.highlight,
.markdown-content h6.highlight {
animation: highlight 2s ease-out;
}
@media (max-width: 1000px) {
.menu-button {
display: block;
}
.left-sidebar {
position: fixed;
left: -100%;
top: var(--title-bar-height);
bottom: 0;
z-index: 100;
transition: var(--sidebar-transition);
}
.right-sidebar {
display: none;
}
.left-sidebar.show {
left: 0;
box-shadow: 2px 0 8px rgba(0, 0, 0, 0.2);
}
.content {
padding: 1.5rem;
}
.social-links {
background: var(--ifm-background-surface-color);
border-color: var(--ifm-border-color);
}
}
.title-text {
display: flex;
align-items: center;
gap: 0.5rem;
}
.title-text .brand {
color: var(--ifm-color-primary);
font-weight: 800;
letter-spacing: -0.01em;
font-size: 1.2rem;
}
.title-text .divider,
.title-text .page-title {
font-size: 0.9rem;
}