/* Modified Items Dashboard Styles */

/* Page & Layout */
body {
    background-color: #f8fafc;
}

.page-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Header */
.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    background: white;
    padding: 24px;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.dashboard-header h1 {
    margin: 0;
    font-size: 1.5rem;
    color: #1e293b;
}

.back-link {
    text-decoration: none;
    color: #64748b;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
    margin-bottom: 8px;
    transition: color 0.2s;
}

.back-link:hover {
    color: #3b82f6;
}

.refresh-btn {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.9rem;
    transition: background 0.2s;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.2);
}

.refresh-btn:hover {
    background: #2563eb;
}

/* Table */
.sync-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
}

.sync-table th {
    text-align: left;
    padding: 16px 24px;
    background: #f8fafc;
    color: #475569;
    font-weight: 600;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-bottom: 1px solid #e2e8f0;
}

.sync-table td {
    padding: 20px 24px;
    border-bottom: 1px solid #f1f5f9;
    vertical-align: top;
}

.sync-table tr:last-child td {
    border-bottom: none;
}

.sync-table tr:hover td {
    background-color: #f8fafc;
}

/* Product Column */
.product-title {
    font-weight: 600;
    color: #0f172a;
    font-size: 1rem;
    line-height: 1.4;
    margin-bottom: 8px;
}

.row-date {
    font-size: 0.85rem;
    color: #94a3b8;
    white-space: nowrap;
}

/* SKU Badge */
.sku-badge {
    display: inline-flex;
    align-items: center;
    padding: 2px 8px;
    background: #f1f5f9;
    color: #475569;
    border-radius: 4px;
    font-size: 0.8rem;
    font-family: 'Monaco', 'Consolas', monospace;
    border: 1px solid #e2e8f0;
}

.sku-badge.old {
    background: #fee2e2;
    color: #991b1b;
    border-color: #fecaca;
    text-decoration: line-through;
    opacity: 0.8;
}

.sku-badge.new {
    background: #dcfce7;
    color: #166534;
    border-color: #bbf7d0;
}

/* Pricing Column */
.price-row, .cost-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.95rem;
    margin-bottom: 6px;
}

.label {
    color: #64748b;
    width: 45px;
    font-size: 0.85rem;
}

.current-val {
    font-weight: 600;
    color: #0f172a;
}

.old-val {
    color: #94a3b8;
    text-decoration: line-through;
    font-size: 0.9rem;
}

.new-val {
    font-weight: 700;
    color: #059669; /* Green for new value */
}

.cost-row .new-val {
    color: #ea580c; /* Orange/Red for cost changes to alert user */
}

.arrow {
    color: #cbd5e1;
    font-size: 0.9rem;
}

/* Action Buttons */
.action-cell {
    display: flex;
    gap: 12px;
}

.sync-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
    font-size: 0.9rem;
    font-weight: 500;
    color: #475569;
    min-width: 160px;
    justify-content: center;
}

/* Pending State (Default) */
.sync-btn.btn-pending {
    border-color: #fdba74;
    background: #fff7ed;
    color: #c2410c;
}

.sync-btn.btn-pending:hover {
    background: #ffedd5;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(234, 88, 12, 0.1);
}

.sync-btn.btn-pending svg {
    color: #ea580c;
}

/* Done State */
.sync-btn.btn-done {
    border-color: #86efac;
    background: #f0fdf4;
    color: #15803d;
}

.sync-btn.btn-done:hover {
    background: #dcfce7;
}

.sync-btn.btn-done svg {
    color: #16a34a;
}

/* Loading & Empty States */
#loading {
    color: #64748b;
    font-size: 1.1rem;
}

.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(59, 130, 246, 0.3);
    border-radius: 50%;
    border-top-color: #3b82f6;
    animation: spin 1s ease-in-out infinite;
    vertical-align: middle;
    margin-right: 10px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #64748b;
}

.empty-state h3 {
    color: #0f172a;
    margin: 10px 0;
}
