# hjkl syntax theme — dark.
# Override for hjkl-bonsai's bundled DotFallbackTheme. Uses hjkl-theme schema:
# @-prefixed TS capture names, modifiers as arrays, optional $palette refs.
# Loaded via include_str! in apps/hjkl/src/theme.rs and passed to
# DotFallbackTheme::from_toml().
#
# Palette anchors (hjkl.kryptic.sh CSS custom properties):
#   --bg #0b0d10  --fg #e5e9f0
#   --accent #bb9af7  --blue #7aa2f7  --green #7ee787  --orange #ff9e64
#   --keyword #c792ea  --string #a3e88a
#   --number #f78c6c  --comment #8597a3

"@default"                        = { fg = "$fg" }

"@keyword"                        = { fg = "$keyword", modifiers = ["bold"] }
"@keyword.control"                = { fg = "$accent", modifiers = ["bold"] }
"@keyword.return"                 = { fg = "$accent", modifiers = ["bold"] }
"@keyword.operator"               = { fg = "$keyword" }
"@keyword.sql"                    = { fg = "$keyword", modifiers = ["bold"] }

"@string"                         = { fg = "$string" }
"@string.escape"                  = { fg = "$orange" }
"@string.special"                 = { fg = "$blue" }

"@comment"                        = { fg = "$comment", modifiers = ["italic"] }

"@number"                         = { fg = "$number" }

"@function"                       = { fg = "$blue" }
"@function.builtin"               = { fg = "$accent" }
"@function.method"                = { fg = "$blue" }
"@function.macro"                 = { fg = "$accent", modifiers = ["bold"] }

"@type"                           = { fg = "$orange" }
"@type.builtin"                   = { fg = "$orange", modifiers = ["bold"] }

"@variable"                       = { fg = "$fg" }
"@variable.builtin"               = { fg = "$accent" }
"@variable.parameter"             = { fg = "$fg", modifiers = ["italic"] }

"@constant"                       = { fg = "$accent" }
"@constant.builtin"               = { fg = "$accent", modifiers = ["bold"] }

"@punctuation"                    = { fg = "$punctuation" }
"@punctuation.bracket"            = { fg = "$punctuation" }
"@punctuation.delimiter"          = { fg = "$punctuation" }

"@operator"                       = { fg = "$blue" }

"@tag"                            = { fg = "$blue" }
"@heading"                        = { fg = "$accent", modifiers = ["bold"] }
"@link"                           = { fg = "$blue", modifiers = ["underline"] }
"@code"                           = { fg = "$string" }

"@property"                       = { fg = "$blue" }
"@table"                          = { fg = "$orange" }

"@identifier"                     = { fg = "$fg" }

# Markdown (tree-sitter-markdown / markdown_inline capture names).
# `@markup.foo.bar` falls back to `@markup.foo` if not present, so the
# specific levels (.1–.6) inherit `@markup.heading` automatically.
"@markup.heading"                 = { fg = "$accent", modifiers = ["bold"] }
"@markup.heading.1"               = { fg = "$accent", modifiers = ["bold", "underline"] }
"@markup.heading.2"               = { fg = "$blue", modifiers = ["bold"] }
"@markup.italic"                  = { fg = "$fg", modifiers = ["italic"] }
"@markup.strong"                  = { fg = "$fg", modifiers = ["bold"] }
"@markup.strikethrough"           = { fg = "$comment", modifiers = ["strikethrough"] }
"@markup.raw"                     = { fg = "$string" }
"@markup.raw.block"               = { bg = "$codeblock_bg" }
"@markup.link"                    = { fg = "$blue", modifiers = ["underline"] }
"@markup.link.label"              = { fg = "$blue" }
"@markup.link.url"                = { fg = "$comment", modifiers = ["underline"] }
"@markup.list"                    = { fg = "$keyword" }
"@markup.list.checked"            = { fg = "$string", modifiers = ["bold"] }
"@markup.list.unchecked"          = { fg = "$comment" }
"@markup.quote"                   = { fg = "$comment", modifiers = ["italic"] }
"@label"                          = { fg = "$blue", modifiers = ["italic"] }

# Comment markers (TODO / FIXME / NOTE / WARN badges)
# Label: coloured bg, dark fg, bold
# Tail:  same colour as label bg, italic, no bg
"@comment.marker.todo"            = { fg = "$bg", bg = "$orange", modifiers = ["bold"] }
"@comment.marker.tail.todo"       = { fg = "$orange", modifiers = ["italic"] }

"@comment.marker.fixme"           = { fg = "$bg", bg = "$number", modifiers = ["bold"] }
"@comment.marker.tail.fixme"      = { fg = "$number", modifiers = ["italic"] }

"@comment.marker.note"            = { fg = "$bg", bg = "$blue", modifiers = ["bold"] }
"@comment.marker.tail.note"       = { fg = "$blue", modifiers = ["italic"] }

"@comment.marker.warn"            = { fg = "$bg", bg = "$accent", modifiers = ["bold"] }
"@comment.marker.tail.warn"       = { fg = "$accent", modifiers = ["italic"] }

[palette]
bg           = "#0b0d10"
fg           = "#e5e9f0"
accent       = "#bb9af7"
blue         = "#7aa2f7"
orange       = "#ff9e64"
keyword      = "#c792ea"
string       = "#a3e88a"
number       = "#f78c6c"
comment      = "#8597a3"
punctuation  = "#8b95a7"
# Slightly elevated panel tint for fenced/indented code blocks. Sits two
# steps off `bg` so it reads as "different layer" without fighting the
# surrounding prose for attention.
codeblock_bg = "#1a1f29"
