/* Gemini for Excel — Sidebar Taskpane Styles */

:root {
    --bg-primary: #0f0f14;
    --bg-secondary: #1a1a24;
    --bg-tertiary: #242434;
    --bg-hover: #2a2a3e;
    --surface: #1e1e2e;
    --text-primary: #e8e8f0;
    --text-secondary: #9898b0;
    --text-muted: #6868808c;
    --accent: #4285f4;
    --accent-hover: #5a9af5;
    --accent-glow: rgba(66, 133, 244, 0.15);
    --gemini-gradient: linear-gradient(135deg, #4285f4 0%, #9b72cb 50%, #d96570 100%);
    --user-bg: #1e3a5f;
    --assistant-bg: #1e1e2e;
    --border: #2a2a3e;
    --success: #34a853;
    --warning: #fbbc04;
    --error: #ea4335;
    --radius: 12px;
    --radius-sm: 8px;
    --shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    --transition: 200ms cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-primary);
    color: var(--text-primary);
    height: 100vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    -webkit-font-smoothing: antialiased;
}

/* Header */
.header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border);
    flex-shrink: 0;
}

.header-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.gemini-icon {
    color: transparent;
    background: var(--gemini-gradient);
    -webkit-background-clip: text;
    background-clip: text;
    filter: drop-shadow(0 0 6px rgba(66, 133, 244, 0.4));
}

