/*
 * Pipali Styles - Thoughts Component
 * Includes: thoughts section, tool results (grep, diff, bash, list)
 */

/* Thoughts Section */
.thoughts-section {
    margin-bottom: 4px;
}

.thoughts-section ::selection {
    background: var(--color-selection-bg);
    color: var(--color-selection-text);
}

.thoughts-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    background: var(--color-bg-muted);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    font-size: 12px;
    color: var(--color-text-secondary);
    cursor: pointer;
    transition: all var(--transition);
}

.thoughts-toggle:hover {
    background: var(--color-border);
}

.thoughts-summary {
    display: inline-flex;
    align-items: center;
    font-weight: 500;
}

.thoughts-summary-text {
    font-weight: 500;
}

/* Header row: toggle button */
.thoughts-header {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Grouped category icons with counts inside toggle */
.thoughts-icon-trail {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.trail-group {
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.trail-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    flex-shrink: 0;
}

.trail-icon--web {
    background: var(--color-info-bg);
    color: var(--color-info-text);
}

.trail-icon--read {
    background: var(--color-success-bg);
    color: var(--color-success-text);
}

.trail-icon--write {
    background: var(--color-warning-bg);
    color: var(--color-warning-text);
}

.trail-icon--execute {
    background: var(--color-execute-bg);
    color: var(--color-execute-text);
}

.trail-icon--other {
    background: var(--color-bg-muted);
    color: var(--color-text-muted);
}

.trail-icon--pending {
    animation: none;
}

.trail-group-count {
    font-size: 11px;
    font-weight: 600;
    color: var(--color-text-secondary);
    min-width: 8px;
}

.thoughts-chevron {
    flex-shrink: 0;
}

/* Streaming preview - shows latest thought while streaming */
.thoughts-preview {
    margin-top: 12px;
    padding-left: 8px;
    border-left: 2px solid var(--color-border);
    box-sizing: border-box;
    height: 96px;
    overflow-y: auto;
    overscroll-behavior: contain;
    scrollbar-gutter: stable;
}

.thoughts-preview .thought-item {
    padding-left: 12px;
}

.thoughts-list {
    margin-top: 12px;
    padding-left: 8px;
    border-left: 2px solid var(--color-border);
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.thought-item {
    display: flex;
    gap: 12px;
    padding-left: 12px;
}

.thought-item.clickable,
.thought-tool.clickable,
.thought-step.clickable {
    cursor: pointer;
}

.thought-step {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--color-bg-muted);
    border-radius: 50%;
    font-size: 11px;
    font-weight: 600;
    color: var(--color-text-secondary);
}

/* Reasoning dot - neutral dot for thought/reasoning items */
.thought-reasoning-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: block;
    background: var(--color-text-secondary);
}

/* Category dot inside step indicator (outline level) */
.thought-category-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    display: block;
}

.thought-category-dot--web {
    background: var(--color-info);
}

.thought-category-dot--read {
    background: var(--color-success);
}

.thought-category-dot--write {
    background: var(--color-write);
}

.thought-category-dot--execute {
    background: var(--color-execute-text);
}

.thought-category-dot--other {
    background: var(--color-text-muted);
}

.thought-category-dot--pending {
    animation: pulse-pending 1s ease-in-out infinite;
}

.thought-content {
    flex: 1;
    min-width: 0;
}

.thought-tool {
    font-size: 13px;
    font-weight: 500;
    color: var(--color-text);
    margin-bottom: 4px;
}

/* Operation type badge for MCP tool calls */
.thought-op-badge {
    display: inline-block;
    font-size: 9px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 1px 4px;
    border-radius: 3px;
    margin-left: 6px;
    vertical-align: middle;
}

.thought-op-badge--unsafe {
    background: var(--color-warning-bg);
    color: var(--color-warning-text);
}

.thought-args {
    font-weight: 400;
    color: var(--color-text-secondary);
    font-size: 12px;
}

.thought-args-primary {
    color: var(--color-text-secondary);
}

.thought-args-secondary {
    color: var(--color-text-muted);
}

.thought-args-link {
    color: var(--color-text-secondary);
    text-decoration: underline;
    text-decoration-color: var(--color-border);
    text-underline-offset: 2px;
}

