/* Toki Pona font */
@font-face {
    font-family: ssk;
    src: url("../fonts/sitelenselikiwenmonoasuki1.woff2") format("woff2"),
        url("../fonts/sitelenselikiwenmonoasuki1.woff") format("woff");
    font-weight: 400;
    font-style: normal;
    font-display: swap;
}

.font-pona {
    font-family: 'ssk', sans-serif;
    font-feature-settings: "liga" 1;
    text-rendering: optimizeLegibility;
}

/* Theme colors */
.coal {
    --bg: #000 !important;
    --fg: #fff !important;
    --sidebar-bg: #000 !important;
    --sidebar-fg: #888 !important;
    --sidebar-non-existant: #444 !important;
    --sidebar-active: #fff !important;
    --sidebar-spacer: #222 !important;
    --scrollbar: #333 !important;
    --icons: #555 !important;
    --icons-hover: #fff !important;
    --links: #fff !important;
    --inline-code-color: #888 !important;
    --theme-popup-bg: #111 !important;
    --theme-popup-border: #333 !important;
    --theme-hover: #111 !important;
    --quote-bg: #111 !important;
    --quote-border: #333 !important;
    --table-border-color: #333 !important;
    --table-header-bg: #111 !important;
    --table-alternate-bg: #0a0a0a !important;
    --searchbar-border-color: #333 !important;
    --searchbar-bg: #111 !important;
    --searchbar-fg: #fff !important;
    --searchbar-shadow-color: transparent !important;
    --searchresults-header-fg: #666 !important;
    --searchresults-border-color: #333 !important;
    --searchresults-li-bg: #111 !important;
    --search-mark-bg: #333 !important;
    --color-scheme: dark !important;
    --copy-button-filter: invert(0.6) !important;
    --copy-button-filter-hover: invert(1) !important;
}

.hljs {
    background: #111 !important;
}

/* Hide theme picker - single theme */
#theme-list {
    display: none;
}

#theme-toggle {
    display: none;
}

/* General overrides */
html {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    color-scheme: dark;
}

body {
    background: #000;
    color: #fff;
}

/* Sidebar */
.sidebar {
    background: #000;
    border-right: 1px solid #222;
}

.sidebar .sidebar-scrollbox {
    padding: 1.5rem;
}

.chapter li a {
    color: #888;
    padding: 0.5rem 0;
    border-bottom: none;
    transition: color 0.15s ease;
}

.chapter li a:hover {
    color: #fff;
}

.chapter li.part-title {
    border-bottom: 1px solid #888;
}

.chapter li.active>a {
    color: #fff;
}

/* Content */
.content {
    background: #000;
}

.content main {
    max-width: 700px;
    padding: 2rem;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    color: #fff;
    font-weight: 500;
    letter-spacing: -0.01em;
}

h1 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
    border-bottom: none;
}

h2 {
    font-size: 1.4rem;
    margin-top: 2.5rem;
    margin-bottom: 1rem;
    border-bottom: none;
}

h3 {
    font-size: 1.1rem;
}

p {
    line-height: 1.7;
    color: #ccc;
}

a {
    color: #fff;
    text-decoration: none;
    border-bottom: 1px solid #333;
    transition: border-color 0.15s ease;
}

a:hover {
    border-color: #fff;
}

/* Code */
pre {
    background: #111 !important;
    border: 1px solid #222;
    border-radius: 4px;
    padding: 1rem;
}

code {
    font-family: 'JetBrains Mono', 'Fira Code', monospace;
    font-size: 0.9em;
}

:not(pre)>code {
    background: #111;
    padding: 0.2em 0.4em;
    border-radius: 3px;
    color: #888;
}

/* Code highlighting - minimal */
.tokimun .hljs {
    background: #111;
    color: #ccc;
}

.tokimun .hljs-keyword,
.tokimun .hljs-built_in {
    color: #fff;
}

.tokimun .hljs-string {
    color: #888;
}

.tokimun .hljs-comment {
    color: #555;
}

.tokimun .hljs-number {
    color: #aaa;
}

.tokimun .hljs-function {
    color: #fff;
}

/* Menu bar */
.menu-bar {
    background: #000;
    border-bottom: 1px solid #222;
}

.menu-bar i {
    color: #555;
}

.menu-bar i:hover {
    color: #fff;
}

.menu-bar .left-buttons button,
.menu-bar .right-buttons button,
.menu-bar .right-buttons a {
    color: #555;
}

.menu-bar .left-buttons button:hover,
.menu-bar .right-buttons button:hover,
.menu-bar .right-buttons a:hover {
    color: #fff;
}

/* Search */
#searchbar {
    background: #111;
    border: 1px solid #333;
    color: #fff;
    border-radius: 4px;
}

#searchbar:focus {
    border-color: #555;
    outline: none;
}

.search-results {
    background: #111;
    border: 1px solid #333;
}

.search-results a {
    border-bottom: none;
}

.search-results a:hover {
    background: #222;
}

/* Navigation arrows */
.nav-chapters {
    color: #333;
}

.nav-chapters:hover {
    color: #fff;
}

/* Blockquotes */
blockquote {
    background: #111;
    border-left: 3px solid #333;
    margin: 1.5rem 0;
    padding: 1rem 1.5rem;
}

blockquote p {
    color: #888;
}

/* Tables */
table {
    border-collapse: collapse;
    width: 100%;
}

th,
td {
    border: 1px solid #333;
    padding: 0.75rem;
}

th {
    background: #111;
}

tr:nth-child(even) {
    background: #0a0a0a;
}

/* Lists */
ul,
ol {
    color: #ccc;
}

li {
    margin-bottom: 0.5rem;
}

/* Horizontal rule */
hr {
    border: none;
    border-top: 1px solid #222;
    margin: 2rem 0;
}

/* Print button and other icons - hide stuff we don't need */
#print-button {
    display: none;
}

/* Footer spacing */
.content main {
    padding-bottom: 4rem;
}

.right-buttons a {
    border-bottom: none;
}

#mdbook-theme-toggle {
    display: none;
}

#theme-list,
#theme-toggle,
.theme-popup {
    display: none !important;
}

/* Mobile */
@media (max-width: 768px) {
    .content main {
        padding: 1rem;
    }

    h1 {
        font-size: 1.6rem;
    }
}