.gemini-icon path {
    fill: url(#gemini-grad);
}

.header-logo h1 {
    font-size: 16px;
    font-weight: 700;
    background: var(--gemini-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.icon-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 6px;
    border-radius: 6px;
    transition: all var(--transition);
    display: flex;
    align-items: center;
}

.icon-btn:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    transition: background var(--transition);
}

.status-dot.connected {
    background: var(--success);
    box-shadow: 0 0 8px rgba(52, 168, 83, 0.5);
}

.status-dot.disconnected {
    background: var(--error);
    box-shadow: 0 0 8px rgba(234, 67, 53, 0.5);
}

.status-dot.loading {
    background: var(--warning);
    box-shadow: 0 0 8px rgba(251, 188, 4, 0.5);
    animation: pulse 1.5s infinite;
}

.status-label {
    font-size: 10px;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

@keyframes pulse {

    0%,
    100% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }
}

/* Connection Banner */
.connection-banner {
    background: linear-gradient(135deg, rgba(255, 167, 38, 0.12), rgba(255, 167, 38, 0.06));
    border-bottom: 1px solid rgba(255, 167, 38, 0.25);
    padding: 14px 16px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.connection-banner.hidden {
    display: none;
}

.banner-content {
    display: flex;
    align-items: center;
    gap: 10px;
}

.banner-icon {
    font-size: 20px;
    flex-shrink: 0;
}

.banner-text {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.banner-text strong {
    font-size: 12px;
    color: var(--text-primary);
}

.banner-text span {
    font-size: 11px;
    color: var(--text-secondary);
}

.start-server-btn {
    width: 100%;
    padding: 8px 16px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 12px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: all var(--transition);
}

.start-server-btn:hover {
    background: var(--accent-hover);
    transform: translateY(-1px);
}

.start-server-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

/* Disconnect button */
.disconnect-btn {
    color: var(--text-secondary) !important;
    transition: color var(--transition);
}

.disconnect-btn:hover {
    color: var(--error) !important;
}

.hidden {
    display: none !important;
}

/* Chat Container */
.chat-container {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 12px;
    scroll-behavior: smooth;
}

.chat-container::-webkit-scrollbar {
    width: 4px;
}

.chat-container::-webkit-scrollbar-track {
    background: transparent;
}

.chat-container::-webkit-scrollbar-thumb {
    background: var(--bg-tertiary);
    border-radius: 4px;
}

/* Welcome Message */
.welcome-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 24px 16px;
    flex: 1;
}

.welcome-icon {
    font-size: 40px;
    margin-bottom: 12px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

.welcome-message h2 {
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 8px;
    background: var(--gemini-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.welcome-message p {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    max-width: 280px;
}

.quick-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    margin-top: 20px;
    width: 100%;
    max-width: 320px;
}

.quick-action {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    color: var(--text-primary);
    padding: 10px 12px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    cursor: pointer;
    text-align: left;
    transition: all var(--transition);
    font-family: inherit;
}

.quick-action:hover {
    background: var(--bg-hover);
    border-color: var(--accent);
    box-shadow: 0 0 12px var(--accent-glow);
    transform: translateY(-1px);
}

/* Chat Messages */
.message {
    display: flex;
    flex-direction: column;
    gap: 4px;
    max-width: 100%;
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(8px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message-bubble {
    padding: 10px 14px;
    border-radius: var(--radius);
    font-size: 13px;
    line-height: 1.55;
    word-wrap: break-word;
    white-space: pre-wrap;
}

.message.user .message-bubble {
    background: var(--user-bg);
    border: 1px solid rgba(66, 133, 244, 0.2);
    align-self: flex-end;
    border-bottom-right-radius: 4px;
}

.message.assistant .message-bubble {
    background: var(--assistant-bg);
    border: 1px solid var(--border);
    border-bottom-left-radius: 4px;
}

.message-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 11px;
    color: var(--text-muted);
    padding: 0 4px;
}

.message.user .message-meta {
    justify-content: flex-end;
}

/* Operations badge */
.ops-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    padding: 4px 10px;
    background: rgba(52, 168, 83, 0.15);
    border: 1px solid rgba(52, 168, 83, 0.3);
    border-radius: 20px;
    font-size: 11px;
    color: var(--success);
}

.ops-badge-error {
    background: rgba(234, 67, 53, 0.15);
    border-color: rgba(234, 67, 53, 0.3);
    color: var(--error);
    cursor: help;
}

/* Citations */
.citations {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 6px;
}

.citation {
    padding: 2px 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    font-size: 11px;
    color: var(--accent);
    font-family: 'SF Mono', 'Fira Code', monospace;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.citation:hover {
    background: var(--accent);
    color: #fff;
}

/* Thinking indicator */
.thinking {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 10px 14px;
    background: var(--assistant-bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    font-size: 13px;
    color: var(--text-secondary);
}

.thinking-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.thinking-thoughts {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.thinking-thoughts:empty {
    display: none;
}

.thinking-dots {
    display: flex;
    gap: 3px;
}

.thinking-dots span {
    width: 6px;
    height: 6px;
    background: var(--accent);
    border-radius: 50%;
    animation: thinking 1.4s infinite;
}

.thinking-dots span:nth-child(2) {
    animation-delay: 0.2s;
}

.thinking-dots span:nth-child(3) {
    animation-delay: 0.4s;
}

@keyframes thinking {

    0%,
    80%,
    100% {
        opacity: 0.3;
        transform: scale(0.8);
    }

    40% {
        opacity: 1;
        transform: scale(1);
    }
}

/* Thought Bubbles */
.thought-bubble {
    background: linear-gradient(135deg, rgba(66, 133, 244, 0.06), rgba(155, 114, 203, 0.06));
    border: 1px solid rgba(66, 133, 244, 0.15);
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 12px;
    animation: slideIn 0.2s ease-out;
}

.thought-bubble summary {
    cursor: pointer;
    color: var(--text-secondary);
    font-weight: 500;
    list-style: none;
    display: flex;
    align-items: center;
    gap: 4px;
    user-select: none;
}

.thought-bubble summary::-webkit-details-marker {
    display: none;
}

.thought-bubble summary::before {
    content: '▶';
    font-size: 8px;
    transition: transform 0.2s ease;
    color: var(--text-muted);
}

.thought-bubble[open] summary::before {
    transform: rotate(90deg);
}

.thought-icon {
    font-size: 13px;
}

.thought-description {
    margin: 4px 0 2px 18px;
    color: var(--text-muted);
    font-size: 11px;
    line-height: 1.5;
    font-style: italic;
}

/* Office Script Code Blocks */
.script-block {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    margin: 4px 0;
}

.script-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: var(--surface-hover);
    border-bottom: 1px solid var(--border);
}

.script-name {
    font-weight: 600;
    font-size: 13px;
    color: var(--text-primary);
}

.script-copy-btn {
    background: var(--accent);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 4px 10px;
    font-size: 12px;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.script-copy-btn:hover {
    background: var(--accent-hover);
    transform: scale(1.02);
}

.script-code {
    margin: 0;
    padding: 14px;
    background: #1e1e2e;
    color: #cdd6f4;
    font-family: 'SF Mono', 'Fira Mono', 'Cascadia Code', monospace;
    font-size: 12px;
    line-height: 1.6;
    overflow-x: auto;
    white-space: pre;
}

.script-code code {
    font-family: inherit;
    font-size: inherit;
}

.script-instructions {
    padding: 8px 14px;
    font-size: 11px;
    color: var(--text-muted);
    background: var(--surface-hover);
    border-top: 1px solid var(--border);
}

/* Input Area */
.input-area {
    padding: 12px 16px 16px;
    background: var(--bg-secondary);
    border-top: 1px solid var(--border);
    flex-shrink: 0;
}

.input-wrapper {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 8px 12px;
    transition: border-color var(--transition), box-shadow var(--transition);
}

.input-wrapper:focus-within {
    border-color: var(--accent);
    box-shadow: 0 0 0 3px var(--accent-glow);
}

#prompt-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--text-primary);
    font-family: inherit;
    font-size: 13px;
    resize: none;
    outline: none;
    max-height: 120px;
    line-height: 1.5;
}

#prompt-input::placeholder {
    color: var(--text-muted);
}

.send-btn {
    background: var(--accent);
    border: none;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition);
    flex-shrink: 0;
}

.send-btn:hover:not(:disabled) {
    background: var(--accent-hover);
    transform: scale(1.05);
}

.send-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.input-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 6px;
    padding: 0 4px;
}

.input-footer-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Auto-apply toggle switch */
.auto-apply-toggle {
    display: flex;
    align-items: center;
    gap: 6px;
    cursor: pointer;
    font-size: 11px;
    color: var(--text-secondary);
    user-select: none;
}

.auto-apply-toggle input[type="checkbox"] {
    display: none;
}

.toggle-slider {
    position: relative;
    width: 28px;
    height: 16px;
    background: var(--bg-tertiary);
    border-radius: 8px;
    transition: background var(--transition);
    flex-shrink: 0;
}

.toggle-slider::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width: 12px;
    height: 12px;
    background: var(--text-muted);
    border-radius: 50%;
    transition: transform var(--transition), background var(--transition);
}

.auto-apply-toggle input:checked+.toggle-slider {
    background: var(--accent);
}

.auto-apply-toggle input:checked+.toggle-slider::after {
    transform: translateX(12px);
    background: white;
}

.toggle-label {
    font-size: 11px;
    white-space: nowrap;
}

.shortcut-hint {
    font-size: 10px;
    color: var(--text-muted);
    white-space: nowrap;
}

.workbook-info {
    font-size: 11px;
    color: var(--text-muted);
}

/* Error message */
.error-bubble {
    background: rgba(234, 67, 53, 0.1) !important;
    border-color: rgba(234, 67, 53, 0.3) !important;
    color: var(--error) !important;
}

/* PDF Attachment */
.pdf-attachment {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    margin-bottom: 8px;
    background: rgba(155, 114, 203, 0.12);
    border: 1px solid rgba(155, 114, 203, 0.3);
    border-radius: var(--radius-sm);
    font-size: 12px;
    color: var(--text-primary);
    animation: slideIn 0.2s ease-out;
}

.pdf-icon {
    font-size: 16px;
}

.pdf-name {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: #c4a1e8;
    font-weight: 500;
}

.pdf-clear {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 16px;
    padding: 0 2px;
    line-height: 1;
    transition: color var(--transition);
}

.pdf-clear:hover {
    color: var(--error);
}

.icon-btn.pdf-active {
    color: #c4a1e8;
    background: rgba(155, 114, 203, 0.15);
}

/* PDF upload badge in messages */
.pdf-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    padding: 4px 10px;
    background: rgba(155, 114, 203, 0.15);
    border: 1px solid rgba(155, 114, 203, 0.3);
    border-radius: 20px;
    font-size: 11px;
    color: #c4a1e8;
}

/* File Attachments */
.file-attachments {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 4px;
}

.file-attachments:empty {
    display: none;
}

.file-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 10px;
    background: rgba(66, 133, 244, 0.12);
    border: 1px solid rgba(66, 133, 244, 0.3);
    border-radius: 20px;
    font-size: 11px;
    color: var(--text-primary);
    animation: slideIn 0.2s ease-out;
}

