/* Refresh Cards Tab Styles */
.refresh-cards-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
    color: #333;
    line-height: 1.6;
}

.refresh-cards-content h2 {
    color: #2c5aa0;
    text-align: center;
    margin-bottom: 30px;
    font-size: 2rem;
}

.refresh-section {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 25px;
}

.refresh-section h3 {
    color: #2c5aa0;
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.4rem;
}

.refresh-section p {
    margin-bottom: 15px;
    color: #666;
}

/* Button Styles */
.action-button {
    background: #2c5aa0;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    margin: 5px;
    transition: background-color 0.2s;
}

.action-button:hover {
    background: #1e3f73;
}

.action-button:disabled {
    background: #6c757d;
    cursor: not-allowed;
}

.commit-button {
    background: #28a745;
}

.commit-button:hover {
    background: #1e7e34;
}

.reset-button {
    background: #dc3545;
}

.reset-button:hover {
    background: #c82333;
}

/* Controls Layout */
.script-controls, .git-controls, .commit-controls {
    margin-bottom: 20px;
}

.cursor-input {
    margin-top: 10px;
    display: flex;
    align-items: center;
}

.commit-message-input {
    display: flex;
    align-items: center;
    margin-bottom: 10px;
}

/* Output Display Styles */
.output-display {
    background: #1a1a1a;
    color: #e0e0e0;
    padding: 15px;
    border-radius: 6px;
    font-family: 'Monaco', 'Menlo', 'Ubuntu Mono', monospace;
    font-size: 13px;
    line-height: 1.4;
    max-height: 400px;
    overflow-y: auto;
    white-space: pre-wrap;
    word-wrap: break-word;
    border: 1px solid #333;
    margin-top: 5px;
}

.output-display:empty {
    display: none;
}

.output-display:not(:empty) {
    display: block;
}

/* Authentication Section */
.auth-section {
    border-left: 4px solid #ffc107;
}

/* Authenticated state styling */
#authenticated-header {
    border-left: 4px solid #28a745;
    background: #f8fff8;
}

.auth-controls {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

/* Auth Status */
.auth-status {
    margin-left: 10px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.9rem;
    font-weight: 500;
}

.auth-status.testing {
    background: #e3f2fd;
    color: #1976d2;
}

.auth-status.success {
    background: #e8f5e8;
    color: #2e7d32;
}

.auth-status.error {
    background: #ffebee;
    color: #c62828;
}

/* Script Status */
.script-status {
    margin-top: 10px;
    padding: 8px 12px;
    border-radius: 4px;
    font-weight: 500;
    text-align: center;
    display: none;
}

.script-status.running {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
    display: block;
}

.script-status.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
    display: block;
}

.script-status.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
    display: block;
}

/* Output Log Lines */
.output-line {
    margin: 2px 0;
}

.output-line.stdout {
    color: #e0e0e0;
}

.output-line.stderr {
    color: #ff6b6b;
}

.output-line.error {
    color: #ff4757;
    font-weight: 500;
}

.output-line.success {
    color: #2ed573;
    font-weight: 500;
}

.output-line.info {
    color: #5352ed;
    font-weight: 500;
}

/* Bulk Refresh Controls */
.bulk-refresh-controls {
    margin-bottom: 20px;
}

.collection-selector {
    margin-bottom: 15px;
}

.collection-selector label {
    font-weight: 500;
    color: #333;
}

.queue-controls {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Queue Status */
.queue-status-container {
    margin-top: 20px;
}

.queue-stats {
    display: flex;
    gap: 20px;
    margin-bottom: 15px;
    padding: 15px;
    background: white;
    border-radius: 6px;
    border: 1px solid #dee2e6;
}

.queue-stats span {
    color: #666;
}

.queue-stats strong {
    color: #2c5aa0;
    margin-left: 5px;
}

/* Queue Items List */
.queue-items-list {
    max-height: 400px;
    overflow-y: auto;
    background: white;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 10px;
}

.queue-items-list:empty::before {
    content: 'No items in queue';
    color: #999;
    font-style: italic;
    display: block;
    text-align: center;
    padding: 20px;
}

.queue-item {
    padding: 8px 12px;
    margin-bottom: 6px;
    background: #f8f9fa;
    border-radius: 4px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
}

.queue-item-name {
    flex: 1;
    color: #333;
    font-weight: 500;
}

.queue-item-status {
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    text-transform: uppercase;
}

.queue-item-status.pending {
    background: #e3f2fd;
    color: #1976d2;
}

.queue-item-status.processing {
    background: #fff3cd;
    color: #856404;
    animation: pulse 1.5s ease-in-out infinite;
}

.queue-item-status.success {
    background: #d4edda;
    color: #155724;
}

.queue-item-status.failed {
    background: #f8d7da;
    color: #721c24;
}

.queue-item-error {
    margin-top: 4px;
    font-size: 0.8rem;
    color: #dc3545;
    font-style: italic;
}

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

/* Responsive Design */
@media (max-width: 768px) {
    .refresh-cards-content {
        padding: 15px;
    }
    
    .cursor-input, .commit-message-input {
        flex-direction: column;
        align-items: stretch;
    }
    
    .cursor-input input, .commit-message-input input {
        margin-right: 0;
        margin-bottom: 10px;
        width: 100%;
    }

    .queue-stats {
        flex-direction: column;
        gap: 10px;
    }

    .queue-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
}