/**
 * ============================================
 * FLOWBOT DCI v3.0 - COMPLETE STYLESHEET
 * ============================================
 * Professional dark theme design system
 * Version: 3.1.0 (Complete Rewrite)
 */

/* ==========================================
   CSS VARIABLES / DESIGN TOKENS
   ========================================== */
:root {
    /* Colors - Primary */
    --color-primary: #3B82F6;
    --color-primary-hover: #2563EB;
    --color-primary-light: #60A5FA;
    --color-primary-dark: #1D4ED8;

    /* Colors - Status */
    --color-success: #10B981;
    --color-success-light: #34D399;
    --color-warning: #F59E0B;
    --color-warning-light: #FBBF24;
    --color-error: #EF4444;
    --color-error-light: #F87171;
    --color-info: #6366F1;

    /* Colors - Background */
    --bg-primary: #0F172A;
    --bg-secondary: #1E293B;
    --bg-tertiary: #334155;
    --bg-card: rgba(30, 41, 59, 0.95);
    --bg-hover: rgba(255, 255, 255, 0.05);

    /* Colors - Text */
    --text-primary: #F8FAFC;
    --text-secondary: #94A3B8;
    --text-muted: #64748B;

    /* Colors - Border */
    --border-color: rgba(255, 255, 255, 0.1);
    --border-light: rgba(255, 255, 255, 0.05);

    /* Spacing */
    --spacing-xs: 4px;
    --spacing-sm: 8px;
    --spacing-md: 16px;
    --spacing-lg: 24px;
    --spacing-xl: 32px;
    --spacing-2xl: 48px;

    /* Border Radius */
    --radius-sm: 6px;
    --radius-md: 10px;
    --radius-lg: 16px;
    --radius-full: 9999px;

    /* Shadows */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.3);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.4);

    /* Transitions */
    --transition-fast: 150ms ease;
    --transition-normal: 250ms ease;
    --transition-slow: 350ms ease;

    /* Typography */
    --font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-mono: 'SF Mono', Monaco, 'Cascadia Code', Consolas, monospace;
}

/* ==========================================
   RESET & BASE STYLES
   ========================================== */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    font-size: 16px;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body {
    font-family: var(--font-family);
    background: var(--bg-primary);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
}

a {
    color: var(--color-primary-light);
    text-decoration: none;
    transition: color var(--transition-fast);
}

a:hover {
    color: var(--color-primary);
}

/* ==========================================
   MAIN NAVIGATION
   ========================================== */
.main-nav {
    background: var(--bg-secondary);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
    gap: var(--spacing-lg);
}

/* Brand */
.nav-brand {
    flex-shrink: 0;
}

.brand-link {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    color: var(--text-primary);
    text-decoration: none;
}

.brand-link:hover {
    color: var(--text-primary);
}

.brand-logo {
    width: 32px;
    height: 32px;
}

.brand-logo svg {
    width: 100%;
    height: 100%;
}

.brand-text {
    font-size: 1.125rem;
    font-weight: 700;
    letter-spacing: -0.025em;
}

.brand-version {
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    background: var(--bg-tertiary);
    padding: 2px 8px;
    border-radius: var(--radius-full);
}

/* Nav Links */
.nav-main {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    flex: 1;
    justify-content: center;
}

.nav-link {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    color: var(--text-secondary);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    font-weight: 500;
    transition: all var(--transition-fast);
    text-decoration: none;
}

.nav-link:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.nav-link.active {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

.nav-icon {
    width: 18px;
    height: 18px;
    flex-shrink: 0;
}

/* Nav Right */
.nav-right {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

/* ==========================================
   BUTTONS
   ========================================== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: var(--radius-md);
    border: none;
    cursor: pointer;
    transition: all var(--transition-fast);
    white-space: nowrap;
    text-decoration: none;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8125rem;
}

.btn-lg {
    padding: 12px 24px;
    font-size: 1rem;
}

.btn-primary {
    background: var(--color-primary);
    color: white;
}

.btn-primary:hover {
    background: var(--color-primary-hover);
    color: white;
    transform: translateY(-1px);
}

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

.btn-secondary:hover {
    background: var(--bg-hover);
    border-color: var(--border-light);
}

.btn-success {
    background: var(--color-success);
    color: white;
}

.btn-danger {
    background: var(--color-error);
    color: white;
}

.btn-ghost {
    background: transparent;
    color: var(--text-secondary);
}

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

/* ==========================================
   MAIN CONTENT
   ========================================== */
.main-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: var(--spacing-xl) var(--spacing-lg);
    min-height: calc(100vh - 64px);
}

/* ==========================================
   CARDS
   ========================================== */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    backdrop-filter: blur(10px);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--spacing-md);
    padding-bottom: var(--spacing-md);
    border-bottom: 1px solid var(--border-light);
}

.card-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.card-body {
    color: var(--text-secondary);
}

/* ==========================================
   STATS CARDS
   ========================================== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: var(--spacing-lg);
    margin-bottom: var(--spacing-xl);
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: var(--spacing-lg);
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
    transition: all var(--transition-fast);
}

.stat-card:hover {
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.stat-card-active .stat-icon {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

.stat-card-success .stat-icon {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success-light);
}

.stat-card-error .stat-icon {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-error-light);
}

.stat-card-total .stat-icon {
    background: rgba(99, 102, 241, 0.15);
    color: var(--color-info);
}

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

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    display: block;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    display: block;
    margin-top: var(--spacing-xs);
}

.stat-trend {
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 4px;
    margin-top: var(--spacing-sm);
}

.stat-trend.positive {
    color: var(--color-success);
}

.stat-trend.negative {
    color: var(--color-error);
}

/* ==========================================
   PAGE HEADER
   ========================================== */
.page-header {
    margin-bottom: var(--spacing-xl);
}

.page-title {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: var(--spacing-xs);
}

.page-subtitle {
    font-size: 0.9375rem;
    color: var(--text-muted);
}

/* ==========================================
   DASHBOARD GRID
   ========================================== */
.dashboard-grid {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: var(--spacing-lg);
}

.dashboard-main {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.dashboard-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

/* ==========================================
   SECTION
   ========================================== */
.section {
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-md) var(--spacing-lg);
    border-bottom: 1px solid var(--border-light);
}

.section-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.section-title svg {
    width: 18px;
    height: 18px;
    color: var(--text-muted);
}

.section-body {
    padding: var(--spacing-lg);
}

/* ==========================================
   EMPTY STATE
   ========================================== */
.empty-state {
    text-align: center;
    padding: var(--spacing-2xl) var(--spacing-lg);
    color: var(--text-muted);
}

.empty-state-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto var(--spacing-md);
    opacity: 0.5;
}

.empty-state-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-xs);
}

.empty-state-text {
    font-size: 0.875rem;
    margin-bottom: var(--spacing-md);
}

/* ==========================================
   ACTIVITY FEED
   ========================================== */
.activity-list {
    list-style: none;
}

.activity-item {
    display: flex;
    align-items: flex-start;
    gap: var(--spacing-md);
    padding: var(--spacing-md) 0;
    border-bottom: 1px solid var(--border-light);
}

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

.activity-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 0.875rem;
}

.activity-icon.success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success);
}

.activity-icon.error {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-error);
}

.activity-icon.info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

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

.activity-text {
    font-size: 0.875rem;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.activity-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ==========================================
   PERFORMANCE STATS
   ========================================== */
.perf-stats {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.perf-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.perf-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.perf-value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.perf-bar {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
    margin-top: var(--spacing-sm);
}

.perf-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-primary), var(--color-success));
    border-radius: var(--radius-full);
    transition: width var(--transition-slow);
}

/* ==========================================
   TABLES
   ========================================== */
.table-container {
    overflow-x: auto;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th, td {
    padding: var(--spacing-md);
    text-align: left;
    border-bottom: 1px solid var(--border-light);
}

th {
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    background: var(--bg-tertiary);
}

td {
    font-size: 0.875rem;
    color: var(--text-primary);
}

tr:hover td {
    background: var(--bg-hover);
}

/* ==========================================
   BADGES
   ========================================== */
.badge {
    display: inline-flex;
    align-items: center;
    padding: 4px 10px;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: var(--radius-full);
}

.badge-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success-light);
}