.file-pill-icon {
    font-size: 13px;
}

.file-pill-name {
    max-width: 120px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    color: var(--accent-hover);
    font-weight: 500;
}

.file-pill-remove {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 14px;
    padding: 0 2px;
    line-height: 1;
    transition: color var(--transition);
}

.file-pill-remove:hover {
    color: var(--error);
}



/* Settings Modal */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.15s ease-out;
}

.modal-overlay.hidden {
    display: none;
}

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    width: 90%;
    max-width: 380px;
    box-shadow: 0 16px 48px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.2s ease-out;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
}

.modal-header h2 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 22px;
    cursor: pointer;
    padding: 0 4px;
    line-height: 1;
    transition: color var(--transition);
}

.modal-close:hover {
    color: var(--text-primary);
}

.modal-body {
    padding: 20px;
    overflow-y: auto;
    max-height: calc(100vh - 120px);
}

.settings-group {
    margin-bottom: 20px;
}

.settings-group:last-child {
    margin-bottom: 0;
}

.settings-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.settings-desc {
    font-size: 11px;
    color: var(--text-secondary);
    margin-bottom: 10px;
    line-height: 1.5;
}

/* Keyboard Shortcuts Display */
.shortcut-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 8px;
}

.shortcut-row {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
    color: var(--text-secondary);
}