.thought-args-link:hover {
    color: var(--color-text);
    text-decoration-color: var(--color-text-secondary);
}

.thought-reasoning {
    font-size: 13px;
    color: var(--color-text-secondary);
    margin-bottom: 6px;
    white-space: pre-wrap;
}

.thought-reasoning.italic {
    font-style: italic;
}

.thought-reasoning.outline {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Compact markdown for intermediate messages: full markdown at trajectory
   scale. Everything inherits the 13px container size; only spacing and
   chrome are tightened. */
.chat-markdown-compact {
    white-space: normal; /* markdown handles paragraph breaks; undo pre-wrap */
}

.chat-markdown-compact p {
    margin: 0 0 6px;
}

.chat-markdown-compact p:last-child {
    margin-bottom: 0;
}

.chat-markdown-compact .compact-heading {
    margin: 10px 0 4px;
    color: var(--color-text);
}

.chat-markdown-compact .compact-heading:first-child {
    margin-top: 0;
}

.chat-markdown-compact ul,
.chat-markdown-compact ol {
    margin: 4px 0 6px;
    padding-left: 18px;
}

.chat-markdown-compact li {
    margin: 2px 0;
}

.chat-markdown-compact table {
    border-collapse: collapse;
    margin: 6px 0;
    font-size: 12px;
}

.chat-markdown-compact th,
.chat-markdown-compact td {
    padding: 3px 8px;
    text-align: left;
    border: 1px solid var(--color-border);
}

.chat-markdown-compact th {
    background: var(--color-bg-muted);
    font-weight: 600;
    color: var(--color-text);
}

.chat-markdown-compact pre {
    margin: 6px 0;
    padding: 6px 8px;
    font-size: 12px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow-x: auto;
}

.chat-markdown-compact code {
    font-size: 12px;
}

/* Keep code upright inside italicized internal thoughts */
.thought-reasoning.italic .chat-markdown-compact code {
    font-style: normal;
}

.chat-markdown-compact blockquote {
    margin: 6px 0;
    padding-left: 8px;
    border-left: 2px solid var(--color-border);
}

/* Generic tool result view */
.thought-tool-result {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.tool-result-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg-muted);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
}

.tool-result-content {
    padding: 6px 8px;
}

.tool-result-line {
    font-family: var(--font-mono);
    font-size: 11px;
    color: var(--color-text-secondary);
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}

/* Thought diff view for edit operations */
.thought-diff {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.thought-diff-file-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-success-bg);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
}

.diff-file-content {
    padding: 0;
}

.thought-diff-line {
    display: flex;
    padding: 1px 8px;
    line-height: 1.5;
    white-space: pre-wrap;
    word-break: break-word;
}

.thought-diff-line.context {
    background: var(--color-bg-elevated);
    color: var(--color-text-muted);
}

.thought-diff-line.removed {
    background: var(--color-error-bg);
    color: var(--color-error-text);
}

.thought-diff-line.added {
    background: var(--color-success-bg);
    color: var(--color-success-text);
}

.thought-diff-indicator {
    flex-shrink: 0;
    width: 16px;
    font-weight: 600;
    user-select: none;
}

.thought-diff-content {
    flex: 1;
    min-width: 0;
}

/* Write file view */
.thought-write {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.write-file-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-success-bg);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
}

.write-file-content {
    padding: 0;
}

.write-file-line {
    display: flex;
    padding: 1px 8px;
    gap: 4px;
    line-height: 1.5;
}

.write-line-num {
    flex-shrink: 0;
    width: 28px;
    text-align: right;
    color: var(--color-text-muted);
    user-select: none;
}

.write-line-text {
    flex: 1;
    color: var(--color-text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
}

/* Thought step status indicators */
.thought-step.success {
    background: var(--color-success-bg);
    color: var(--color-success-text);
}

.thought-step.error {
    background: var(--color-error-bg);
    color: var(--color-error-text);
}

.thought-step.neutral {
    background: var(--color-bg-muted);
    color: var(--color-text-secondary);
}

.thought-step.pending {
    background: var(--color-warning-bg);
    color: var(--color-warning-text);
    animation: pulse-pending 1s ease-in-out infinite;
}

@keyframes pulse-pending {
    0%, 100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.5;
        transform: scale(0.8);
    }
}