.badge-error {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-error-light);
}

.badge-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--color-warning-light);
}

.badge-info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

/* ==========================================
   FORMS
   ========================================== */
.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-label {
    display: block;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: var(--spacing-sm);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: var(--spacing-md);
    font-size: 0.9375rem;
    font-family: inherit;
    color: var(--text-primary);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    transition: all var(--transition-fast);
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.2);
}

.form-textarea {
    min-height: 200px;
    resize: vertical;
    font-family: var(--font-mono);
    line-height: 1.5;
}

.form-hint {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: var(--spacing-xs);
}

/* ==========================================
   MODALS - HIDDEN BY DEFAULT
   ========================================== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    backdrop-filter: blur(4px);
}

.modal-overlay.active {
    display: flex;
}

.modal {
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

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

.modal-title {
    font-size: 1.125rem;
    font-weight: 600;
}

.modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    border-radius: var(--radius-sm);
}

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

.modal-body {
    padding: var(--spacing-lg);
}

.modal-footer {
    display: flex;
    gap: var(--spacing-sm);
    justify-content: flex-end;
    padding: var(--spacing-lg);
    border-top: 1px solid var(--border-light);
}

/* ==========================================
   PROGRESS BAR
   ========================================== */
.progress {
    height: 8px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--color-primary), var(--color-primary-light));
    border-radius: var(--radius-full);
    transition: width var(--transition-normal);
}

.progress-large {
    height: 12px;
}

/* ==========================================
   TOAST NOTIFICATIONS
   ========================================== */
.toast-container {
    position: fixed;
    bottom: var(--spacing-lg);
    right: var(--spacing-lg);
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.toast {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.toast-success {
    border-left: 4px solid var(--color-success);
}

.toast-error {
    border-left: 4px solid var(--color-error);
}

.toast-warning {
    border-left: 4px solid var(--color-warning);
}

/* ==========================================
   RESPONSIVE
   ========================================== */
@media (max-width: 1024px) {
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .dashboard-sidebar {
        order: -1;
    }
}

@media (max-width: 768px) {
    .nav-main {
        display: none;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }

    .main-content {
        padding: var(--spacing-md);
    }
}

@media (max-width: 480px) {
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .nav-container {
        padding: 0 var(--spacing-md);
    }
}

/* ==========================================
   UTILITIES
   ========================================== */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-muted { color: var(--text-muted); }
.text-success { color: var(--color-success); }
.text-error { color: var(--color-error); }
.text-warning { color: var(--color-warning); }

.mt-sm { margin-top: var(--spacing-sm); }
.mt-md { margin-top: var(--spacing-md); }
.mt-lg { margin-top: var(--spacing-lg); }
.mb-sm { margin-bottom: var(--spacing-sm); }
.mb-md { margin-bottom: var(--spacing-md); }
.mb-lg { margin-bottom: var(--spacing-lg); }

.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.gap-sm { gap: var(--spacing-sm); }
.gap-md { gap: var(--spacing-md); }

.hidden { display: none !important; }

/* ==========================================
   STEP INDICATOR (Workflow Steps)
   ========================================== */
.step-indicator {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: var(--spacing-xl);
    padding: var(--spacing-lg) 0;
}

.step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-sm);
}

.step-circle {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-full);
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: all var(--transition-fast);
}

.step-circle svg {
    width: 16px;
    height: 16px;
}

.step.active .step-circle {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
}

.step.completed .step-circle {
    background: var(--color-success);
    border-color: var(--color-success);
    color: white;
}

.step-label {
    font-size: 0.8125rem;
    color: var(--text-muted);
    font-weight: 500;
}

.step.active .step-label {
    color: var(--color-primary-light);
}

.step.completed .step-label {
    color: var(--color-success);
}

.step-line {
    width: 60px;
    height: 2px;
    background: var(--bg-tertiary);
    margin: 0 var(--spacing-sm);
    margin-bottom: 24px;
}

.step-line.completed {
    background: var(--color-success);
}

/* ==========================================
   FORM GRID LAYOUT
   ========================================== */
.form-grid {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: var(--spacing-lg);
}