.shortcut-row span {
    margin-left: auto;
    color: var(--text-muted);
    font-size: 11px;
}

kbd {
    display: inline-block;
    padding: 2px 7px;
    font-family: inherit;
    font-size: 11px;
    color: var(--text-primary);
    background: var(--bg-tertiary);
    border: 1px solid var(--border);
    border-radius: 4px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(12px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Markdown inside chat bubbles */
.message-bubble h1,
.message-bubble h2,
.message-bubble h3,
.message-bubble h4 {
    margin: 12px 0 6px 0;
    font-weight: 600;
    line-height: 1.3;
}

.message-bubble h1 {
    font-size: 1.15em;
}

.message-bubble h2 {
    font-size: 1.08em;
}

.message-bubble h3 {
    font-size: 1em;
}

.message-bubble h4 {
    font-size: 0.95em;
    color: var(--text-secondary);
}

.message-bubble p {
    margin: 6px 0;
    line-height: 1.55;
}

.message-bubble ul,
.message-bubble ol {
    margin: 6px 0;
    padding-left: 20px;
}

.message-bubble li {
    margin: 3px 0;
    line-height: 1.5;
}

.message-bubble code {
    background: rgba(255, 255, 255, 0.08);
    padding: 1px 5px;
    border-radius: 4px;
    font-family: 'SF Mono', 'Fira Code', 'Consolas', monospace;
    font-size: 0.88em;
    color: #e8b4f8;
}

.message-bubble pre {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 10px 12px;
    margin: 8px 0;
    overflow-x: auto;
    font-size: 12px;
    line-height: 1.5;
}

.message-bubble pre code {
    background: none;
    padding: 0;
    color: #c8d0e0;
    font-size: inherit;
}

.message-bubble blockquote {
    border-left: 3px solid var(--accent);
    padding-left: 12px;
    margin: 8px 0;
    color: var(--text-secondary);
    font-style: italic;
}

.message-bubble table {
    border-collapse: collapse;
    width: 100%;
    margin: 8px 0;
    font-size: 12px;
}

.message-bubble th,
.message-bubble td {
    border: 1px solid var(--border);
    padding: 6px 10px;
    text-align: left;
}

.message-bubble th {
    background: var(--bg-tertiary);
    font-weight: 600;
}

.message-bubble tr:nth-child(even) {
    background: rgba(255, 255, 255, 0.02);
}

.message-bubble strong {
    font-weight: 600;
    color: var(--text-primary);
}

.message-bubble a {
    color: var(--accent-hover);
    text-decoration: none;
}

.message-bubble a:hover {
    text-decoration: underline;
}

.message-bubble hr {
    border: none;
    border-top: 1px solid var(--border);
    margin: 12px 0;
}

/* Review Before Edit */
.review-card {
    border: 1px solid var(--accent);
    border-left: 3px solid var(--accent);
}

.review-explanation {
    font-size: 13px;
    color: var(--text-primary);
    line-height: 1.5;
    margin-bottom: 10px;
    padding-bottom: 8px;
    border-bottom: 1px solid var(--border);
}

.review-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 13px;
}

.review-count {
    font-size: 11px;
    color: var(--text-secondary);
    padding: 1px 6px;
    background: var(--bg-tertiary);
    border-radius: 10px;
}

.review-op-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 10px;
    max-height: 200px;
    overflow-y: auto;
}

