* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: #1e1e1e;
    color: #a9b7c6;
    line-height: 1.6;
}

/* Sidebar */
.sidebar {
    position: fixed;
    left: 0;
    top: 0;
    width: 280px;
    height: 100vh;
    background-color: #2b2b2b;
    border-right: 1px solid #3c3f41;
    overflow-y: auto;
    overflow-x: hidden;
    padding: 0;
    z-index: 1000;
    display: flex;
    flex-direction: column;
}

/* Custom scrollbar for sidebar */
.sidebar::-webkit-scrollbar {
    width: 8px;
}

.sidebar::-webkit-scrollbar-track {
    background: #2b2b2b;
}

.sidebar::-webkit-scrollbar-thumb {
    background: #5a5a5a;
    border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: #6e6e6e;
}

.sidebar-header {
    padding: 20px;
    background-color: #3c3f41;
    border-bottom: 1px solid #515151;
    position: sticky;
    top: 0;
    z-index: 10;
}

.sidebar-header h1 {
    font-size: 1.1em;
    color: #a9b7c6;
    margin-bottom: 0;
    font-weight: 600;
}

.sidebar nav {
    flex: 1;
    overflow-y: auto;
    padding: 12px 0;
}

.nav-section {
    margin-bottom: 8px;
    padding: 0 8px;
}

.nav-section-title {
    font-size: 0.7em;
    text-transform: uppercase;
    color: #787878;
    margin-bottom: 6px;
    padding: 8px 12px 4px;
    font-weight: 700;
    letter-spacing: 0.8px;
}

.nav-list {
    list-style: none;
}

.nav-list li {
    margin-bottom: 1px;
}

.nav-list a {
    display: block;
    color: #a9b7c6;
    text-decoration: none;
    padding: 6px 12px;
    border-radius: 3px;
    font-size: 0.85em;
    transition: background-color 0.15s, color 0.15s;
    border-left: 3px solid transparent;
}

.nav-list a:hover {
    background-color: #3c3f41;
    color: #ffc66d;
    text-decoration: none;
}

.nav-list a.active {
    background-color: #214283;
    color: #a9b7c6;
    border-left-color: #4e94cf;
}

/* Mobile sidebar toggle */
.sidebar-toggle {
    display: none;
    position: fixed;
    top: 16px;
    left: 16px;
    z-index: 1001;
    background-color: #3c3f41;
    border: 1px solid #515151;
    border-radius: 4px;
    padding: 8px 12px;
    color: #a9b7c6;
    cursor: pointer;
    font-size: 1.2em;
}

/* Mobile responsive sidebar */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .sidebar.open {
        transform: translateX(0);
    }

    .sidebar-toggle {
        display: block;
    }

    .main-content {
        margin-left: 0;
        padding: 60px 20px 40px;
    }
}

/* Main Content */
.main-content {
    margin-left: 280px;
    padding: 40px 60px;
    max-width: 1200px;
    background-color: #1e1e1e;
    min-height: 100vh;
}

h1 {
    color: #a9b7c6;
    font-size: 2em;
    margin-bottom: 12px;
    font-weight: 600;
}

h2 {
    color: #a9b7c6;
    font-size: 1.5em;
    margin-top: 40px;
    margin-bottom: 16px;
    padding-bottom: 8px;
    border-bottom: 1px solid #3c3f41;
    font-weight: 600;
}

h3 {
    color: #ffc66d;
    font-size: 1.25em;
    margin-top: 24px;
    margin-bottom: 12px;
    font-weight: 600;
}

h4 {
    color: #a9b7c6;
    font-size: 1.1em;
    margin-top: 20px;
    margin-bottom: 10px;
    font-weight: 600;
}

p {
    margin-bottom: 16px;
    color: #a9b7c6;
}

/* Inline code */
code {
    background-color: #313335;
    color: #a9b7c6;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'JetBrains Mono', 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 0.85em;
    border: 1px solid #3c3f41;
}

pre {
    background-color: #2b2b2b;
    border: 1px solid #3c3f41;
    border-radius: 6px;
    padding: 16px;
    overflow-x: auto;
    margin: 16px 0;
    line-height: 1.5;
}

pre code {
    background-color: transparent;
    padding: 0;
    color: #a9b7c6;
    font-size: 0.9em;
    display: block;
    border: none;
}

/* IntelliJ Darcula Theme - Syntax Highlighting */
.codehilite {
    background-color: #2b2b2b;
    border: 1px solid #3c3f41;
    border-radius: 6px;
    margin: 16px 0;
}

.codehilite pre {
    background-color: #2b2b2b;
    border: none;
    margin: 0;
    padding: 16px;
}

.codehilite code {
    background-color: transparent;
    color: #a9b7c6;
}

/* Pygments Token Classes - IntelliJ Darcula Colors */

/* Comments */
.codehilite .c,      /* Comment */
.codehilite .c1,     /* Comment.Single */
.codehilite .cm,     /* Comment.Multiline */
.codehilite .cp,     /* Comment.Preproc */
.codehilite .cs,     /* Comment.Special */
.codehilite .ch {    /* Comment.Hashbang */
    color: #808080;
    font-style: italic;
}

/* Keywords */
.codehilite .k,      /* Keyword */
.codehilite .kc,     /* Keyword.Constant */
.codehilite .kd,     /* Keyword.Declaration */
.codehilite .kn,     /* Keyword.Namespace */
.codehilite .kp,     /* Keyword.Pseudo */
.codehilite .kr,     /* Keyword.Reserved */
.codehilite .kt {    /* Keyword.Type */
    color: #cc7832;
    font-weight: bold;
}