.form-main {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.form-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

@media (max-width: 1024px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   DOMAIN LIST
   ========================================== */
.domain-list {
    max-height: 400px;
    overflow-y: auto;
}

.domain-item {
    display: flex;
    align-items: center;
    padding: var(--spacing-sm) 0;
    border-bottom: 1px solid var(--border-light);
    gap: var(--spacing-sm);
}

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

.domain-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    flex-shrink: 0;
}

.domain-icon.social {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

.domain-info {
    flex: 1;
    min-width: 0;
}

.domain-name {
    font-size: 0.875rem;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.domain-meta {
    display: flex;
    gap: var(--spacing-sm);
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.domain-count {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    min-width: 40px;
    text-align: right;
}

.domain-bar {
    width: 80px;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: 3px;
    overflow: hidden;
}

.domain-bar-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: 3px;
    transition: width var(--transition-normal);
}

/* ==========================================
   MODE OPTIONS (Radio Cards)
   ========================================== */
.mode-options {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.mode-option {
    position: relative;
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.mode-option:hover {
    border-color: rgba(59, 130, 246, 0.3);
    background: var(--bg-tertiary);
}

.mode-option.selected {
    border-color: var(--color-primary);
    background: rgba(59, 130, 246, 0.1);
}

.mode-option input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.mode-option-header {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.mode-option-radio {
    width: 18px;
    height: 18px;
    border: 2px solid var(--text-muted);
    border-radius: var(--radius-full);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    flex-shrink: 0;
}

.mode-option.selected .mode-option-radio {
    border-color: var(--color-primary);
}

.mode-option.selected .mode-option-radio::after {
    content: '';
    width: 10px;
    height: 10px;
    background: var(--color-primary);
    border-radius: var(--radius-full);
}

.mode-option-title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9375rem;
}

.mode-option-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-top: var(--spacing-xs);
    margin-left: 26px;
}

.mode-option-stats {
    display: flex;
    gap: var(--spacing-md);
    margin-top: var(--spacing-sm);
    margin-left: 26px;
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* ==========================================
   CHECKBOX GROUP
   ========================================== */
.checkbox-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: background var(--transition-fast);
}

.checkbox-item:hover {
    background: var(--bg-tertiary);
}

.checkbox-item input[type="checkbox"] {
    width: 18px;
    height: 18px;
    accent-color: var(--color-primary);
    flex-shrink: 0;
}

.checkbox-item span {
    font-size: 0.875rem;
    color: var(--text-primary);
}

/* ==========================================
   SUCCESS INDICATOR (Circular Progress)
   ========================================== */
.success-indicator {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.success-circle {
    width: 64px;
    height: 64px;
    border-radius: var(--radius-full);
    background: conic-gradient(
        var(--color-success) calc(var(--percent) * 1%),
        var(--bg-tertiary) 0
    );
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    flex-shrink: 0;
}

.success-circle::before {
    content: '';
    width: 52px;
    height: 52px;
    background: var(--bg-secondary);
    border-radius: var(--radius-full);
    position: absolute;
}

.success-value {
    position: relative;
    font-weight: 700;
    font-size: 0.9375rem;
    color: var(--text-primary);
}

.success-info {
    flex: 1;
}

.success-label {
    font-size: 0.9375rem;
    color: var(--text-primary);
    font-weight: 600;
}

.success-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ==========================================
   WARNINGS SECTION
   ========================================== */
.subsection-title {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-sm);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.subsection-title svg {
    color: var(--color-warning);
}

.warnings-list {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.warning-item {
    display: flex;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: rgba(245, 158, 11, 0.1);
    border: 1px solid rgba(245, 158, 11, 0.3);
    border-radius: var(--radius-sm);
}

.warning-item.error {
    background: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.3);
}

.warning-icon {
    flex-shrink: 0;
    color: var(--color-warning);
}

.warning-item.error .warning-icon {
    color: var(--color-error);
}

.warning-content {
    flex: 1;
}

.warning-title {
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-primary);
}

.warning-desc {
    font-size: 0.8125rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ==========================================
   INVALID URLS SECTION
   ========================================== */
.invalid-urls-section {
    margin-top: var(--spacing-md);
}

.invalid-toggle {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    cursor: pointer;
    width: 100%;
    text-align: left;
    color: var(--text-secondary);
    font-size: 0.875rem;
    transition: all var(--transition-fast);
}

.invalid-toggle:hover {
    background: var(--bg-tertiary);
}

.invalid-toggle svg {
    transition: transform var(--transition-fast);
}

.invalid-toggle.open svg {
    transform: rotate(90deg);
}

.invalid-list {
    display: none;
    margin-top: var(--spacing-sm);
    max-height: 200px;
    overflow-y: auto;
    padding: var(--spacing-sm);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

.invalid-list.open {
    display: block;
}

.invalid-url-item {
    display: flex;
    gap: var(--spacing-sm);
    padding: var(--spacing-xs) 0;
    font-size: 0.8125rem;
    border-bottom: 1px solid var(--border-light);
}

.invalid-url-item:last-child {
    border-bottom: none;
}

.invalid-url {
    flex: 1;
    color: var(--text-muted);
    word-break: break-all;
}

.invalid-reason {
    color: var(--color-error);
    white-space: nowrap;
}

/* ==========================================
   ACTION BUTTONS
   ========================================== */
.action-buttons {
    display: flex;
    gap: var(--spacing-md);
    margin-top: var(--spacing-lg);
}

.action-buttons .btn {
    flex: 1;
}

/* ==========================================
   TAGS
   ========================================== */
.tag {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    font-size: 0.6875rem;
    font-weight: 500;
    border-radius: 4px;
    text-transform: uppercase;
}

.tag-info {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary-light);
}

.tag-success {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success-light);
}

.tag-warning {
    background: rgba(245, 158, 11, 0.15);
    color: var(--color-warning-light);
}

/* ==========================================
   LOADING SPINNER
   ========================================== */
.loading-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: var(--radius-full);
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* ==========================================
   URL INPUT (Form Page)
   ========================================== */
.url-input-area {
    position: relative;
}

.url-input {
    width: 100%;
    min-height: 300px;
    padding: var(--spacing-lg);
    font-size: 0.875rem;
    font-family: var(--font-mono);
    color: var(--text-primary);
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    resize: vertical;
    transition: border-color var(--transition-fast);
    line-height: 1.6;
}

.url-input:focus {
    outline: none;
    border-color: var(--color-primary);
}

.url-input::placeholder {
    color: var(--text-muted);
}

.input-counter {
    position: absolute;
    bottom: var(--spacing-md);
    right: var(--spacing-md);
    font-size: 0.75rem;
    color: var(--text-muted);
    background: var(--bg-secondary);
    padding: 4px 8px;
    border-radius: var(--radius-sm);
}

/* ==========================================
   VALIDATION PREVIEW
   ========================================== */
.validation-preview {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    margin-top: var(--spacing-md);
}

.validation-item {
    text-align: center;
}

.validation-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.validation-value.success {
    color: var(--color-success);
}

.validation-value.error {
    color: var(--color-error);
}

.validation-value.warning {
    color: var(--color-warning);
}

.validation-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    margin-top: 2px;
}

/* ==========================================
   FILE IMPORT
   ========================================== */
.file-import {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.file-import:hover {
    border-color: var(--color-primary);
    background: rgba(59, 130, 246, 0.05);
}

.file-import input {
    display: none;
}

.file-import-icon {
    width: 40px;
    height: 40px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.file-import-text {
    flex: 1;
}

.file-import-title {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.9375rem;
}

.file-import-desc {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* ==========================================
   STATS GRID VARIANTS
   ========================================== */
.stats-grid.cols-4 {
    grid-template-columns: repeat(4, 1fr);
}

.stats-grid.cols-3 {
    grid-template-columns: repeat(3, 1fr);
}

@media (max-width: 900px) {
    .stats-grid.cols-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .stats-grid.cols-4,
    .stats-grid.cols-3 {
        grid-template-columns: 1fr;
    }
}

/* Page Header with Actions */
.page-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: var(--spacing-xl);
    gap: var(--spacing-md);
}

@media (max-width: 600px) {
    .page-header {
        flex-direction: column;
    }
}

/* Warning colored stat card */
.stat-card-warning .stat-icon {
    background: rgba(245, 158, 11, 0.15);
    color: var(--color-warning-light);
}

/* ==========================================
   PROGRESS PAGE LAYOUT
   ========================================== */
.progress-layout {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: var(--spacing-lg);
}

.progress-main {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

.progress-sidebar {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-lg);
}

@media (max-width: 1100px) {
    .progress-layout {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   PROGRESS HERO (Big Circle)
   ========================================== */
.progress-hero {
    display: flex;
    align-items: center;
    gap: var(--spacing-xl);
    padding: var(--spacing-xl);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
}

.progress-circle-large {
    width: 160px;
    height: 160px;
    position: relative;
    flex-shrink: 0;
}

.progress-circle-large svg {
    width: 100%;
    height: 100%;
    transform: rotate(-90deg);
}

.progress-circle-bg {
    fill: none;
    stroke: var(--bg-tertiary);
    stroke-width: 12;
}

.progress-circle-fill {
    fill: none;
    stroke: var(--color-primary);
    stroke-width: 12;
    stroke-linecap: round;
    transition: stroke-dashoffset 0.5s ease;
}

.progress-circle-fill.paused {
    stroke: var(--color-warning);
}

.progress-circle-fill.complete {
    stroke: var(--color-success);
}

.progress-circle-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    text-align: center;
}

.progress-circle-value {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1;
}

.progress-circle-label {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-top: 4px;
}

.progress-hero-stats {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.hero-stat {
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
}

.hero-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.hero-stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.hero-stat.success .hero-stat-value { color: var(--color-success); }
.hero-stat.error .hero-stat-value { color: var(--color-error); }
.hero-stat.warning .hero-stat-value { color: var(--color-warning); }

/* ==========================================
   STATUS INDICATOR
   ========================================== */
.status-indicator {
    display: inline-flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
}

.status-indicator.running {
    background: rgba(59, 130, 246, 0.2);
    color: var(--color-primary);
}

.status-indicator.paused {
    background: rgba(251, 191, 36, 0.2);
    color: var(--color-warning);
}

.status-indicator.completed {
    background: rgba(16, 185, 129, 0.2);
    color: var(--color-success);
}

.status-indicator.failed {
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error);
}

.status-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: currentColor;
    animation: pulse 1.5s ease-in-out infinite;
}

.status-indicator.paused .status-dot,
.status-indicator.completed .status-dot,
.status-indicator.failed .status-dot {
    animation: none;
}

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

/* ==========================================
   PHASE PIPELINE
   ========================================== */
.phase-pipeline {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--spacing-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

.phase-node {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--spacing-xs);
}

.phase-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--bg-tertiary);
    border: 2px solid var(--border-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: var(--text-muted);
    transition: all var(--transition-normal);
}

.phase-node.active .phase-circle {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
    box-shadow: 0 0 20px rgba(59, 130, 246, 0.4);
}

.phase-node.completed .phase-circle {
    background: var(--color-success);
    border-color: var(--color-success);
    color: white;
}

.phase-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.phase-node.active .phase-label,
.phase-node.completed .phase-label {
    color: var(--text-secondary);
}

.phase-stats-mini {
    font-size: 0.7rem;
    color: var(--text-muted);
}

.phase-connector {
    flex: 1;
    height: 2px;
    background: var(--border-color);
    margin: 0 var(--spacing-sm);
}

.phase-connector.completed {
    background: var(--color-success);
}

/* ==========================================
   CURRENT URL DISPLAY
   ========================================== */
.current-url-display {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.85rem;
    color: var(--text-secondary);
    overflow: hidden;
}

.current-url-display .spinner-icon {
    animation: spin 1s linear infinite;
    flex-shrink: 0;
}

.current-url-display .url {
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ==========================================
   CONTROL BUTTONS
   ========================================== */
.control-buttons {
    display: flex;
    gap: var(--spacing-sm);
}

.btn-control {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-md);
    border-radius: var(--radius-md);
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-pause {
    background: rgba(251, 191, 36, 0.2);
    border: 1px solid var(--color-warning);
    color: var(--color-warning);
}

.btn-pause:hover {
    background: rgba(251, 191, 36, 0.3);
}

.btn-resume {
    background: rgba(16, 185, 129, 0.2);
    border: 1px solid var(--color-success);
    color: var(--color-success);
}

.btn-resume:hover {
    background: rgba(16, 185, 129, 0.3);
}

.btn-cancel {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid var(--color-error);
    color: var(--color-error);
}

.btn-cancel:hover {
    background: rgba(239, 68, 68, 0.3);
}

/* ==========================================
   COMPLETION BANNER
   ========================================== */
.completion-banner {
    display: flex;
    align-items: center;
    gap: var(--spacing-lg);
    padding: var(--spacing-xl);
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid var(--color-success);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-lg);
}

.completion-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: var(--color-success);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.completion-info {
    flex: 1;
}

.completion-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.completion-subtitle {
    color: var(--text-secondary);
    margin-top: 4px;
}

.completion-actions {
    display: flex;
    gap: var(--spacing-sm);
}

/* ==========================================
   TIME STATS GRID
   ========================================== */
.time-stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: var(--spacing-md);
}

.time-stat {
    text-align: center;
}

.time-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.time-stat-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--text-primary);
}

/* ==========================================
   SPEED CHART
   ========================================== */
.speed-chart-container {
    height: 80px;
    margin-bottom: var(--spacing-sm);
}

.speed-stats-mini {
    display: flex;
    justify-content: space-around;
    gap: var(--spacing-sm);
}

.speed-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.speed-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.speed-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--color-primary);
}

