/**
 * Welcome Pickups Dashboard - Main Stylesheet
 * Extracted from index.html for better maintainability
 */

/* ===== BASE STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #f5f7fa;
    color: #333;
    line-height: 1.6;
    height: 100vh;
    overflow: hidden;
}

/* ===== LAYOUT ===== */
.app-container {
    display: grid;
    grid-template-rows: auto 1fr;
    height: 100vh;
}

/* ===== HEADER ===== */
.header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 15px 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.header h1 {
    font-size: 1.5em;
    flex-shrink: 0;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
    flex-wrap: wrap;
}

.header-links {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.header-links a {
    color: white;
    text-decoration: none;
    padding: 6px 12px;
    background: rgba(255,255,255,0.2);
    border-radius: 5px;
    transition: background 0.3s;
    font-size: 0.9em;
    white-space: nowrap;
}

.header-links a:hover {
    background: rgba(255,255,255,0.3);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 6px 12px;
    background: rgba(255,255,255,0.15);
    border-radius: 5px;
    font-size: 0.9em;
    white-space: nowrap;
}

/* ===== MAIN LAYOUT ===== */
.main-content {
    display: grid;
    grid-template-columns: 280px 1fr;
    height: 100%;
    overflow: hidden;
    transition: grid-template-columns 0.3s ease;
}

.main-content.sidebar-collapsed {
    grid-template-columns: 40px 1fr;
}

/* ===== SIDEBAR ===== */
.sidebar {
    background: white;
    border-right: 1px solid #e0e0e0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    position: relative;
}

.sidebar-collapse-toggle {
    position: absolute;
    top: 10px;
    right: -15px;
    width: 30px;
    height: 30px;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: all 0.3s;
    font-size: 14px;
}

.sidebar-collapse-toggle:hover {
    background: #667eea;
    color: white;
}

.sidebar-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    transition: opacity 0.3s;
}

.main-content.sidebar-collapsed .sidebar-content {
    opacity: 0;
    pointer-events: none;
}

.main-content.sidebar-collapsed .sidebar-collapse-toggle {
    right: 5px;
}

.sidebar-header {
    padding: 15px;
    border-bottom: 1px solid #e0e0e0;
}

.sidebar-header h2 {
    color: #667eea;
    font-size: 1.1em;
    margin-bottom: 10px;
}

.city-search {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 0.9em;
}

.city-search:focus {
    outline: none;
    border-color: #667eea;
}

.cities-list {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.cities-table-header {
    display: grid;
    grid-template-columns: 1fr 60px 60px;
    background: #f9fafb;
    border-bottom: 2px solid #e5e7eb;
    padding: 8px 10px;
    font-weight: 600;
    font-size: 0.7em;
    text-transform: uppercase;
    color: #6b7280;
    position: sticky;
    top: 0;
    z-index: 5;
}

.cities-table-header-cell {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 4px;
}

.cities-table-header-cell:hover {
    color: #667eea;
}

.sort-icon {
    font-size: 0.8em;
    opacity: 0.5;
}

.sort-icon.active {
    opacity: 1;
    color: #667eea;
}

.city-item {
    display: grid;
    grid-template-columns: 1fr 60px 60px;
    padding: 8px 10px;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.8em;
    align-items: center;
}

.city-item:hover {
    background: #f8f9fa;
}

.city-item.active {
    background: #667eea;
    color: white;
}

.city-name {
    font-weight: 500;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.city-metric {
    text-align: right;
    font-size: 0.9em;
    font-weight: 600;
    color: #16a34a;
}

.city-item.active .city-metric {
    color: rgba(255,255,255,0.9);
}

.city-metric.empty {
    color: #d1d5db;
}

.city-item.active .city-metric.empty {
    color: rgba(255,255,255,0.4);
}

/* ===== SIDEBAR FILTERS ===== */
.sidebar-filters {
    border-bottom: 1px solid #e0e0e0;
    background: #f8f9fa;
}

.filter-toggle {
    width: 100%;
    padding: 8px 10px;
    background: white;
    border: none;
    border-bottom: 1px solid #e0e0e0;
    cursor: pointer;
    font-size: 0.8em;
    font-weight: 600;
    color: #667eea;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.filter-toggle:hover {
    background: #f8f9fa;
}

.filter-toggle-icon {
    transition: transform 0.2s;
    font-size: 0.9em;
}

.filter-toggle-icon.collapsed {
    transform: rotate(-90deg);
}

.filter-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease-out;
    padding: 0 10px;
}

.filter-content.expanded {
    max-height: 400px;
    padding: 10px;
}

.filter-group {
    margin-bottom: 8px;
}

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

.filter-label {
    font-size: 0.75em;
    font-weight: 600;
    color: #666;
    margin-bottom: 3px;
    display: block;
}

.filter-select {
    width: 100%;
    padding: 5px 8px;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 0.75em;
    background: white;
    cursor: pointer;
}

.filter-select:focus {
    outline: none;
    border-color: #667eea;
}

.filter-reset {
    width: 100%;
    padding: 5px 8px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 0.75em;
    cursor: pointer;
    margin-top: 8px;
    transition: background 0.3s;
}

.filter-reset:hover {
    background: #5568d3;
}

/* ===== CONTENT AREA ===== */
.content-area {
    overflow-y: auto;
    padding: 20px;
}

/* ===== STATS & CARDS ===== */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
    margin-bottom: 25px;
}