/* Strings */
.codehilite .s,      /* String */
.codehilite .s1,     /* String.Single */
.codehilite .s2,     /* String.Double */
.codehilite .sa,     /* String.Affix */
.codehilite .sb,     /* String.Backtick */
.codehilite .sc,     /* String.Char */
.codehilite .sd,     /* String.Doc */
.codehilite .se,     /* String.Escape */
.codehilite .sh,     /* String.Heredoc */
.codehilite .si,     /* String.Interpol */
.codehilite .sr,     /* String.Regex */
.codehilite .ss,     /* String.Symbol */
.codehilite .sx {    /* String.Other */
    color: #6a8759;
}

/* Numbers */
.codehilite .m,      /* Number */
.codehilite .mf,     /* Number.Float */
.codehilite .mh,     /* Number.Hex */
.codehilite .mi,     /* Number.Integer */
.codehilite .mo,     /* Number.Oct */
.codehilite .mb,     /* Number.Bin */
.codehilite .il {    /* Number.Integer.Long */
    color: #6897bb;
}

/* Names */
.codehilite .n {     /* Name */
    color: #a9b7c6;
}

.codehilite .na {    /* Name.Attribute */
    color: #bababa;
}

.codehilite .nb {    /* Name.Builtin */
    color: #8888c6;
}

.codehilite .nc {    /* Name.Class */
    color: #a9b7c6;
    font-weight: bold;
}

.codehilite .nd {    /* Name.Decorator / Annotation */
    color: #bbb529;
}

.codehilite .ne {    /* Name.Exception */
    color: #a9b7c6;
    font-weight: bold;
}

.codehilite .nf {    /* Name.Function */
    color: #ffc66d;
}

.codehilite .ni {    /* Name.Entity */
    color: #a9b7c6;
}

.codehilite .nl {    /* Name.Label */
    color: #a9b7c6;
}

.codehilite .nn {    /* Name.Namespace */
    color: #a9b7c6;
}

.codehilite .nt {    /* Name.Tag */
    color: #e8bf6a;
}

.codehilite .nv {    /* Name.Variable */
    color: #9876aa;
}

.codehilite .bp {    /* Name.Builtin.Pseudo */
    color: #8888c6;
}

.codehilite .fm {    /* Name.Function.Magic */
    color: #ffc66d;
}

.codehilite .vc,     /* Name.Variable.Class */
.codehilite .vg,     /* Name.Variable.Global */
.codehilite .vi,     /* Name.Variable.Instance */
.codehilite .vm {    /* Name.Variable.Magic */
    color: #9876aa;
}

/* Operators */
.codehilite .o,      /* Operator */
.codehilite .ow {    /* Operator.Word */
    color: #a9b7c6;
}

/* Punctuation */
.codehilite .p {     /* Punctuation */
    color: #a9b7c6;
}

/* Generic */
.codehilite .g {     /* Generic */
    color: #a9b7c6;
}

.codehilite .gd {    /* Generic.Deleted */
    color: #a9b7c6;
    background-color: #3c1f1f;
}

.codehilite .ge {    /* Generic.Emph */
    font-style: italic;
}

.codehilite .gh {    /* Generic.Heading */
    color: #a9b7c6;
    font-weight: bold;
}

.codehilite .gi {    /* Generic.Inserted */
    color: #a9b7c6;
    background-color: #1f3c1f;
}

.codehilite .go {    /* Generic.Output */
    color: #808080;
}

.codehilite .gp {    /* Generic.Prompt */
    color: #a9b7c6;
    font-weight: bold;
}

.codehilite .gs {    /* Generic.Strong */
    font-weight: bold;
}

.codehilite .gu {    /* Generic.Subheading */
    color: #a9b7c6;
    font-weight: bold;
}

.codehilite .gt {    /* Generic.Traceback */
    color: #ff6b68;
}

/* Errors */
.codehilite .err {   /* Error */
    color: #a9b7c6;
    background-color: transparent;
}

/* Whitespace */
.codehilite .w {     /* Whitespace */
    color: transparent;
}

/* Other */
.codehilite .l {     /* Literal */
    color: #6897bb;
}

.codehilite .ld {    /* Literal.Date */
    color: #6a8759;
}

.codehilite .x {     /* Other */
    color: #a9b7c6;
}

/* Line numbers if present */
.codehilite .linenos {
    color: #606366;
    padding-right: 12px;
    border-right: 1px solid #3c3f41;
    margin-right: 12px;
    user-select: none;
}

ul, ol {
    margin-left: 24px;
    margin-bottom: 16px;
}

li {
    margin-bottom: 8px;
}

table {
    width: 100%;
    border-collapse: collapse;
    margin: 20px 0;
    background-color: #2b2b2b;
    border: 1px solid #3c3f41;
    border-radius: 6px;
    overflow: hidden;
}

th {
    background-color: #3c3f41;
    color: #a9b7c6;
    padding: 12px;
    text-align: left;
    font-weight: 600;
    border-bottom: 1px solid #515151;
}

td {
    padding: 12px;
    border-bottom: 1px solid #3c3f41;
    color: #a9b7c6;
}

tr:last-child td {
    border-bottom: none;
}

tr:hover td {
    background-color: #323335;
}

a {
    color: #6897bb;
    text-decoration: none;
}

a:hover {
    color: #8fbcd5;
    text-decoration: underline;
}

strong {
    color: #a9b7c6;
    font-weight: 600;
}


hr {
    border: none;
    border-top: 1px solid #3c3f41;
    margin: 30px 0;
}