/* ==========================================
   HTTP CODES GRID
   ========================================== */
.http-codes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: var(--spacing-xs);
}

.http-code-item {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    padding: var(--spacing-xs) var(--spacing-sm);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    font-size: 0.8rem;
}

.http-code-badge {
    font-weight: 700;
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 4px;
}

.http-code-badge.success { background: rgba(16, 185, 129, 0.2); color: var(--color-success); }
.http-code-badge.redirect { background: rgba(96, 165, 250, 0.2); color: var(--color-info); }
.http-code-badge.client-error { background: rgba(251, 191, 36, 0.2); color: var(--color-warning); }
.http-code-badge.server-error { background: rgba(239, 68, 68, 0.2); color: var(--color-error); }

.http-code-count {
    color: var(--text-muted);
}

.http-codes-empty {
    grid-column: span 3;
    text-align: center;
    color: var(--text-muted);
    font-size: 0.85rem;
    padding: var(--spacing-sm);
}

/* ==========================================
   LIVE LOG
   ========================================== */
.live-log {
    max-height: 300px;
    overflow-y: auto;
    font-family: var(--font-mono);
    font-size: 0.8rem;
}

.log-entry {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-xs) 0;
    border-bottom: 1px solid var(--border-light);
}

.log-entry:last-child {
    border-bottom: none;
}

.log-icon {
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.log-entry.log-success .log-icon { color: var(--color-success); }
.log-entry.log-error .log-icon { color: var(--color-error); }
.log-entry.log-warning .log-icon { color: var(--color-warning); }
.log-entry.log-info .log-icon { color: var(--color-info); }

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

.log-message {
    color: var(--text-muted);
    white-space: nowrap;
}

/* ==========================================
   HISTORY PAGE STYLES
   ========================================== */
.history-filters {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-lg);
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.filter-label {
    font-size: 0.875rem;
    color: var(--text-secondary);
}

.filter-select {
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.875rem;
}

.history-table {
    width: 100%;
}

.history-table th {
    text-align: left;
    padding: var(--spacing-md);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    background: var(--bg-tertiary);
    border-bottom: 1px solid var(--border-color);
}

.history-table td {
    padding: var(--spacing-md);
    border-bottom: 1px solid var(--border-light);
}

.history-table tr:hover td {
    background: var(--bg-hover);
}

/* Sortable Columns */
.history-table th.sortable {
    cursor: pointer;
    user-select: none;
    transition: all var(--transition-fast);
}

.history-table th.sortable:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.history-table th .th-content {
    display: flex;
    align-items: center;
    gap: 6px;
}

.history-table th .sort-icon {
    opacity: 0.3;
    transition: all var(--transition-fast);
    flex-shrink: 0;
}

.history-table th.sortable:hover .sort-icon {
    opacity: 0.6;
}

.history-table th.sorted-asc .sort-icon,
.history-table th.sorted-desc .sort-icon {
    opacity: 1;
    color: var(--color-primary);
}

.history-table th.sorted-asc .sort-icon path:last-child {
    opacity: 0.3;
}

.history-table th.sorted-desc .sort-icon path:first-child {
    opacity: 0.3;
}

/* Search Input */
.filter-group-search {
    flex: 1;
    max-width: 280px;
}

.search-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.search-input-wrapper .search-icon {
    position: absolute;
    left: 12px;
    color: var(--text-muted);
    pointer-events: none;
}

.search-input-wrapper .search-input {
    padding-left: 36px;
    width: 100%;
}

/* General Sortable Table Styles */
table th.sortable {
    cursor: pointer;
    user-select: none;
    transition: all var(--transition-fast);
    position: relative;
}

table th.sortable:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

table th.sortable::after {
    content: '↕';
    margin-left: 6px;
    opacity: 0.3;
    font-size: 0.75em;
}

table th.sortable.sort-asc::after {
    content: '↑';
    opacity: 1;
    color: var(--color-primary);
}

table th.sortable.sort-desc::after {
    content: '↓';
    opacity: 1;
    color: var(--color-primary);
}

.history-actions {
    display: flex;
    gap: var(--spacing-xs);
}

.history-action-btn {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

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

.history-action-btn.danger:hover {
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error);
    border-color: var(--color-error);
}

/* Pagination */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--spacing-sm);
    margin-top: var(--spacing-lg);
}

.pagination-btn {
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.pagination-btn:hover:not(:disabled) {
    background: var(--bg-tertiary);
    color: var(--text-primary);
}

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

.pagination-info {
    font-size: 0.875rem;
    color: var(--text-muted);
}

/* ============================================
   HISTORY PAGE SPECIFIC STYLES
   ============================================ */

/* Page Header with actions */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: var(--spacing-xl);
}

.page-header-content {
    flex: 1;
}

.page-title {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-xs) 0;
}

.page-title-icon {
    width: 28px;
    height: 28px;
    color: var(--color-primary);
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 0.9375rem;
    margin: 0;
}

.page-header-actions {
    display: flex;
    gap: var(--spacing-sm);
}

/* History Stats Row */
.history-stats {
    display: flex;
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-xl);
    flex-wrap: wrap;
}

.stat-mini {
    display: flex;
    flex-direction: column;
    padding: var(--spacing-md) var(--spacing-lg);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    min-width: 140px;
}

.stat-mini-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
}

.stat-mini-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.stat-mini.stat-success .stat-mini-value {
    color: var(--color-success);
}

.stat-mini.stat-error .stat-mini-value {
    color: var(--color-error);
}

.stat-mini.stat-info .stat-mini-value {
    color: var(--color-info);
}

/* Filters Section */
.filters-section {
    margin-bottom: var(--spacing-lg);
}

.filters-form {
    padding: var(--spacing-md);
}

.filters-row {
    display: flex;
    align-items: flex-end;
    gap: var(--spacing-md);
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-xs);
}

.filter-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.filter-input {
    padding: var(--spacing-sm) var(--spacing-md);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-primary);
    font-size: 0.875rem;
    min-width: 160px;
}

.filter-input:focus,
.filter-select:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.filter-actions {
    display: flex;
    gap: var(--spacing-sm);
}

/* Section Badge */
.section-badge {
    font-size: 0.75rem;
    padding: var(--spacing-xs) var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    color: var(--text-secondary);
}

/* History Table Enhanced */
.history-row {
    transition: background var(--transition-fast);
}

.history-row:hover {
    background: var(--bg-hover);
}

.col-id .process-link {
    color: var(--color-primary);
    font-weight: 600;
    font-family: var(--font-mono);
    font-size: 0.875rem;
    text-decoration: none;
    transition: color var(--transition-fast);
}