.stat-card {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
    border-left: 4px solid #667eea;
}

.stat-value {
    font-size: 2em;
    font-weight: 700;
    color: #667eea;
    margin-bottom: 5px;
}

.stat-label {
    color: #666;
    font-size: 0.9em;
}

/* ===== SECTIONS ===== */
.section {
    background: white;
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.section h2 {
    color: #667eea;
    font-size: 1.3em;
}

/* ===== BUTTONS ===== */
.btn {
    padding: 8px 16px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    transition: background 0.3s;
}

.btn:hover {
    background: #5568d3;
}

.btn-success {
    background: #27ae60;
}

.btn-success:hover {
    background: #229954;
}

.btn-warning {
    background: #ffd700;
    color: #333;
}

.btn-warning:hover {
    background: #ffcc00;
}

.btn-secondary {
    background: #6c757d;
}

.btn-secondary:hover {
    background: #5a6268;
}

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

.btn-icon {
    background: #f3f4f6;
    border: 1px solid #e5e7eb;
    color: #6b7280;
    padding: 4px 8px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.15s;
    line-height: 1;
}

.btn-icon:hover {
    background: #e5e7eb;
    color: #374151;
    border-color: #d1d5db;
}

.btn-icon-active {
    background: #fef3c7;
    border-color: #fcd34d;
    color: #92400e;
}

.btn-icon-active:hover {
    background: #fde68a;
}

/* ===== BADGES ===== */
.badge {
    padding: 4px 8px;
    background: #e9ecef;
    border-radius: 4px;
    font-size: 0.8em;
}

.sku-badge {
    display: inline-block;
    padding: 2px 6px;
    background: #f3f4f6;
    border-radius: 3px;
    font-size: 11px;
    font-weight: 500;
    color: #374151;
}

.sku-badge-primary {
    background: #dbeafe;
    color: #1e40af;
}

.sku-badge-muted {
    background: #f3f4f6;
    color: #9ca3af;
}

.status-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 500;
}

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

.status-error {
    background: #f8d7da;
    color: #721c24;
}

.health-badge {
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 0.8em;
    font-weight: 600;
}

.health-excellent {
    background: #d4edda;
    color: #155724;
}

.health-good {
    background: #d1ecf1;
    color: #0c5460;
}

.health-poor {
    background: #fff3cd;
    color: #856404;
}

.health-critical {
    background: #f8d7da;
    color: #721c24;
}

.issue-badge {
    padding: 2px 6px;
    background: #fee2e2;
    color: #991b1b;
    border-radius: 3px;
    font-size: 0.7em;
    font-weight: 500;
}

/* ===== CITY TABS ===== */
.city-tabs {
    display: flex;
    gap: 5px;
    border-bottom: 2px solid #e0e0e0;
    margin-top: 20px;
}

.city-tab {
    padding: 12px 24px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #666;
    transition: all 0.2s;
}

.city-tab:hover {
    color: #667eea;
    background: #f8f9ff;
}

.city-tab.active {
    color: #667eea;
    border-bottom-color: #667eea;
}