.review-op-row {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 8px;
    background: var(--bg-tertiary);
    border-radius: 4px;
    font-size: 11px;
}

.review-op-action {
    font-weight: 600;
    color: var(--accent);
    text-transform: capitalize;
    white-space: nowrap;
}

.review-op-range {
    font-family: 'SF Mono', 'Fira Code', monospace;
    color: var(--text-secondary);
    white-space: nowrap;
}

.review-op-value {
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 150px;
}

.review-actions {
    display: flex;
    gap: 8px;
}

.review-btn {
    flex: 1;
    padding: 6px 12px;
    border: none;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: opacity 0.15s;
}

.review-btn:hover {
    opacity: 0.85;
}

.review-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.review-btn-apply {
    background: #28A745;
    color: #fff;
}

.review-btn-dismiss {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.review-applied,
.review-dismissed {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-secondary);
}

/* Clear Highlights Button */
.clear-highlights-wrapper {
    display: flex;
    justify-content: center;
    padding: 4px 0;
}

.clear-highlights-btn {
    padding: 4px 12px;
    border: 1px solid var(--border);
    border-radius: 12px;
    background: var(--bg-tertiary);
    color: var(--text-secondary);
    font-size: 11px;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
}

.clear-highlights-btn:hover {
    background: var(--accent);
    color: #fff;
    border-color: var(--accent);
}

.clear-highlights-done {
    font-size: 11px;
    color: var(--text-secondary);
}

/* Auth Code Modal */
.auth-modal {
    max-width: 340px;
}

.auth-modal-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-bottom: 12px;
    line-height: 1.5;
}

.auth-code-input {
    width: 100%;
    padding: 10px 12px;
    background: var(--bg-primary);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 14px;
    font-family: 'SF Mono', 'Fira Code', monospace;
    margin-bottom: 12px;
    outline: none;
    transition: border-color var(--transition);
}

.auth-code-input:focus {
    border-color: var(--accent);
}

.auth-submit-btn {
    width: 100%;
}

/* Retry Button */
.retry-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 8px;
    padding: 4px 10px;
    border: 1px solid rgba(234, 67, 53, 0.3);
    border-radius: 12px;
    background: rgba(234, 67, 53, 0.1);
    color: var(--error);
    font-size: 11px;
    cursor: pointer;
    transition: background var(--transition);
}

.retry-btn:hover {
    background: rgba(234, 67, 53, 0.2);
}

/* Queued Message Badge */
.queued-badge {
    display: inline-block;
    font-size: 10px;
    color: var(--text-muted);
    margin-top: 4px;
    padding: 2px 6px;
    background: var(--bg-tertiary);
    border-radius: 8px;
}

/* Error Banner */
.error-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(234, 67, 53, 0.1);
    border: 1px solid rgba(234, 67, 53, 0.3);
    border-radius: var(--radius-sm);
    color: var(--error);
    font-size: 12px;
    margin: 4px 16px;
    flex-shrink: 0;
    animation: fadeIn 0.3s ease;
}

.error-banner .dismiss-banner {
    margin-left: auto;
    background: none;
    border: none;
    color: var(--error);
    cursor: pointer;
    font-size: 16px;
    padding: 0 4px;
}

/* Step Progress */
.step-progress {
    font-size: 11px;
    color: var(--text-secondary);
    margin-top: 4px;
    opacity: 0.8;
}

.step-elapsed {
    color: var(--text-muted);
    font-size: 10px;
    margin-left: 6px;
}

/* Settings Saved Feedback */
.settings-saved {
    font-size: 11px;
    color: var(--success);
    padding: 4px 8px;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-4px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}