.col-id .process-link:hover {
    color: var(--color-primary-light);
    text-decoration: underline;
}

/* URLs Info */
.urls-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.urls-total {
    font-weight: 600;
    font-size: 0.9375rem;
    color: var(--text-primary);
}

.urls-breakdown {
    display: flex;
    gap: 4px;
    font-size: 0.75rem;
}

.urls-success {
    color: var(--color-success);
}

.urls-divider {
    color: var(--text-muted);
}

.urls-failed {
    color: var(--color-error);
}

/* Mini Progress Bar */
.mini-progress {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.mini-progress-bar {
    width: 80px;
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.mini-progress-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    transition: width var(--transition-fast);
}

.mini-progress-text {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
    min-width: 38px;
}

/* Mode Badge */
.mode-badge {
    display: inline-block;
    padding: 2px 8px;
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: var(--radius-sm);
}

.mode-fast {
    background: rgba(251, 191, 36, 0.15);
    color: var(--color-warning);
    border: 1px solid rgba(251, 191, 36, 0.3);
}

.mode-standard {
    background: rgba(59, 130, 246, 0.15);
    color: var(--color-primary);
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.mode-thorough {
    background: rgba(139, 92, 246, 0.15);
    color: #A78BFA;
    border: 1px solid rgba(139, 92, 246, 0.3);
}

/* Date Info */
.date-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.date-main {
    font-size: 0.875rem;
    color: var(--text-primary);
}

.date-time {
    font-size: 0.75rem;
    color: var(--text-muted);
}

/* Duration */
.duration {
    font-family: var(--font-mono);
    font-size: 0.875rem;
    color: var(--text-secondary);
}

/* Action Buttons */
.action-buttons {
    display: flex;
    gap: var(--spacing-xs);
}

.btn-action {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.btn-action svg {
    width: 16px;
    height: 16px;
}

.btn-action:hover {
    background: var(--bg-tertiary);
    color: var(--text-primary);
    border-color: var(--text-muted);
}

.btn-action.btn-delete:hover {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-error);
    border-color: var(--color-error);
}

.btn-action.btn-retry:hover {
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success);
    border-color: var(--color-success);
}

/* Enhanced Pagination */
.pagination {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-top: var(--spacing-xl);
    padding: var(--spacing-md) 0;
    border-top: 1px solid var(--border-light);
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.pagination-btn {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    text-decoration: none;
    transition: all var(--transition-fast);
}

.pagination-btn svg {
    width: 16px;
    height: 16px;
}

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

.pagination-pages {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
}

.pagination-page {
    min-width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-size: 0.875rem;
    text-decoration: none;
    transition: all var(--transition-fast);
}

.pagination-page:hover {
    background: var(--bg-hover);
    color: var(--text-primary);
}

.pagination-page.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
    font-weight: 600;
}

.pagination-ellipsis {
    padding: 0 var(--spacing-sm);
    color: var(--text-muted);
}

/* Modal Enhancements */
.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-normal);
}

.modal.active {
    opacity: 1;
    visibility: visible;
}

.modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    width: 100%;
    max-width: 420px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    transform: scale(0.95) translateY(10px);
    transition: transform var(--transition-normal);
}

.modal.active .modal-content {
    transform: scale(1) translateY(0);
}

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

.modal-title {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.modal-title svg {
    color: var(--color-warning);
}

.modal-close {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: none;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all var(--transition-fast);
}

.modal-close svg {
    width: 20px;
    height: 20px;
}

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

.modal-body {
    padding: var(--spacing-lg);
}

.modal-body p {
    margin: 0 0 var(--spacing-md) 0;
    color: var(--text-secondary);
}

.modal-process-id {
    padding: var(--spacing-md);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    font-family: var(--font-mono);
    font-size: 0.875rem;
}

.modal-process-id strong {
    color: var(--text-primary);
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: var(--spacing-sm);
    padding: var(--spacing-lg);
    border-top: 1px solid var(--border-color);
}

.btn-danger {
    background: rgba(239, 68, 68, 0.2);
    border: 1px solid var(--color-error);
    color: var(--color-error);
}

.btn-danger:hover {
    background: var(--color-error);
    color: white;
}

/* Small Spinner */
.spinner-small {
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-top-color: currentColor;
    border-radius: 50%;
    display: inline-block;
    animation: spin 0.8s linear infinite;
}

/* Empty State Enhancement */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-3xl) var(--spacing-xl);
    text-align: center;
}

.empty-state-icon {
    width: 64px;
    height: 64px;
    color: var(--text-muted);
    margin-bottom: var(--spacing-lg);
    opacity: 0.5;
}

.empty-state-title {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 var(--spacing-sm) 0;
}

.empty-state-text {
    color: var(--text-secondary);
    margin: 0 0 var(--spacing-lg) 0;
    max-width: 320px;
}

/* Responsive */
@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    .page-header-actions {
        width: 100%;
    }

    .page-header-actions .btn {
        flex: 1;
        justify-content: center;
    }

    .history-stats {
        display: grid;
        grid-template-columns: repeat(2, 1fr);
    }

    .filters-row {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group {
        width: 100%;
    }

    .filter-input,
    .filter-select {
        width: 100%;
    }

    .filter-actions {
        width: 100%;
        justify-content: flex-end;
    }

    .history-table {
        font-size: 0.8125rem;
    }

    .history-table th,
    .history-table td {
        padding: var(--spacing-sm);
    }

    .col-mode,
    .col-duration {
        display: none;
    }

    .pagination {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    .pagination-info {
        order: 2;
    }
}

/* ==========================================
   EXPANDABLE ROWS - History Page v3.1
   ========================================== */

/* Expand button */
.btn-expand {
    transition: transform 0.2s ease;
}

.btn-expand.expanded {
    transform: rotate(180deg);
}

.btn-expand svg {
    width: 16px;
    height: 16px;
}

/* Expand row */
.expand-row {
    background: var(--bg-tertiary);
}

.expand-row td {
    padding: 0 !important;
}

.expand-content {
    padding: var(--spacing-md) var(--spacing-lg);
    border-top: 1px solid var(--border-color);
    animation: slideDown 0.2s ease;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Expand sections */
.expand-section {
    margin-bottom: var(--spacing-sm);
}

.expand-error {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

.expand-label {
    font-size: 0.6875rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    color: var(--text-muted);
    margin-bottom: var(--spacing-xs);
}

.expand-value {
    color: var(--text-primary);
    font-size: 0.875rem;
}

.error-text {
    color: var(--color-error-light);
    font-family: monospace;
    font-size: 0.8125rem;
}

/* Expand grid */
.expand-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: var(--spacing-md);
    margin-bottom: var(--spacing-md);
}

/* Option tags */
.option-tag {
    display: inline-block;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    padding: 2px 8px;
    font-size: 0.75rem;
    margin-right: var(--spacing-xs);
    margin-bottom: var(--spacing-xs);
}

/* Mini phases */
.mini-phases {
    display: flex;
    gap: var(--spacing-xs);
}

.mini-phase {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 24px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 0.6875rem;
    font-weight: 600;
    color: var(--text-muted);
}

.mini-phase.completed {
    background: var(--color-success);
    border-color: var(--color-success);
    color: white;
}

.mini-phase.active {
    background: var(--color-primary);
    border-color: var(--color-primary);
    color: white;
    animation: pulse 1.5s infinite;
}

/* Rate badge */
.rate-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-weight: 600;
    font-size: 0.875rem;
}

.rate-badge.good {
    background: rgba(16, 185, 129, 0.2);
    color: var(--color-success-light);
}

.rate-badge.medium {
    background: rgba(245, 158, 11, 0.2);
    color: var(--color-warning-light);
}

.rate-badge.bad {
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error-light);
}

/* Stat mini */
.stat-mini {
    display: inline-block;
    font-size: 0.75rem;
    margin-right: var(--spacing-sm);
}

.stat-mini.success {
    color: var(--color-success-light);
}

.stat-mini.error {
    color: var(--color-error-light);
}

.stat-mini.muted {
    color: var(--text-muted);
}

/* Expand actions */
.expand-actions {
    display: flex;
    gap: var(--spacing-sm);
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--border-light);
}

