/* Enhanced Code Blocks */
.code-container {
    position: relative;
    background: #1a1a1a;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #374151;
    margin: 1rem 0;
}

.code-header {
    background: #111827;
    padding: 0.75rem 1rem;
    border-bottom: 1px solid #374151;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.code-language {
    color: #9CA3AF;
    font-size: 0.875rem;
    font-weight: 500;
}

.copy-btn {
    background: #374151;
    color: #9CA3AF;
    border: none;
    padding: 0.375rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}

.copy-btn:hover {
    background: #4B5563;
    color: #F3F4F6;
}

.copy-btn.copied {
    background: #059669;
    color: white;
}

.code-content {
    display: flex;
    max-height: 400px;
    overflow-y: auto;
}

.line-numbers {
    background: #111827;
    color: #6B7280;
    padding: 1rem 0.75rem;
    font-family: 'Fira Code', 'Monaco', 'Cascadia Code', 'Roboto Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    user-select: none;
    border-right: 1px solid #374151;
    min-width: 3rem;
    text-align: right;
    white-space: pre-line;
    flex-shrink: 0;
}

.code-block {
    flex: 1;
    background: #1a1a1a;
    color: #E5E7EB;
    font-family: 'Fira Code', 'Monaco', 'Cascadia Code', 'Roboto Mono', monospace;
    font-size: 0.875rem;
    line-height: 1.5;
    padding: 1rem;
    margin: 0;
    border: none;
    overflow: visible;
    white-space: pre-wrap;
    word-break: break-all;
    overflow-wrap: break-word;
}

/* Inline code styling */
code:not(.code-block) {
    background: #374151;
    color: #F87171;
    padding: 0.125rem 0.375rem;
    border-radius: 4px;
    font-family: 'Fira Code', 'Monaco', 'Cascadia Code', 'Roboto Mono', monospace;
    font-size: 0.875rem;
    white-space: nowrap;
}

/* Scrollbar styling for code content */
.code-content::-webkit-scrollbar {
    width: 8px;
}

.code-content::-webkit-scrollbar-track {
    background: #111827;
}

.code-content::-webkit-scrollbar-thumb {
    background: #374151;
    border-radius: 4px;
}

.code-content::-webkit-scrollbar-thumb:hover {
    background: #4B5563;
}