/* Highlight.js Theme - GitHub Light/Dark */

/* Light theme (default) */
.hljs {
    display: block;
    overflow-x: auto;
    padding: 0;
    color: #24292e;
    background: transparent;
}

.hljs-comment,
.hljs-quote {
    color: #6a737d;
    font-style: italic;
}

.hljs-keyword,
.hljs-selector-tag,
.hljs-subst {
    color: #d73a49;
    font-weight: bold;
}

.hljs-number,
.hljs-literal,
.hljs-variable,
.hljs-template-variable,
.hljs-tag .hljs-attr {
    color: #005cc5;
}

.hljs-string,
.hljs-doctag {
    color: #032f62;
}

.hljs-title,
.hljs-section,
.hljs-selector-id {
    color: #6f42c1;
    font-weight: bold;
}

.hljs-type,
.hljs-class .hljs-title {
    color: #d73a49;
    font-weight: bold;
}

.hljs-tag,
.hljs-name,
.hljs-attribute {
    color: #22863a;
    font-weight: normal;
}

.hljs-regexp,
.hljs-link {
    color: #032f62;
}

.hljs-symbol,
.hljs-bullet {
    color: #e36209;
}

.hljs-built_in,
.hljs-builtin-name {
    color: #005cc5;
}

.hljs-meta {
    color: #6a737d;
}

.hljs-deletion {
    background: #ffeef0;
}

.hljs-addition {
    background: #f0fff4;
}

.hljs-emphasis {
    font-style: italic;
}

.hljs-strong {
    font-weight: bold;
}

/* Dark theme */
[data-theme="dark"] .hljs {
    color: #e1e4e8;
}

[data-theme="dark"] .hljs-comment,
[data-theme="dark"] .hljs-quote {
    color: #8b949e;
}

[data-theme="dark"] .hljs-keyword,
[data-theme="dark"] .hljs-selector-tag,
[data-theme="dark"] .hljs-subst {
    color: #ff7b72;
}

[data-theme="dark"] .hljs-number,
[data-theme="dark"] .hljs-literal,
[data-theme="dark"] .hljs-variable,
[data-theme="dark"] .hljs-template-variable,
[data-theme="dark"] .hljs-tag .hljs-attr {
    color: #79c0ff;
}

[data-theme="dark"] .hljs-string,
[data-theme="dark"] .hljs-doctag {
    color: #a5d6ff;
}

[data-theme="dark"] .hljs-title,
[data-theme="dark"] .hljs-section,
[data-theme="dark"] .hljs-selector-id {
    color: #d2a8ff;
}

[data-theme="dark"] .hljs-type,
[data-theme="dark"] .hljs-class .hljs-title {
    color: #ff7b72;
}

[data-theme="dark"] .hljs-tag,
[data-theme="dark"] .hljs-name,
[data-theme="dark"] .hljs-attribute {
    color: #7ee787;
}

[data-theme="dark"] .hljs-regexp,
[data-theme="dark"] .hljs-link {
    color: #a5d6ff;
}

[data-theme="dark"] .hljs-symbol,
[data-theme="dark"] .hljs-bullet {
    color: #ffa657;
}

[data-theme="dark"] .hljs-built_in,
[data-theme="dark"] .hljs-builtin-name {
    color: #79c0ff;
}

[data-theme="dark"] .hljs-meta {
    color: #8b949e;
}

[data-theme="dark"] .hljs-deletion {
    background: #490202;
}

[data-theme="dark"] .hljs-addition {
    background: #04260f;
}

/* Language specific styles */
.hljs-tag .hljs-name {
    color: #22863a;
}

[data-theme="dark"] .hljs-tag .hljs-name {
    color: #7ee787;
}

.hljs-tag .hljs-string {
    color: #032f62;
}

[data-theme="dark"] .hljs-tag .hljs-string {
    color: #a5d6ff;
}

/* Copy button for code blocks */
pre {
    position: relative;
}

pre:hover .copy-button {
    opacity: 1;
}

.copy-button {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 0.25rem;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.2s ease;
    color: var(--text-secondary);
}

.copy-button:hover {
    background: var(--border-light);
    color: var(--text-primary);
}

.copy-button.copied {
    background: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}