/* Small spinner */
.spinner-small {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Button small */
.btn-sm {
    padding: 6px 12px;
    font-size: 0.8125rem;
}

/* ============================================
   LIVE INDICATOR & AUTO-REFRESH STYLES
   ============================================ */

/* Live indicator badge */
.live-indicator {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    margin-left: 12px;
    background: rgba(239, 68, 68, 0.15);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 20px;
    font-size: 0.7rem;
    font-weight: 700;
    color: #ef4444;
    letter-spacing: 0.5px;
    vertical-align: middle;
}

/* Animated dot */
.live-dot {
    width: 8px;
    height: 8px;
    background: #ef4444;
    border-radius: 50%;
    animation: pulse-dot 1.5s ease-in-out infinite;
}

@keyframes pulse-dot {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.3);
        opacity: 0.7;
    }
}

/* Flash update animation */
.flash-update {
    animation: flash-highlight 0.5s ease-out;
}

@keyframes flash-highlight {
    0% {
        background-color: rgba(59, 130, 246, 0.3);
    }
    100% {
        background-color: transparent;
    }
}

/* Updated badge flash */
.badge.flash-update {
    animation: badge-flash 0.5s ease-out;
}

@keyframes badge-flash {
    0% {
        transform: scale(1.1);
        box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.3);
    }
    100% {
        transform: scale(1);
        box-shadow: none;
    }
}

/* Progress bar smooth transition */
.mini-progress-fill,
.progress-fill {
    transition: width 0.3s ease-out;
}

/* Small live indicator for inline use */
.live-indicator.live-sm {
    padding: 2px 6px;
    margin-left: 6px;
    font-size: 0.6rem;
}

.live-indicator.live-sm .live-dot {
    width: 6px;
    height: 6px;
}

/* ==========================================
   BULK ACTIONS - HISTORY PAGE
   ========================================== */

/* Bulk Actions Bar */
.bulk-actions-bar {
    position: sticky;
    top: 64px;
    z-index: 50;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(99, 102, 241, 0.15) 100%);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: var(--radius-lg);
    margin-bottom: var(--spacing-md);
    padding: var(--spacing-md) var(--spacing-lg);
    backdrop-filter: blur(10px);
    box-shadow: var(--shadow-md);
    opacity: 0;
    transform: translateY(-10px);
    transition: opacity var(--transition-fast), transform var(--transition-fast);
}

.bulk-actions-bar.visible {
    opacity: 1;
    transform: translateY(0);
}

.bulk-actions-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--spacing-lg);
    flex-wrap: wrap;
}

.bulk-selection-info {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    color: var(--text-primary);
    font-size: 0.95rem;
}

.bulk-checkbox-icon {
    display: flex;
    align-items: center;
    color: var(--color-primary-light);
}

.bulk-count strong {
    color: var(--color-primary-light);
    font-weight: 700;
}

.bulk-actions-buttons {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

/* Checkbox Styles */
.col-checkbox {
    width: 44px;
    text-align: center;
}

.checkbox-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: var(--spacing-xs);
}

.bulk-checkbox {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.checkbox-custom {
    width: 18px;
    height: 18px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--bg-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-fast);
    position: relative;
}

.checkbox-custom::after {
    content: '';
    width: 10px;
    height: 10px;
    background: var(--color-primary);
    border-radius: 2px;
    opacity: 0;
    transform: scale(0);
    transition: all var(--transition-fast);
}

.bulk-checkbox:checked + .checkbox-custom {
    border-color: var(--color-primary);
    background: var(--bg-tertiary);
}

.bulk-checkbox:checked + .checkbox-custom::after {
    opacity: 1;
    transform: scale(1);
}

.bulk-checkbox:indeterminate + .checkbox-custom {
    border-color: var(--color-primary);
}

.bulk-checkbox:indeterminate + .checkbox-custom::after {
    opacity: 1;
    transform: scale(1);
    height: 3px;
    border-radius: 1px;
}

.checkbox-wrapper:hover .checkbox-custom {
    border-color: var(--color-primary-light);
    background: var(--bg-hover);
}

.bulk-checkbox:focus + .checkbox-custom {
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.3);
}

/* Selected Row Highlight */
.history-row.selected {
    background: rgba(59, 130, 246, 0.1);
}

.history-row.selected:hover {
    background: rgba(59, 130, 246, 0.15);
}

/* Small button variant */
.btn-xs {
    padding: 4px 10px;
    font-size: 0.75rem;
    gap: 4px;
}

.btn-xs svg {
    width: 12px;
    height: 12px;
}

/* Spinner small for bulk actions */
.spinner-small {
    display: inline-block;
    width: 14px;
    height: 14px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Mobile responsiveness for bulk actions */
@media (max-width: 768px) {
    .bulk-actions-bar {
        position: fixed;
        top: auto;
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: var(--radius-lg) var(--radius-lg) 0 0;
        margin: 0;
        padding: var(--spacing-md);
    }

    .bulk-actions-content {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    .bulk-actions-buttons {
        width: 100%;
        justify-content: stretch;
    }

    .bulk-actions-buttons .btn {
        flex: 1;
    }

    .col-checkbox {
        width: 36px;
    }
}

/* ==========================================
   PERFORMANCE LIVE SECTION (v3.1)
   Professional real-time stats with subtle animations
   ========================================== */
.performance-live-section {
    padding: var(--spacing-md);
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    margin-bottom: var(--spacing-lg);
}

.performance-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: var(--spacing-md);
}

@media (max-width: 900px) {
    .performance-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .performance-grid {
        grid-template-columns: 1fr;
    }
}

.perf-stat {
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.perf-stat:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.perf-stat-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: var(--spacing-xs);
}

.perf-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.perf-stat-trend {
    display: flex;
    align-items: center;
    color: var(--color-success);
    transition: color 0.2s ease;
}

.perf-stat-trend.down {
    color: var(--color-error);
    transform: rotate(180deg);
}

.perf-stat-percent {
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: var(--radius-sm);
    background: rgba(16, 185, 129, 0.15);
    color: var(--color-success);
}

.perf-stat-percent.negative {
    background: rgba(239, 68, 68, 0.15);
    color: var(--color-error);
}

.perf-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    line-height: 1.2;
    transition: color 0.2s ease, transform 0.15s ease;
}

.perf-stat-value.updating {
    animation: countPulse 0.25s ease-out;
}

.perf-stat-bar {
    margin-top: var(--spacing-sm);
    height: 4px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.perf-stat-bar-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    transition: width 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.perf-stat-bar-fill.batch {
    background: var(--color-info);
}

.perf-stat-bar-fill.latency {
    background: var(--color-warning);
}

.perf-stat-bar-fill.success {
    background: var(--color-success);
}

/* ==========================================
   CIRCUIT BREAKER STATUS
   ========================================== */
.circuit-breaker-status {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.cb-main-status {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
}

.cb-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.cb-indicator.cb-closed {
    background: var(--color-success);
    box-shadow: 0 0 8px rgba(16, 185, 129, 0.4);
}

.cb-indicator.cb-open {
    background: var(--color-error);
    box-shadow: 0 0 8px rgba(239, 68, 68, 0.4);
    animation: cbPulse 1s infinite ease-in-out;
}

.cb-indicator.cb-half-open {
    background: var(--color-warning);
    box-shadow: 0 0 8px rgba(251, 191, 36, 0.4);
}

@keyframes cbPulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.cb-status-text {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
}

.cb-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-xs);
}

.cb-stat {
    display: flex;
    justify-content: space-between;
    padding: var(--spacing-xs);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

.cb-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.cb-stat-value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.cb-blocked-list {
    margin-top: var(--spacing-xs);
    padding: var(--spacing-sm);
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-sm);
}

.cb-blocked-title {
    font-size: 0.7rem;
    color: var(--color-error);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.cb-blocked-list ul {
    list-style: none;
    margin: var(--spacing-xs) 0 0 0;
    padding: 0;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
}

.cb-blocked-list li {
    font-size: 0.75rem;
    padding: 2px 6px;
    background: rgba(239, 68, 68, 0.2);
    border-radius: var(--radius-sm);
    color: var(--color-error);
}

/* ==========================================
   RETRY STATS
   ========================================== */
.retry-stats {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.retry-main {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-sm);
}

.retry-stat-big {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: var(--spacing-md);
    background: var(--bg-secondary);
    border-radius: var(--radius-sm);
}

.retry-stat-big .retry-stat-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    transition: color 0.2s ease;
}