/* Grep results view */
.thought-grep {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.grep-file-group {
    border-bottom: 1px solid var(--color-border);
}

.grep-file-group:last-child {
    border-bottom: none;
}

.grep-file-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg-muted);
    font-size: 11px;
}

.grep-result-line {
    display: flex;
    padding: 1px 8px;
    gap: 8px;
}

/* Matched line - highlighted */
.grep-result-line.match {
    background: #ffffe3;
}

/* Context line - dimmed */
.grep-result-line.context {
    opacity: 0.4;
}

.grep-line-num {
    flex-shrink: 0;
    width: 36px;
    text-align: right;
    color: var(--color-text-muted);
    user-select: none;
}

.grep-text {
    flex: 1;
    color: var(--color-text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
}

.grep-result-truncated {
    padding: 4px 8px;
    font-size: 11px;
    color: var(--color-text-muted);
    background: var(--color-bg-muted);
    border-top: 1px solid var(--color-border);
}

/* List files results view */
.thought-list {
    margin-top: 6px;
    border: 1px solid var(--color-border);
    border-radius: 4px;
    overflow: hidden;
    font-size: 11px;
    font-family: var(--font-mono);
    max-height: 200px;
    overflow-y: auto;
}

.list-dir-group {
    border-bottom: 1px solid var(--color-border);
}

.list-dir-group:last-child {
    border-bottom: none;
}

.list-dir-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg-muted);
    font-size: 11px;
}

.list-file-item {
    padding: 2px 8px 2px 16px;
}

.list-file-name {
    color: var(--color-text-secondary);
}

.list-result-truncated {
    padding: 4px 8px;
    font-size: 11px;
    color: var(--color-text-muted);
    background: var(--color-bg-muted);
    border-top: 1px solid var(--color-border);
}

/* Bash command results view */
.thought-bash {
    margin-top: 6px;
    font-size: 12px;
}

.bash-justification {
    display: flex;
    gap: 6px;
    padding: 6px 8px;
    background: var(--color-bg-muted);
    border-radius: 4px;
    margin-bottom: 6px;
    font-size: 11px;
    line-height: 1.4;
}

.bash-label {
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    font-size: 10px;
    flex-shrink: 0;
}

.bash-justification-text {
    color: var(--color-text-secondary);
}

.bash-command-block {
    border: 1px solid var(--color-border);
    border-radius: 4px;
    overflow: hidden;
    background: var(--color-code-bg);
}

.bash-command-header {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 4px 8px;
    background: var(--color-code-border);
    border-bottom: 1px solid var(--color-code-border);
}

.bash-cwd {
    font-family: var(--font-mono);
    font-size: 10px;
    color: var(--color-syntax-comment);
    background: none;
    padding: 0;
}

.bash-prompt {
    color: var(--color-syntax-keyword);
    font-weight: bold;
    font-size: 11px;
}

.bash-command-text {
    margin: 0;
    padding: 8px;
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 1.4;
    color: var(--color-code-text);
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 120px;
    overflow-y: auto;
}

.bash-command-text code {
    font-family: inherit;
    background: none;
    padding: 0;
    color: inherit;
}

.bash-output {
    margin-top: 6px;
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--color-border);
}

.bash-output.success {
    border-color: rgba(34, 197, 94, 0.25);
}

.bash-output.error {
    border-color: rgba(239, 68, 68, 0.25);
}

.bash-output-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 8px;
    background: var(--color-bg-muted);
    border-bottom: 1px solid var(--color-border);
}

.bash-output.success .bash-output-header {
    background: rgba(34, 197, 94, 0.06);
}

.bash-output.error .bash-output-header {
    background: rgba(239, 68, 68, 0.06);
}

.bash-expand-hint {
    font-size: 10px;
    color: var(--text-muted);
}

.bash-output-text {
    margin: 0;
    padding: 6px 8px;
    font-family: var(--font-mono);
    font-size: 11px;
    line-height: 1.4;
    color: var(--color-text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
    max-height: 150px;
    overflow-y: auto;
    background: var(--color-bg);
}

.bash-output.error .bash-output-text {
    color: #ef4444;
}

/* Read file results view */
.thought-read {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-family: var(--font-mono);
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.read-file-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg-muted);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
}