.city-tab-content {
    animation: fadeIn 0.3s;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* ===== SKU STYLES ===== */
.benchmark-sku {
    border: 2px solid #ffd700 !important;
    box-shadow: 0 0 10px rgba(255, 215, 0, 0.2);
}

.draft-sku {
    opacity: 0.7;
    border: 2px solid #ff9800 !important;
    background: #fffbf0 !important;
}

.draft-sku:hover {
    opacity: 1;
}

/* SKU Table Layout */
.sku-table-header {
    display: flex;
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-bottom: 2px solid #d1d5db;
    padding: 8px 12px;
    font-weight: 600;
    font-size: 11px;
    text-transform: uppercase;
    color: #6b7280;
    letter-spacing: 0.05em;
    margin-bottom: 2px;
    border-radius: 6px 6px 0 0;
}

.sku-table-row {
    display: flex;
    background: white;
    border: 1px solid #e5e7eb;
    border-top: none;
    padding: 8px 12px;
    margin-bottom: 1px;
    transition: all 0.15s;
    align-items: center;
}

.sku-table-row:last-child {
    border-radius: 0 0 6px 6px;
}

.sku-table-row:hover {
    background: #f9fafb;
    border-color: #667eea;
    box-shadow: 0 1px 3px rgba(102, 126, 234, 0.1);
}

.sku-table-cell {
    padding: 0 8px;
}

.sku-cell-main {
    flex: 2;
    min-width: 280px;
}

.sku-cell-route {
    flex: 1.5;
    min-width: 180px;
}

.sku-cell-meta {
    flex: 0.8;
    min-width: 100px;
}

.sku-cell-stats {
    flex: 1;
    min-width: 120px;
}

.sku-cell-actions {
    flex: 0.6;
    min-width: 100px;
    text-align: right;
}

/* ===== ROUTES & COMPETITORS ===== */
.routes-grid {
    display: grid;
    gap: 15px;
}

.route-card {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #667eea;
}

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

.route-path {
    font-weight: 600;
    font-size: 1.1em;
}

.route-meta {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 10px;
}

.competitors-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.competitor-tag {
    padding: 4px 10px;
    background: #667eea;
    color: white;
    border-radius: 4px;
    font-size: 0.8em;
}

/* ===== CAR TYPE MAPPINGS ===== */
.car-class-card {
    background: white;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: all 0.2s;
}

.car-class-card:hover {
    border-color: #667eea;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.1);
}

.car-class-card.unmapped {
    border-left: 4px solid #ff9800;
    background: #fff8f0;
}

.car-class-card.not-competitor {
    border-left: 4px solid #999;
    background: #f5f5f5;
    opacity: 0.8;
}

.car-class-info {
    flex: 1;
}

.car-class-name {
    font-weight: 600;
    font-size: 1.1em;
    margin-bottom: 5px;
}

.car-class-meta {
    font-size: 0.85em;
    color: #666;
}

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

.mapping-select {
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 0.9em;
    background: white;
}

.mapping-select:focus {
    outline: none;
    border-color: #667eea;
}

/* ===== FILTER PILLS ===== */
.filter-pill {
    padding: 8px 16px;
    border: 2px solid #e0e0e0;
    background: white;
    border-radius: 20px;
    font-size: 0.9em;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.filter-pill:hover {
    border-color: #667eea;
    background: #f5f7ff;
}

.filter-pill.active {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* ===== TABLES ===== */
.results-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

.results-table th,
.results-table td {
    text-align: left;
    padding: 12px;
    border-bottom: 1px solid #e0e0e0;
}

.results-table th {
    background: #f8f9fa;
    font-weight: 600;
    color: #555;
    font-size: 0.9em;
}

.results-table tr:hover {
    background: #f8f9fa;
}

.price-cell {
    font-weight: 600;
    color: #27ae60;
    font-size: 1.1em;
}

/* ===== BOOKING WINDOW RESULTS ===== */
.booking-window-results {
    margin: 20px 0;
    padding: 20px;
    background: white;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.booking-window-results h3 {
    color: #333;
    margin-bottom: 15px;
    font-size: 1.1em;
}

.bw-results-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    font-size: 0.9em;
}

.bw-results-table th,
.bw-results-table td {
    border: 1px solid #ddd;
    padding: 10px;
    text-align: left;
}

.bw-results-table th {
    background-color: #f2f2f2;
    font-weight: 600;
    color: #555;
}

.bw-results-table tr:hover {
    background-color: #f9f9f9;
}

.surge-high {
    background-color: #ffcccc;
    font-weight: bold;
    color: #c0392b;
}

.surge-medium {
    background-color: #fff4cc;
    font-weight: 600;
    color: #d68910;
}

.surge-low {
    background-color: #ccffcc;
    color: #27ae60;
}

.your-strategy-row {
    background: #e6f7ff !important;
    font-weight: bold;
    border-top: 2px solid #667eea;
}

.your-strategy-row:hover {
    background: #d9f0ff !important;
}

.results-timestamp {
    margin-top: 10px;
    font-size: 0.85em;
    color: #666;
    font-style: italic;
}

/* ===== PRICE COMPARISON TABLE ===== */
.price-compare-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.price-compare-table thead th {
    background: #f9fafb;
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 11px;
    text-transform: uppercase;
    color: #6b7280;
    border-bottom: 2px solid #e5e7eb;
}

.price-compare-table thead th:nth-child(1) {
    width: 18%;
}

.price-compare-table thead th:nth-child(2) {
    width: 30%;
    min-width: 220px;
}

.price-compare-table thead th:nth-child(3) {
    width: 12%;
}

.price-compare-table thead th:nth-child(4) {
    width: 12%;
}

.price-compare-table thead th:nth-child(5) {
    width: 8%;
    text-align: center;
}

.price-compare-table thead th:nth-child(6) {
    width: 10%;
}

.price-compare-table thead th:last-child {
    width: 40px;
    text-align: center;
}

.competitor-summary-row {
    cursor: pointer;
    transition: background 0.15s;
    border-bottom: 1px solid #e5e7eb;
}

.competitor-summary-row:hover {
    background: #f9fafb;
}

.competitor-summary-row.is-you {
    background: #ede9fe;
    font-weight: 600;
}

.competitor-summary-row.is-you:hover {
    background: #ddd6fe;
}

.competitor-summary-row td {
    padding: 12px;
}

.competitor-summary-row.expanded {
    background: #f3f4f6;
}

.expand-icon {
    font-size: 16px;
    transition: transform 0.2s;
    display: inline-block;
    color: #6b7280;
}

.competitor-summary-row.expanded .expand-icon {
    transform: rotate(90deg);
}

.scrape-details-row {
    background: #f9fafb;
    border-bottom: 1px solid #e5e7eb;
}

.scrape-details-container {
    padding: 16px 20px;
}

.scrape-history-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 12px;
    background: white;
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.scrape-history-table thead th {
    background: #f3f4f6;
    padding: 8px 10px;
    text-align: left;
    font-weight: 600;
    font-size: 11px;
    color: #6b7280;
    border-bottom: 1px solid #e5e7eb;
}

.scrape-history-table tbody td {
    padding: 8px 10px;
    border-bottom: 1px solid #f3f4f6;
}

.scrape-history-table tbody tr:last-child td {
    border-bottom: none;
}

.scrape-history-table tbody tr:hover {
    background: #f9fafb;
}

.price-diff-positive {
    color: #dc2626;
    font-weight: 600;
}

.price-diff-negative {
    color: #16a34a;
    font-weight: 600;
}

.price-diff-neutral {
    color: #9ca3af;
}

.trend-sparkline {
    display: inline-block;
    font-family: monospace;
    font-size: 16px;
    line-height: 1;
    letter-spacing: -2px;
    color: #6b7280;
}

.status-indicator {
    display: inline-block;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    margin-right: 6px;
}

.status-winning {
    background: #16a34a;
}

.status-losing {
    background: #dc2626;
}

.status-neutral {
    background: #f59e0b;
}

.status-you {
    background: #667eea;
}

/* ===== PRICE CHARTS ===== */
.price-chart-container {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin: 20px 0;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

.chart-controls {
    display: flex;
    gap: 12px;
    margin-bottom: 15px;
    flex-wrap: wrap;
    align-items: center;
}

.chart-controls label {
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
}

.chart-controls select,
.chart-controls input {
    padding: 6px 10px;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    font-size: 13px;
    background: white;
}

.chart-controls select:focus,
.chart-controls input:focus {
    outline: none;
    border-color: #667eea;
}

#priceChart {
    max-height: 400px;
}

/* ===== PRICE COMPARISON VISUAL ===== */
.price-comparison-visual {
    display: flex;
    flex-direction: column;
    gap: 4px;
    width: 100%;
}

.price-comparison-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.price-bar-container {
    flex: 1;
    height: 6px;
    background: #f3f4f6;
    border-radius: 3px;
    overflow: hidden;
}

.price-bar {
    height: 100%;
    transition: width 0.3s ease;
}

.price-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
}

.price-status-text {
    font-size: 10px;
    color: #6b7280;
    white-space: nowrap;
}

/* ===== HOME PAGE STYLES ===== */
.cities-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

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

.attention-city-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-left: 3px solid #ff9800;
    border-radius: 6px;
    padding: 10px 12px;
    transition: all 0.15s;
    cursor: pointer;
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.attention-city-card:hover {
    border-color: #667eea;
    border-left-color: #667eea;
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.15);
    transform: translateX(2px);
}

.attention-city-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
}