.retry-stat-big.success .retry-stat-value {
    color: var(--color-success);
}

.retry-stat-big .retry-stat-label {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-top: 2px;
}

.retry-by-phase {
    padding: var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
}

.retry-phase-title {
    font-size: 0.7rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: block;
    margin-bottom: var(--spacing-xs);
}

.retry-phase-bars {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.retry-phase-item {
    display: grid;
    grid-template-columns: 24px 1fr 32px;
    align-items: center;
    gap: var(--spacing-xs);
}

.retry-phase-label {
    font-size: 0.7rem;
    font-weight: 600;
    color: var(--text-muted);
}

.retry-phase-bar {
    height: 6px;
    background: var(--bg-secondary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.retry-phase-bar-fill {
    height: 100%;
    background: var(--color-primary);
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
}

.retry-phase-count {
    font-size: 0.75rem;
    font-family: var(--font-mono);
    color: var(--text-secondary);
    text-align: right;
}

/* ==========================================
   EXPANDED PHASE DETAILS
   ========================================== */
.phase-details {
    display: none;
    flex-direction: column;
    gap: 4px;
    margin-top: var(--spacing-sm);
    padding: var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    font-size: 0.7rem;
    min-width: 120px;
    animation: fadeSlideIn 0.2s ease-out;
}

.phase-details.expanded {
    display: flex;
}

.phase-node:hover .phase-details {
    display: flex;
}

.phase-detail-row {
    display: flex;
    align-items: center;
    gap: 4px;
}

.phase-detail-icon {
    font-size: 0.65rem;
    width: 14px;
    text-align: center;
}

.phase-detail-label {
    color: var(--text-muted);
    flex: 1;
}

.phase-detail-value {
    font-weight: 600;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.phase-detail-value.text-success {
    color: var(--color-success);
}

/* Active phase glow */
.phase-node.active .phase-circle {
    animation: activeGlow 2s infinite ease-in-out;
}

@keyframes activeGlow {
    0%, 100% { box-shadow: 0 0 12px rgba(59, 130, 246, 0.3); }
    50% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.5); }
}

/* ==========================================
   SUBTLE ANIMATIONS (Professional)
   ========================================== */

/* Count pulse - for updating numbers */
@keyframes countPulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.03); color: var(--color-primary); }
    100% { transform: scale(1); }
}