.read-file-content {
    padding: 0;
}

.read-file-line {
    display: flex;
    padding: 1px 8px;
    gap: 8px;
    line-height: 1.5;
}

.read-line-num {
    flex-shrink: 0;
    width: 36px;
    text-align: right;
    color: var(--color-text-muted);
    user-select: none;
}

.read-line-text {
    flex: 1;
    color: var(--color-text-secondary);
    white-space: pre-wrap;
    word-break: break-word;
}

/* Read file image view (for multimodal content) */
.read-file-meta {
    padding: 6px 8px;
    font-size: 11px;
    color: var(--color-text-muted);
    border-bottom: 1px solid var(--color-border);
}

.read-file-image {
    padding: 8px;
    display: flex;
    justify-content: left;
    background: var(--color-bg-muted);
}

.read-file-image img {
    max-width: 100%;
    max-height: 180px;
    object-fit: contain;
    border-radius: var(--radius-sm);
}


/* Web search results view */
.thought-web-search {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.thought-web-search.error {
    border-color: rgba(239, 68, 68, 0.25);
}

.web-search-header {
    padding: 4px 8px;
    font-weight: 600;
    color: var(--color-text);
    background: var(--color-bg-muted);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.web-search-query {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.web-search-content {
    padding: 8px;
    color: var(--color-text-secondary);
    font-size: 11px;
}

.web-search-results {
    padding: 0;
}

.web-search-result {
    padding: 6px 8px;
    border-bottom: 1px solid var(--color-border);
}

.web-search-result:last-child {
    border-bottom: none;
}

.web-search-title {
    font-weight: 500;
    color: var(--color-text);
    font-size: 12px;
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.web-search-link {
    font-size: 10px;
    color: var(--color-link);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.web-search-snippet {
    font-size: 11px;
    color: var(--color-text-muted);
    line-height: 1.4;
    display: -webkit-box;
    line-clamp: 2;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}


/* Webpage content view */
.thought-webpage {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
    background: var(--color-bg-elevated);
}

.thought-webpage.error {
    border-color: rgba(239, 68, 68, 0.25);
}

.webpage-header {
    padding: 4px 8px;
    background: var(--color-bg-muted);
    font-size: 11px;
    border-bottom: 1px solid var(--color-border);
    position: sticky;
    top: 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.webpage-domain {
    font-weight: 600;
    color: var(--color-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.webpage-content {
    padding: 6px 8px;
}

/* Markdown styling within webpage content */
.webpage-content.webpage-markdown {
    font-size: 11px;
    line-height: 1.5;
    color: var(--color-text-secondary);
}

.webpage-content.webpage-markdown h1,
.webpage-content.webpage-markdown h2,
.webpage-content.webpage-markdown h3,
.webpage-content.webpage-markdown h4,
.webpage-content.webpage-markdown h5,
.webpage-content.webpage-markdown h6 {
    font-size: 12px;
    font-weight: 600;
    color: var(--color-text);
    margin: 8px 0 4px 0;
}

.webpage-content.webpage-markdown h1:first-child,
.webpage-content.webpage-markdown h2:first-child,
.webpage-content.webpage-markdown h3:first-child {
    margin-top: 0;
}

.webpage-content.webpage-markdown p {
    margin: 4px 0;
}

.webpage-content.webpage-markdown ul,
.webpage-content.webpage-markdown ol {
    margin: 4px 0;
    padding-left: 16px;
}

.webpage-content.webpage-markdown li {
    margin: 2px 0;
}

.webpage-content.webpage-markdown a {
    color: var(--color-link);
    text-decoration: none;
}

.webpage-content.webpage-markdown a:visited {
    color: var(--color-link-visited);
}

.webpage-content.webpage-markdown a:hover {
    text-decoration: underline;
}

.webpage-content.webpage-markdown code {
    font-family: var(--font-mono);
    font-size: 10px;
    background: var(--color-bg-muted);
    padding: 1px 4px;
    border-radius: 2px;
}

.webpage-content.webpage-markdown pre {
    background: var(--color-bg-muted);
    padding: 6px 8px;
    border-radius: 4px;
    overflow-x: auto;
    margin: 4px 0;
}

.webpage-content.webpage-markdown pre code {
    background: none;
    padding: 0;
}

.webpage-content.webpage-markdown blockquote {
    border-left: 2px solid var(--color-border);
    margin: 4px 0;
    padding-left: 8px;
    color: var(--color-text-muted);
}

.webpage-content.webpage-markdown table {
    border-collapse: collapse;
    font-size: 10px;
    margin: 4px 0;
}

.webpage-content.webpage-markdown th,
.webpage-content.webpage-markdown td {
    border: 1px solid var(--color-border);
    padding: 4px 6px;
}

.webpage-content.webpage-markdown th {
    background: var(--color-bg-muted);
    font-weight: 600;
}

.thought-webpage.error .webpage-content {
    color: #ef4444;
}

/* Chrome snapshot view */
.thought-snapshot {
    margin-top: 8px;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-sm);
    overflow: hidden;
    font-size: 12px;
    background: var(--color-bg-elevated);
}

.snapshot-header {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    font-weight: 600;
    font-size: 11px;
    color: var(--color-text);
    background: var(--color-bg-muted);
    border-bottom: 1px solid var(--color-border);
}

.snapshot-title {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.snapshot-url {
    font-weight: 400;
    color: var(--color-text-muted);
    font-size: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 200px;
}

.snapshot-tree {
    max-height: 300px;
    overflow-y: auto;
    padding: 4px 0;
}

.snapshot-node {
    display: flex;
    align-items: baseline;
    gap: 4px;
    padding: 1px 4px;
    line-height: 1.6;
    font-size: 11px;
}

.snapshot-badge {
    display: inline-block;
    font-size: 9px;
    font-weight: 600;
    padding: 0 3px;
    border-radius: 2px;
    flex-shrink: 0;
    line-height: 1.4;
}

.snapshot-label {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.snapshot-value {
    color: var(--color-text-muted);
    font-size: 10px;
    font-style: italic;
}

.snapshot-value::before {
    content: "= ";
}

.snapshot-attr {
    color: var(--color-text-muted);
    font-size: 9px;
}

/* Role-based styling */
.snapshot-role-interactive .snapshot-badge {
    background: var(--color-accent-bg);
    color: var(--color-accent);
    border: 1px solid color-mix(in srgb, var(--color-accent) 30%, transparent);
}

.snapshot-role-link .snapshot-label {
    color: var(--color-accent);
}

.snapshot-role-button .snapshot-badge {
    background: var(--color-bg-muted);
    color: var(--color-text-secondary);
    border: 1px solid var(--color-border);
}

.snapshot-role-structure .snapshot-badge {
    background: transparent;
    color: var(--color-text-muted);
    font-weight: 700;
}

.snapshot-role-heading .snapshot-label {
    font-weight: 600;
}

.snapshot-role-text {
    color: var(--color-text-muted);
}

.snapshot-role-text .snapshot-label {
    font-style: italic;
}

.snapshot-role-image .snapshot-badge {
    background: var(--color-bg-muted);
    color: var(--color-text-secondary);
}

.snapshot-more {
    padding: 4px 8px;
    font-size: 10px;
    color: var(--color-text-muted);
    font-style: italic;
}

.snapshot-footer {
    padding: 2px 8px;
    font-size: 10px;
    color: var(--color-text-muted);
    border-top: 1px solid var(--color-border);
    background: var(--color-bg-muted);
}

/* Chrome page list (list_pages, navigate_page, etc.) */
.chrome-page-list {
    padding: 4px 0;
}

.chrome-page-entry {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 2px 8px;
    font-size: 11px;
    line-height: 1.6;
}

.chrome-page-id {
    flex-shrink: 0;
    width: 16px;
    text-align: right;
    color: var(--color-text-muted);
    font-size: 10px;
}

.chrome-page-url {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--color-text-secondary);
}

.chrome-page-entry.selected .chrome-page-url {
    color: var(--color-text);
}

.chrome-page-badge {
    flex-shrink: 0;
    font-size: 9px;
    font-weight: 600;
    padding: 0 4px;
    border-radius: 2px;
    background: var(--color-accent-bg);
    color: var(--color-accent);
    border: 1px solid color-mix(in srgb, var(--color-accent) 30%, transparent);
}
