/*
 * kernelite Doxygen theme
 *
 * Palette (matches kernelite_logo.svg):
 *   #042C53  deep navy    — primary background, headings
 *   #185FA5  mid blue     — navigation, links, secondary elements
 *   #378ADD  accent blue  — highlights, hover states, borders
 *   #B5D4F4  light blue   — subtle backgrounds, code blocks
 *   #E6F1FB  near-white   — body text on dark backgrounds
 */

/* ── Fonts ──────────────────────────────────────────────────────────────── */

body, div, p, td, th, li, dt, dd {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
                 "Helvetica Neue", Arial, sans-serif;
    font-size: 14px;
    color: #1a1a2e;
}

code, pre, tt, kbd, .fragment {
    font-family: "JetBrains Mono", "Fira Code", "Cascadia Code",
                 "Source Code Pro", monospace;
    font-size: 13px;
}

/* ── Top header bar ─────────────────────────────────────────────────────── */

#top {
    background: linear-gradient(135deg, #042C53 0%, #185FA5 100%);
    border-bottom: 3px solid #378ADD;
    padding: 0;
}

#titlearea {
    background: transparent;
    border-bottom: none;
    padding: 12px 16px;
}

#projectname {
    font-family: monospace;
    font-size: 28px;
    font-weight: 400;
    color: #E6F1FB;
    letter-spacing: 1px;
}

#projectname span.bold {
    color: #B5D4F4;
}

#projectbrief {
    font-family: monospace;
    font-size: 12px;
    color: #69a7e5;
    letter-spacing: 3px;
    text-transform: lowercase;
}

#projectlogo img {
    max-height: 50px;
    padding-right: 12px;
}

/* ── Navigation tabs ────────────────────────────────────────────────────── */

.tabs, .tabs2, .tabs3 {
    background: #042C53;
    border-bottom: 2px solid #378ADD;
}

.tablist {
    background: transparent;
}

.tablist a {
    color: #B5D4F4 !important;
    font-size: 13px;
    font-weight: 400;
    text-decoration: none;
    border: none;
    padding: 8px 16px;
    background: transparent;
}

.tablist a:hover,
.tablist li.current a {
    color: #ffffff !important;
    background: #185FA5;
    border-bottom: 2px solid #378ADD;
}

/* ── Left-hand navigation panel ─────────────────────────────────────────── */

#nav-tree {
    background: #f4f8fd;
    border-right: 1px solid #B5D4F4;
}

#nav-tree .selected {
    background: linear-gradient(90deg, #B5D4F4 0%, #e0edf8 100%);
}

#nav-tree a {
    color: #042C53;
}

#nav-tree a:hover {
    color: #185FA5;
}

/* ── Main content area ──────────────────────────────────────────────────── */

body {
    background-color: #EDF4FC;
}

#doc-content, div.contents {
    background: #EDF4FC;
}

/* Keep member declaration blocks on a slightly lighter surface
   so they lift off the tinted page background */
.mdescLeft, .mdescRight,
.memItemLeft, .memItemRight {
    background: #F0F7FD;
}

/* ── Headings ───────────────────────────────────────────────────────────── */

h1, h2, h3 {
    background: linear-gradient(90deg, #042C53 0%, #185FA5 100%);
    color: #E6F1FB;
    font-weight: 600;
    border-bottom: 1px solid #B5D4F4;
    padding-bottom: 4px;
    padding-top: 4px;
}

h1.groupheader, h2.groupheader, h3.groupheader {
    color: #E6F1FB;
    border-bottom: 2px solid #378ADD;
}

/* ── Links ──────────────────────────────────────────────────────────────── */

a:link, a:visited {
    color: #0c95a8;
    text-decoration: none;
}

a:hover {
    color: #378ADD;
    text-decoration: underline;
}

/* ── Member declaration / definition blocks ─────────────────────────────── */

.memtitle {
    background: linear-gradient(90deg, #042C53 0%, #185FA5 100%);
    color: #E6F1FB;
    border: none;
    border-radius: 4px 4px 0 0;
    font-family: monospace;
    font-size: 13px;
    padding: 6px 12px;
}

.memdoc {
    background: #f9fbfe;
    border: 1px solid #B5D4F4;
    border-top: none;
    border-radius: 0 0 4px 4px;
}

.memproto {
    background: linear-gradient(90deg, #042C53 0%, #0d3d6e 100%);
    color: #E6F1FB;
    border: 1px solid #042C53;
    border-radius: 4px 4px 0 0;
    font-family: monospace;
    font-size: 13px;
    padding: 8px 12px;
}

.memproto td.memname {
    color: #B5D4F4;
    font-weight: 600;
}

table.memname td {
    color: #E6F1FB;
}

/* ── Code / fragment blocks ─────────────────────────────────────────────── */

div.fragment {
    background: #042C53;
    color: #E6F1FB;
    border: 1px solid #185FA5;
    border-left: 4px solid #378ADD;
    border-radius: 4px;
    padding: 12px 16px;
    font-size: 12.5px;
    line-height: 1.6;
}

div.line {
    color: #E6F1FB;
}

/* Syntax highlight overrides — keep readable on dark background */
span.keyword    { color: #B5D4F4; font-weight: bold; }
span.keywordtype{ color: #79c0ff; }
span.keywordflow{ color: #f97583; }
span.preprocessor { color: #a5d6ff; }
span.stringliteral { color: #9ecbff; }
span.comment    { color: #8b949e; font-style: italic; }
span.charliteral{ color: #9ecbff; }

/* ── Summary / detail tables ────────────────────────────────────────────── */

table.memberdecls {
    border-collapse: collapse;
    width: 100%;
}

.mdescLeft, .mdescRight,
.memItemLeft, .memItemRight {
    border-bottom: 1px solid #e0edf8;
    padding: 6px 10px;
    font-size: 13px;
}

.memItemLeft {
    font-family: monospace;
    color: #042C53;
}

tr.memitem:hover td {
    background: #e0edf8;
}

/* Section headers inside member lists */
tr.heading > td {
    background: #185FA5;
    color: #E6F1FB;
    font-size: 13px;
    font-weight: 600;
    padding: 6px 10px;
}

/* ── Parameters / return / note boxes ──────────────────────────────────── */

dl.params .paramname,
dl.retval .paramname {
    color: #185FA5;
    font-weight: bold;
    font-family: monospace;
}

dl.note, dl.warning, dl.attention {
    border-left: 4px solid #378ADD;
    background: #e8f2fb;
    padding: 8px 12px;
    border-radius: 0 4px 4px 0;
}

dl.warning {
    border-left-color: #e36209;
    background: #fff8e1;
}

/* ── Search box ─────────────────────────────────────────────────────────── */

#MSearchBox {
    background: #185FA5;
    border: 1px solid #378ADD;
    border-radius: 4px;
}

#MSearchField {
    background: transparent;
    color: #E6F1FB;
    font-size: 13px;
}

#MSearchField::placeholder {
    color: #B5D4F4;
}

/* ── Footer ─────────────────────────────────────────────────────────────── */

address.footer {
    background: #042C53;
    color: #B5D4F4;
    font-size: 11px;
    font-family: monospace;
    padding: 12px 16px;
    border-top: 2px solid #378ADD;
    text-align: center;
}

address.footer a {
    color: #378ADD;
}

/* ── Scrollbar (Webkit) ─────────────────────────────────────────────────── */

::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f4f8fd;
}

::-webkit-scrollbar-thumb {
    background: #185FA5;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #378ADD;
}