/* Fade slide in - for new elements */
@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(-6px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Log entry slide in */
.log-entry {
    animation: logSlideIn 0.2s ease-out;
}

@keyframes logSlideIn {
    from {
        opacity: 0;
        transform: translateX(-8px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

/* Status indicator pulse (subtle) */
.status-indicator.running .status-dot {
    animation: statusPulse 2s infinite ease-in-out;
}

@keyframes statusPulse {
    0%, 100% { opacity: 1; transform: scale(1); }
    50% { opacity: 0.6; transform: scale(1.15); }
}

/* Progress circle smooth transition */
.progress-circle-fill {
    transition: stroke-dashoffset 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Hero stat value transition */
.hero-stat-value {
    transition: color 0.2s ease, transform 0.15s ease;
}

.hero-stat-value.increased {
    color: var(--color-success);
}

.hero-stat-value.decreased {
    color: var(--color-error);
}

/* Skeleton loading */
.skeleton {
    background: linear-gradient(
        90deg,
        var(--bg-tertiary) 25%,
        var(--bg-secondary) 50%,
        var(--bg-tertiary) 75%
    );
    background-size: 200% 100%;
    animation: shimmer 1.5s infinite;
    border-radius: var(--radius-sm);
}

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

/* Current URL display subtle animation */
.current-url-display {
    transition: background 0.2s ease, border-color 0.2s ease;
}

.current-url-display:hover {
    background: var(--bg-hover);
}

/* Spinner icon rotation */
.spinner-icon svg {
    animation: spinSlow 2s linear infinite;
}

@keyframes spinSlow {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

/* Section hover effect */
.section {
    transition: border-color 0.2s ease;
}

.section:hover {
    border-color: var(--border-color-hover, rgba(255, 255, 255, 0.1));
}

/* Phase connector animation */
.phase-connector {
    transition: background 0.3s ease;
}

.phase-connector.completed {
    position: relative;
    overflow: hidden;
}

.phase-connector.completed::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.1), transparent);
    animation: connectorShine 3s infinite;
}

@keyframes connectorShine {
    0% { left: -100%; }
    50% { left: 100%; }
    100% { left: 100%; }
}

/* Speed chart container subtle border glow on hover */
.speed-chart-container {
    transition: box-shadow 0.2s ease;
}

.speed-chart-container:hover {
    box-shadow: inset 0 0 0 1px rgba(59, 130, 246, 0.2);
}

/* HTTP code badge hover */
.http-code-item {
    transition: transform 0.15s ease, background 0.15s ease;
    padding: 4px;
    border-radius: var(--radius-sm);
}

.http-code-item:hover {
    transform: scale(1.02);
    background: var(--bg-tertiary);
}

/* Domain item hover */
.domain-item {
    transition: background 0.15s ease;
    padding: var(--spacing-sm);
    margin: -var(--spacing-sm);
    margin-bottom: 0;
    border-radius: var(--radius-sm);
}

.domain-item:hover {
    background: var(--bg-tertiary);
}

/* Time stat value pulse on update */
.time-stat-value {
    transition: color 0.2s ease;
}

.time-stat-value.pulse {
    animation: countPulse 0.25s ease-out;
}

/* ==========================================
   v3.1 - INITIALIZING OVERLAY
   ========================================== */
.initializing-overlay {
    position: fixed;
    inset: 0;
    background: var(--bg-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: opacity 0.3s ease;
}

.init-content {
    text-align: center;
    max-width: 400px;
    padding: var(--spacing-xl);
}

.init-spinner {
    width: 64px;
    height: 64px;
    border: 4px solid var(--border-color);
    border-top-color: var(--color-primary);
    border-radius: 50%;
    margin: 0 auto var(--spacing-lg);
    animation: spin 1s linear infinite;
}

.init-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--spacing-lg);
}

.init-subtitle {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: var(--spacing-lg);
}

.init-steps {
    text-align: left;
    margin-top: var(--spacing-lg);
}

.init-step {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    padding: var(--spacing-sm) 0;
    opacity: 0.4;
    transition: opacity 0.3s ease;
}

.init-step.active {
    opacity: 1;
}

.init-step.done {
    opacity: 1;
}

.init-step .step-icon {
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
}

.init-step.done .step-icon {
    color: var(--color-success);
}

.init-step.active .step-icon {
    color: var(--color-primary);
}

.init-step .step-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.init-step.done .step-text {
    color: var(--text-primary);
}

.spinner-svg {
    animation: spin 1s linear infinite;
}

/* ==========================================
   v3.1 - DETAILED STATS SECTION
   ========================================== */
.detailed-stats-section {
    margin-top: var(--spacing-lg);
}

.stats-grid-detailed {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-md);
}

@media (max-width: 768px) {
    .stats-grid-detailed {
        grid-template-columns: 1fr;
    }
}

.stat-card-detailed {
    background: var(--bg-secondary);
    border-radius: var(--radius-md);
    padding: var(--spacing-md);
    border: 1px solid var(--border-light);
}

.stat-card-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.stat-card-title svg {
    opacity: 0.7;
}

.stat-breakdown {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.breakdown-item {
    display: grid;
    grid-template-columns: 100px 1fr 40px;
    align-items: center;
    gap: var(--spacing-sm);
}

.breakdown-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.breakdown-bar {
    height: 6px;
    background: var(--bg-tertiary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.breakdown-fill {
    height: 100%;
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
}

.breakdown-fill.blue { background: var(--color-primary); }
.breakdown-fill.orange { background: var(--color-warning); }
.breakdown-fill.red { background: var(--color-error); }
.breakdown-fill.yellow { background: #FBBF24; }
.breakdown-fill.purple { background: var(--color-info); }
.breakdown-fill.gray { background: var(--text-muted); }
.breakdown-fill.brown { background: #A78BFA; }

.breakdown-value {
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text-primary);
    text-align: right;
    font-family: var(--font-mono);
}

/* ==========================================
   v3.1 - ENHANCED LIVE LOG
   ========================================== */
.live-log-section {
    margin-top: var(--spacing-lg);
}

.log-header-enhanced {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: var(--spacing-md);
}

.log-filters {
    display: flex;
    gap: var(--spacing-xs);
}

.filter-btn {
    padding: 6px 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-light);
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 500;
    transition: all var(--transition-fast);
}

.filter-btn:hover {
    background: var(--bg-hover);
    color: var(--text-secondary);
}

.filter-btn.active {
    background: var(--color-primary);
    color: white;
    border-color: var(--color-primary);
}

.log-search {
    padding: 8px 12px;
    border-radius: var(--radius-sm);
    background: var(--bg-tertiary);
    border: 1px solid var(--border-color);
    color: var(--text-primary);
    font-size: 0.8rem;
    width: 180px;
    transition: all var(--transition-fast);
}

.log-search:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2);
}

.log-search::placeholder {
    color: var(--text-muted);
}

.live-log-enhanced {
    max-height: 400px;
    overflow-y: auto;
}

.log-entry-enhanced {
    padding: var(--spacing-sm) var(--spacing-md);
    border-bottom: 1px solid var(--border-light);
    font-family: var(--font-mono);
    font-size: 0.75rem;
    transition: background var(--transition-fast);
}

.log-entry-enhanced:hover {
    background: var(--bg-tertiary);
}

.log-entry-enhanced.log-success {
    border-left: 3px solid var(--color-success);
}

.log-entry-enhanced.log-error {
    border-left: 3px solid var(--color-error);
}

.log-entry-enhanced.log-ignored,
.log-entry-enhanced.log-warning {
    border-left: 3px solid var(--color-warning);
}

.log-entry-enhanced.log-info {
    border-left: 3px solid var(--color-info);
}

.log-row-main {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    margin-bottom: 4px;
}

.log-timestamp {
    color: var(--text-muted);
    font-size: 0.7rem;
}

.log-icon {
    font-size: 0.8rem;
}

.log-entry-enhanced.log-success .log-icon { color: var(--color-success); }
.log-entry-enhanced.log-error .log-icon { color: var(--color-error); }
.log-entry-enhanced.log-ignored .log-icon,
.log-entry-enhanced.log-warning .log-icon { color: var(--color-warning); }

.log-code {
    padding: 2px 6px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.7rem;
}

.log-code.success {
    background: rgba(16, 185, 129, 0.2);
    color: var(--color-success);
}

.log-code.error {
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error);
}

.log-code.info {
    background: rgba(99, 102, 241, 0.2);
    color: var(--color-info);
}

.log-duration {
    color: var(--text-secondary);
    font-size: 0.7rem;
}

.log-domain {
    color: var(--text-primary);
    font-weight: 500;
}

.log-row-url {
    color: var(--text-muted);
    font-size: 0.7rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    padding-left: 40px;
}

.log-row-message {
    color: var(--text-muted);
    font-size: 0.7rem;
    padding-left: 40px;
    margin-top: 2px;
    font-style: italic;
}

/* ==========================================
   v3.1 - REQUEST STATS WITH PERCENTILES
   ========================================== */
.request-stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.req-stat {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.req-stat-label {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.req-stat-value {
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

.percentiles-grid {
    display: flex;
    justify-content: space-around;
    padding-top: var(--spacing-md);
    border-top: 1px solid var(--border-light);
}

.percentile {
    text-align: center;
}

.percentile-label {
    display: block;
    font-size: 0.65rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.percentile-value {
    display: block;
    font-size: 1rem;
    font-weight: 700;
    color: var(--text-primary);
    font-family: var(--font-mono);
}

/* ==========================================
   v3.1 - HTTP CODES CATEGORIZED
   ========================================== */
.http-codes-categorized {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.http-category {
    border-radius: var(--radius-sm);
    padding: var(--spacing-sm);
}

.http-category-label {
    font-size: 0.7rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: var(--spacing-xs);
    display: block;
}

.http-category.success .http-category-label { color: var(--color-success); }
.http-category.redirect .http-category-label { color: var(--color-info); }
.http-category.client-error .http-category-label { color: var(--color-warning); }
.http-category.server-error .http-category-label { color: var(--color-error); }

.http-codes-list {
    display: flex;
    flex-wrap: wrap;
    gap: var(--spacing-xs);
}

.http-code-badge {
    font-size: 0.7rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 4px;
    font-family: var(--font-mono);
}

.http-code-badge.success {
    background: rgba(16, 185, 129, 0.2);
    color: var(--color-success);
}

.http-code-badge.redirect {
    background: rgba(99, 102, 241, 0.2);
    color: var(--color-info);
}

.http-code-badge.client-error {
    background: rgba(245, 158, 11, 0.2);
    color: var(--color-warning);
}

.http-code-badge.server-error {
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error);
}

.http-code-count {
    font-size: 0.75rem;
    color: var(--text-secondary);
    font-family: var(--font-mono);
}

.empty-category {
    color: var(--text-muted);
    font-size: 0.75rem;
}

/* ==========================================
   v3.1 - DOMAIN HEALTH INDICATORS
   ========================================== */
.domain-health-summary {
    display: flex;
    justify-content: space-around;
    padding: var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    margin-bottom: var(--spacing-md);
}

.health-indicator {
    font-size: 0.8rem;
    font-weight: 500;
}

.domain-list-enhanced {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
    max-height: 300px;
    overflow-y: auto;
}

.domain-item-enhanced {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    padding: var(--spacing-sm);
    background: var(--bg-tertiary);
    border-radius: var(--radius-sm);
    transition: all var(--transition-fast);
    border-left: 3px solid transparent;
}

.domain-item-enhanced:hover {
    background: var(--bg-hover);
}

.domain-item-enhanced.healthy {
    border-left-color: var(--color-success);
}

.domain-item-enhanced.slow {
    border-left-color: var(--color-warning);
}

.domain-item-enhanced.problematic {
    border-left-color: var(--color-error);
}

.domain-icon {
    width: 28px;
    height: 28px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-info));
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.65rem;
    font-weight: 700;
    color: white;
    flex-shrink: 0;
}

.domain-info {
    flex: 1;
    min-width: 0;
}

.domain-name {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: var(--font-mono);
}

.domain-meta {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    margin-top: 2px;
}

.domain-bar {
    flex: 1;
    height: 4px;
    background: var(--bg-primary);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.domain-bar-fill {
    height: 100%;
    background: var(--color-success);
    border-radius: var(--radius-full);
    transition: width 0.3s ease;
}

.domain-item-enhanced.slow .domain-bar-fill {
    background: var(--color-warning);
}

.domain-item-enhanced.problematic .domain-bar-fill {
    background: var(--color-error);
}

.domain-stats {
    font-size: 0.65rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.domain-error-badge {
    font-size: 0.65rem;
    padding: 2px 6px;
    background: rgba(239, 68, 68, 0.2);
    color: var(--color-error);
    border-radius: var(--radius-full);
    font-weight: 500;
}

/* ==========================================
   v3.1 - STATUS INDICATOR STATES
   ========================================== */
.status-indicator.initializing .status-dot {
    background: var(--color-warning);
    animation: pulse 1.5s infinite;
}

.status-indicator.initializing {
    color: var(--color-warning);
}

/* ==========================================
   v3.1 - RESPONSIVE ADJUSTMENTS
   ========================================== */
@media (max-width: 640px) {
    .log-header-enhanced {
        flex-direction: column;
        align-items: flex-start;
    }

    .log-filters {
        flex-wrap: wrap;
    }

    .log-search {
        width: 100%;
    }

    .breakdown-item {
        grid-template-columns: 80px 1fr 35px;
    }

    .request-stats-grid {
        grid-template-columns: 1fr;
    }

    .domain-health-summary {
        flex-direction: column;
        gap: var(--spacing-xs);
        align-items: flex-start;
    }
}