.attention-city-name {
    font-weight: 600;
    font-size: 0.95em;
    color: #333;
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.attention-city-metric {
    font-size: 0.8em;
    color: #667eea;
    font-weight: 600;
    white-space: nowrap;
}

.attention-issues {
    display: flex;
    gap: 4px;
    flex-wrap: wrap;
}

.attention-meta {
    display: flex;
    gap: 8px;
    font-size: 0.75em;
    color: #999;
}

.attention-meta span {
    display: flex;
    align-items: center;
    gap: 3px;
}

.scraper-perf-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9em;
}

.scraper-perf-table thead th {
    background: #f9fafb;
    padding: 10px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 0.85em;
    text-transform: uppercase;
    color: #6b7280;
    border-bottom: 2px solid #e5e7eb;
}

.scraper-perf-table tbody td {
    padding: 12px;
    border-bottom: 1px solid #f0f0f0;
}

.scraper-perf-table tbody tr:hover {
    background: #f9fafb;
}

.progress-bar-container {
    width: 100%;
    height: 8px;
    background: #f0f0f0;
    border-radius: 4px;
    overflow: hidden;
    margin-top: 5px;
}

.progress-bar {
    height: 100%;
    background: #667eea;
    transition: width 0.3s;
}

.progress-bar.excellent {
    background: #16a34a;
}

