body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: var(--vscode-editor-background);
    color: var(--vscode-editor-foreground);
}

.container {
    max-width: 800px;
    margin: 0 auto;
}

.header {
    border-bottom: 1px solid var(--vscode-panel-border);
    padding-bottom: 20px;
    margin-bottom: 20px;
}

.controls {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

button {
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    text-transform: none;
}

.btn-icon {
    font-size: 16px;
    line-height: 1;
}

/* Primary Button - Blue */
.btn-primary {
    background: linear-gradient(135deg, #007acc 0%, #0099ff 100%);
    color: white;
}

.btn-primary:hover:not(:disabled) {
    background: linear-gradient(135deg, #0066aa 0%, #0088ee 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 122, 204, 0.4);
}

/* Success Button - Green */
.btn-success {
    background: linear-gradient(135deg, #28a745 0%, #34ce57 100%);
    color: white;
}

.btn-success:hover:not(:disabled) {
    background: linear-gradient(135deg, #218838 0%, #28a745 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(40, 167, 69, 0.4);
}

/* Danger Button - Red */
.btn-danger {
    background: linear-gradient(135deg, #dc3545 0%, #ff4757 100%);
    color: white;
}

.btn-danger:hover:not(:disabled) {
    background: linear-gradient(135deg, #c82333 0%, #dc3545 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(220, 53, 69, 0.4);
}

/* Warning Button - Orange */
.btn-warning {
    background: linear-gradient(135deg, #fd7e14 0%, #ff9f43 100%);
    color: white;
}

.btn-warning:hover:not(:disabled) {
    background: linear-gradient(135deg, #e8690b 0%, #fd7e14 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(253, 126, 20, 0.4);
}

/* Secondary Button - Gray */
.btn-secondary {
    background: linear-gradient(135deg, #6c757d 0%, #868e96 100%);
    color: white;
}

.btn-secondary:hover:not(:disabled) {
    background: linear-gradient(135deg, #5a6268 0%, #6c757d 100%);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(108, 117, 125, 0.4);
}

button:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    background: linear-gradient(135deg, #6c757d 0%, #868e96 100%) !important;
}

button:disabled .btn-icon {
    opacity: 0.7;
}

.input-section {
    margin-bottom: 20px;
}

textarea {
    width: calc(100% - 20px);
    min-height: 100px;
    padding: 10px;
    border: 1px solid var(--vscode-input-border);
    border-radius: 4px;
    background-color: var(--vscode-input-background);
    color: var(--vscode-input-foreground);
    font-family: inherit;
    font-size: 14px;
    resize: vertical;
}

.queue-section {
    margin-top: 20px;
}

.queue-header, .history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px 0;
    border-bottom: 1px solid var(--vscode-panel-border);
}

.queue-controls, .history-controls {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-small {
    padding: 6px 12px;
    font-size: 12px;
}

select {
    background-color: var(--vscode-input-background);
    color: var(--vscode-input-foreground);
    border: 1px solid var(--vscode-input-border);
    border-radius: 4px;
    padding: 6px 8px;
    font-size: 12px;
    cursor: pointer;
}

select:focus {
    outline: 1px solid var(--vscode-focusBorder);
    outline-offset: 2px;
}

.queue-item {
    border: 1px solid var(--vscode-panel-border);
    border-radius: 4px;
    padding: 15px;
    margin-bottom: 10px;
    background-color: var(--vscode-editor-background);
}

.queue-item.pending {
    border-left: 4px solid var(--vscode-charts-yellow);
}

.queue-item.processing {
    border-left: 4px solid var(--vscode-charts-blue);
}

.queue-item.completed {
    border-left: 4px solid var(--vscode-charts-green);
}

.queue-item.error {
    border-left: 4px solid var(--vscode-charts-red);
}

.queue-item.waiting {
    border-left: 4px solid var(--vscode-charts-orange);
}

.queue-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.queue-item-status {
    font-weight: bold;
    text-transform: uppercase;
    font-size: 12px;
}

.queue-item-time {
    font-size: 12px;
    color: var(--vscode-descriptionForeground);
}

.queue-item-text {
    margin-bottom: 10px;
    word-wrap: break-word;
}

.queue-item-output {
    background-color: var(--vscode-textCodeBlock-background);
    padding: 10px;
    border-radius: 4px;
    white-space: pre-wrap;
    font-family: monospace;
    font-size: 12px;
    max-height: 200px;
    overflow-y: auto;
}

.queue-item-error {
    color: var(--vscode-charts-red);
    font-weight: bold;
}

.countdown {
    color: var(--vscode-charts-orange);
    font-weight: bold;
}

.empty-queue, .empty-history {
    text-align: center;
    color: var(--vscode-descriptionForeground);
    padding: 40px;
}

.queue-item {
    position: relative;
    cursor: grab;
}

.queue-item:active {
    cursor: grabbing;
}

.queue-item[draggable="false"] {
    cursor: default;
    opacity: 0.8;
}

.queue-item[draggable="false"]:hover {
    cursor: default;
}

.queue-item-actions {
    position: absolute;
    top: 10px;
    right: 10px;
    display: flex;
    gap: 5px;
    opacity: 0;
    transition: opacity 0.2s ease;
}

.queue-item:hover .queue-item-actions {
    opacity: 1;
}

.queue-item-action {
    background: var(--vscode-button-secondaryBackground);
    color: var(--vscode-button-secondaryForeground);
    border: none;
    border-radius: 3px;
    padding: 4px 6px;
    font-size: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.queue-item-action:hover {
    background: var(--vscode-button-secondaryHoverBackground);
}

.queue-item-action.remove {
    background: var(--vscode-charts-red);
    color: white;
}

.queue-item-action.remove:hover {
    background: #d32f2f;
}

.queue-item-action.duplicate {
    background: var(--vscode-charts-blue);
    color: white;
}

.queue-item-action.duplicate:hover {
    background: #1976d2;
}

.queue-item-action.edit {
    background: var(--vscode-charts-orange);
    color: white;
}

.queue-item-action.edit:hover {
    background: #f57c00;
}

.history-section {
    margin-top: 30px;
}

.history-item {
    border: 1px solid var(--vscode-panel-border);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    background: var(--vscode-editor-background);
    transition: all 0.2s ease;
}

.history-item:hover {
    background: var(--vscode-list-hoverBackground);
}

.history-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.history-item-title {
    font-weight: bold;
    color: var(--vscode-editor-foreground);
}

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

.history-item-action {
    background: var(--vscode-button-secondaryBackground);
    color: var(--vscode-button-secondaryForeground);
    border: none;
    border-radius: 3px;
    padding: 4px 6px;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.history-item-action:hover {
    background: var(--vscode-button-secondaryHoverBackground);
}

.history-item-action.delete {
    background: var(--vscode-charts-red);
    color: white;
}

.history-item-action.delete:hover {
    background: #d32f2f;
}

.history-item-time {
    font-size: 12px;
    color: var(--vscode-descriptionForeground);
}

.history-item-stats {
    display: flex;
    gap: 15px;
    margin-bottom: 10px;
    font-size: 12px;
}

.history-stat {
    display: flex;
    align-items: center;
    gap: 4px;
}

.history-stat-completed {
    color: var(--vscode-charts-green);
}

.history-stat-errors {
    color: var(--vscode-charts-red);
}

.history-stat-waiting {
    color: var(--vscode-charts-orange);
}

.history-stat-total {
    color: var(--vscode-charts-blue);
}

.history-item-messages {
    max-height: 200px;
    overflow-y: auto;
    background: var(--vscode-textCodeBlock-background);
    border-radius: 4px;
    padding: 10px;
    margin-top: 10px;
}

.history-message {
    padding: 5px 0;
    border-bottom: 1px solid var(--vscode-panel-border);
    font-size: 12px;
}

.history-message:last-child {
    border-bottom: none;
}

.history-message-text {
    margin-bottom: 3px;
}

.history-message-meta {
    display: flex;
    justify-content: space-between;
    font-size: 10px;
    color: var(--vscode-descriptionForeground);
}

.claude-output-section {
    margin: 20px 0;
}

.claude-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px 15px;
    background: linear-gradient(135deg, #1a1d3a 0%, #2a2d5a 100%);
    border-radius: 8px;
    border: 1px solid #4a9eff;
}

.claude-title {
    margin: 0;
    color: #4a9eff;
    font-size: 18px;
    font-weight: 600;
    text-shadow: 0 0 10px rgba(74, 158, 255, 0.5);
}

.clear-button {
    background: linear-gradient(135deg, #ff6b6b 0%, #ff8787 100%);
    color: white;
    border: none;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(255, 107, 107, 0.3);
}

.clear-button:hover {
    background: linear-gradient(135deg, #ff5252 0%, #ff7575 100%);
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(255, 107, 107, 0.4);
}

.claude-ready-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    opacity: 0.7;
    font-style: italic;
    color: #9ca3af;
    flex-direction: column;
}

.pulse-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #4a9eff;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
        transform: scale(1);
    }

    50% {
        opacity: 0.5;
        transform: scale(1.2);
    }

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

.claude-live-output {
    background: linear-gradient(135deg, #0a0e1a 0%, #1a1d3a 100%);
    color: #e6f7ff;
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 13px;
    line-height: 1.6;
    padding: 20px;
    border-radius: 12px;
    white-space: pre-wrap;
    word-wrap: break-word;
    min-height: 200px;
    max-height: 400px;
    overflow-y: auto;
    border: 2px solid #4a9eff;
    box-shadow:
        0 0 20px rgba(74, 158, 255, 0.3),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
    position: relative;
    backdrop-filter: blur(10px);
    cursor: pointer;
}

.claude-live-output:focus {
    outline: 2px solid #00ff88;
    outline-offset: 2px;
    box-shadow:
        0 0 20px rgba(0, 255, 136, 0.5),
        inset 0 1px 0 rgba(255, 255, 255, 0.1);
}

.claude-live-output::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, #4a9eff, #00d9ff, #4a9eff);
    border-radius: 12px 12px 0 0;
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        background-position: -200px 0;
    }

    100% {
        background-position: 200px 0;
    }
}

.claude-live-output::-webkit-scrollbar {
    width: 8px;
}

.claude-live-output::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
}

.claude-live-output::-webkit-scrollbar-thumb {
    background: linear-gradient(180deg, #4a9eff, #00d9ff);
    border-radius: 4px;
}

.claude-live-output::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg, #6bb3ff, #33e2ff);
}

.terminal-section {
    margin: 20px 0;
    display: none; /* Hidden by default, shown only in development mode */
}

.terminal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px 15px;
    background: linear-gradient(135deg, #2a2a2a 0%, #3a3a3a 100%);
    border-radius: 8px;
    border: 1px solid #555555;
}

.terminal-title {
    margin: 0;
    color: #a8a8a8;
    font-size: 18px;
    font-weight: 600;
}

.terminal-ready-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    opacity: 0.7;
    font-style: italic;
    color: #9ca3af;
}

.pulse-dot-green {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse 2s infinite;
}

.terminal-output {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a2a2a 100%);
    color: #e0e0e0;
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', 'Monaco', monospace;
    font-size: 12px;
    line-height: 1.5;
    padding: 18px;
    border-radius: 8px;
    white-space: pre-wrap;
    word-wrap: break-word;
    min-height: 200px;
    max-height: 400px;
    overflow-y: auto;
    border: 1px solid #404040;
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.3);
}

.terminal-output::-webkit-scrollbar {
    width: 8px;
}

.terminal-output::-webkit-scrollbar-track {
    background: #2d2d2d;
}

.terminal-output::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 4px;
}

.terminal-output::-webkit-scrollbar-thumb:hover {
    background: #777;
}

/* Debug Section */
.debug-section {
    margin: 20px 0;
    border: 2px dashed var(--vscode-charts-orange);
    border-radius: 8px;
    background: rgba(255, 165, 0, 0.05);
}

.debug-header {
    padding: 15px 20px 10px;
    border-bottom: 1px solid rgba(255, 165, 0, 0.2);
}

.debug-header h3 {
    margin: 0 0 5px 0;
    color: var(--vscode-charts-orange);
    font-size: 16px;
}

.debug-controls {
    padding: 15px 20px;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.debug-controls .btn-small {
    padding: 8px 12px;
    font-size: 12px;
    border-radius: 6px;
}

/* Sexy Toggle Switch */
.toggle-switch {
    position: relative;
    display: inline-block;
    width: 48px;
    height: 24px;
    cursor: pointer;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--vscode-input-background);
    border: 1px solid var(--vscode-input-border);
    border-radius: 24px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1);
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 2px;
    top: 3px;
    background: var(--vscode-foreground);
    border-radius: 50%;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.toggle-switch input:checked + .toggle-slider {
    background: var(--vscode-button-background);
    border-color: var(--vscode-button-background);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1), 0 0 8px rgba(0, 122, 255, 0.3);
}

.toggle-switch input:checked + .toggle-slider:before {
    transform: translateX(24px);
    background: var(--vscode-button-foreground);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

.toggle-switch:hover .toggle-slider {
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1), 0 0 8px rgba(0, 0, 0, 0.1);
}

.toggle-switch input:checked:hover + .toggle-slider {
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.1), 0 0 12px rgba(0, 122, 255, 0.4);
}

.toggle-switch input:focus + .toggle-slider {
    outline: 2px solid var(--vscode-focusBorder);
    outline-offset: 2px;
}

/* Animation for smooth transitions */
.toggle-slider:before {
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                background 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* File autocomplete styles */
.file-autocomplete-container {
    font-family: var(--vscode-font-family);
    font-size: 12px;
    border-radius: 6px;
    overflow: hidden;
    backdrop-filter: blur(8px);
    border: 1px solid var(--vscode-widget-border);
}

.file-autocomplete-item {
    padding: 6px 10px;
    cursor: pointer;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.15s ease;
    position: relative;
}

.file-autocomplete-item:last-child {
    border-bottom: none;
}

.file-autocomplete-item:hover {
    background-color: var(--vscode-list-hoverBackground);
    transform: translateX(2px);
}

.file-autocomplete-item.selected {
    background: linear-gradient(90deg, var(--vscode-list-activeSelectionBackground) 0%, rgba(0, 122, 255, 0.2) 100%);
    color: var(--vscode-list-activeSelectionForeground);
    border-left: 3px solid var(--vscode-focusBorder);
    padding-left: 7px;
    transform: translateX(2px);
}

.file-name {
    font-weight: 500;
    color: var(--vscode-foreground);
    margin-bottom: 1px;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-autocomplete-item.selected .file-name {
    color: var(--vscode-list-activeSelectionForeground);
}

.file-path {
    font-size: 10px;
    color: var(--vscode-descriptionForeground);
    opacity: 0.7;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-autocomplete-item.selected .file-path {
    color: var(--vscode-list-activeSelectionForeground);
    opacity: 0.8;
}

.file-autocomplete-loading,
.file-autocomplete-empty {
    padding: 8px 10px;
    text-align: center;
    color: var(--vscode-descriptionForeground);
    font-style: italic;
    font-size: 11px;
}

.file-autocomplete-loading {
    color: var(--vscode-charts-blue);
    animation: pulse 1.5s ease-in-out infinite;
}

.file-autocomplete-empty {
    color: var(--vscode-charts-orange);
}

@keyframes pulse {
    0%, 100% { opacity: 0.6; }
    50% { opacity: 1; }
}

/* Infinite scroll styles */
.file-autocomplete-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 6px 10px;
    background: var(--vscode-editor-background);
    border-bottom: 1px solid var(--vscode-panel-border);
    font-size: 10px;
    position: sticky;
    top: 0;
    z-index: 1;
}

.file-count {
    color: var(--vscode-foreground);
    font-weight: 500;
}

.loading-more {
    color: var(--vscode-descriptionForeground);
    font-style: italic;
    opacity: 0.8;
}

.file-autocomplete-loading-more {
    padding: 8px 10px;
    text-align: center;
    color: var(--vscode-charts-blue);
    font-style: italic;
    font-size: 11px;
    animation: pulse 1.5s ease-in-out infinite;
    background: var(--vscode-editor-background);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

/* Web Interface Section */
.web-interface-section {
    margin-bottom: 20px;
    border: 1px solid var(--vscode-panel-border);
    border-radius: 8px;
    padding: 16px;
    background: var(--vscode-panel-background);
}

.web-interface-section .section-header {
    margin-bottom: 16px;
    border-bottom: 1px solid var(--vscode-panel-border);
    padding-bottom: 8px;
}

.web-interface-section .section-header h3 {
    margin: 0;
    color: var(--vscode-foreground);
    font-size: 16px;
    font-weight: 600;
}

.web-interface-status {
    margin-bottom: 16px;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 12px;
}

.status-indicator span {
    font-size: 14px;
    font-weight: 500;
}

.pulse-dot-grey {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6b7280;
    animation: pulse 2s infinite;
}

.pulse-dot-success {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #10b981;
    animation: pulse 2s infinite;
}

.web-server-details {
    background: var(--vscode-editor-background);
    border: 1px solid var(--vscode-panel-border); 
    border-radius: 6px;
    padding: 12px;
    margin-top: 8px;
}

.server-info {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
}

.info-label {
    color: var(--vscode-descriptionForeground);
    font-weight: 500;
}

.info-value {
    color: var(--vscode-foreground);
    font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', 'Monaco', monospace;
    background: var(--vscode-textBlockQuote-background);
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 12px;
}

.web-interface-controls {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.web-interface-controls .btn-small {
    padding: 8px 12px;
    font-size: 13px;
}

/* Disclaimer Footer */
.disclaimer-footer {
    margin-top: 30px;
    padding: 15px;
    background-color: var(--vscode-inputValidation-warningBackground);
    border: 1px solid var(--vscode-inputValidation-warningBorder);
    border-radius: 8px;
    margin-bottom: 20px;
}

.disclaimer-content {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

.disclaimer-icon {
    font-size: 16px;
    flex-shrink: 0;
    margin-top: 2px;
}

.disclaimer-text {
    font-size: 13px;
    line-height: 1.4;
    color: var(--vscode-editor-foreground);
}

.disclaimer-text strong {
    font-weight: 600;
    color: var(--vscode-inputValidation-warningForeground);
}