.progress-bar.good {
    background: #3b82f6;
}

.progress-bar.poor {
    background: #f59e0b;
}

.progress-bar.critical {
    background: #dc2626;
}

.top-city-card {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 4px;
    padding: 8px 12px;
    margin-bottom: 4px;
    display: grid;
    grid-template-columns: 2fr 120px 100px 100px 80px;
    gap: 12px;
    align-items: center;
    transition: all 0.15s;
    cursor: pointer;
    font-size: 0.85em;
}

.top-city-card:hover {
    border-color: #667eea;
    box-shadow: 0 2px 6px rgba(102, 126, 234, 0.1);
    transform: translateX(2px);
    background: #f9fafb;
}

.city-info-col {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.city-name-home {
    font-weight: 600;
    color: #333;
    font-size: 1em;
}

.city-country {
    font-size: 0.85em;
    color: #999;
}

.setup-score-col {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.score-value {
    font-weight: 700;
    font-size: 1.3em;
}

.score-label {
    font-size: 0.75em;
    color: #666;
}

.status-col {
    display: flex;
    align-items: center;
    gap: 5px;
}

.status-icon {
    font-size: 1.2em;
}

.recent-activity-item {
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 10px 15px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9em;
}

.activity-info {
    display: flex;
    gap: 15px;
    align-items: center;
}

.activity-timestamp {
    color: #999;
    font-size: 0.85em;
    min-width: 120px;
}

.activity-details {
    display: flex;
    gap: 8px;
    align-items: center;
}

/* ===== FORMS & INPUTS ===== */
.date-filter {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 15px;
}

.date-filter input {
    padding: 8px 12px;
    border: 2px solid #e0e0e0;
    border-radius: 5px;
    font-size: 0.9em;
}

.date-filter input:focus {
    outline: none;
    border-color: #667eea;
}

/* ===== INFO BOX ===== */
.info-box {
    background: #e7f3ff;
    border-left: 4px solid #2196F3;
    padding: 15px;
    border-radius: 5px;
    font-size: 0.9em;
    line-height: 1.6;
}

/* ===== EMPTY STATES ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.empty-state-icon {
    font-size: 3em;
    margin-bottom: 15px;
}

/* ===== LOADING ===== */
.loading {
    text-align: center;
    padding: 40px;
    color: #999;
}

/* ===== SCROLLBAR ===== */
.cities-list::-webkit-scrollbar,
.content-area::-webkit-scrollbar {
    width: 8px;
}

.cities-list::-webkit-scrollbar-track,
.content-area::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.cities-list::-webkit-scrollbar-thumb,
.content-area::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

.cities-list::-webkit-scrollbar-thumb:hover,
.content-area::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* ===== MODAL STYLES ===== */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-box {
    background: white;
    border-radius: 8px;
    padding: 24px;
    max-width: 600px;
    width: 90%;
    max-height: 90vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-header h3 {
    margin: 0;
    color: #333;
}

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
}

.form-group {
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #555;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.form-group small {
    display: block;
    margin-top: 4px;
    color: #999;
    font-size: 12px;
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
}

.competitor-mapping {
    background: #f5f5f5;
    padding: 12px;
    border-radius: 4px;
    margin-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}
