/* Purview Admin Dashboard - Reusable Component Styles */

/* ============================================================================
   BUTTONS
   ============================================================================ */
.action-btn {
    padding: 0.75rem 1.5rem;
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-purple) 100%);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(91, 141, 239, 0.25), 0 4px 16px rgba(91, 141, 239, 0.15);
    letter-spacing: 0.01em;
}

.action-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.action-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(91, 141, 239, 0.35), 0 8px 24px rgba(91, 141, 239, 0.2);
    filter: brightness(1.05);
}

.action-btn:hover::before { left: 100%; }
.action-btn:active { transform: translateY(0); }

.action-btn.primary {
    background: linear-gradient(135deg, var(--accent-teal) 0%, var(--accent-emerald) 100%);
    box-shadow: 0 4px 12px rgba(45, 212, 191, 0.3);
}

.action-btn.primary:hover { box-shadow: 0 6px 20px rgba(45, 212, 191, 0.4); }

.action-btn.danger {
    background: linear-gradient(135deg, var(--accent-rose) 0%, #f43f5e 100%);
    box-shadow: 0 4px 12px rgba(251, 113, 133, 0.3);
}

.action-btn.danger:hover { box-shadow: 0 6px 20px rgba(251, 113, 133, 0.4); }

.action-btn.warning {
    background: linear-gradient(135deg, var(--accent-amber) 0%, var(--accent-orange) 100%);
    box-shadow: 0 4px 12px rgba(251, 191, 36, 0.3);
}

.action-btn.warning:hover { box-shadow: 0 6px 20px rgba(251, 191, 36, 0.4); }

.action-btn.small {
    padding: 0.5rem 1rem;
    font-size: 0.75rem;
}

.action-btn:disabled {
    background: linear-gradient(135deg, #4a5568 0%, #2d3748 100%);
    cursor: not-allowed;
    opacity: 0.5;
    box-shadow: none;
}

.action-btn:disabled:hover { transform: none; }

#logout-btn {
    padding: 0.625rem 1.25rem;
    background: linear-gradient(135deg, var(--accent-rose) 0%, #f43f5e 100%);
    color: white;
    border: none;
    border-radius: var(--radius-md);
    cursor: pointer;
    font-weight: 600;
    font-size: 0.9375rem;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 8px rgba(251, 113, 133, 0.25);
}

#logout-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(251, 113, 133, 0.35);
    filter: brightness(1.05);
}

/* ============================================================================
   FORMS
   ============================================================================ */
.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-bright);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 0.875rem 1.125rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    background: rgba(19, 22, 28, 0.5);
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(19, 22, 28, 0.8);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15), inset 0 1px 3px rgba(0, 0, 0, 0.15);
}

.form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.search-input {
    flex: 1;
    min-width: 220px;
    padding: 0.75rem 1rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    background: rgba(19, 22, 28, 0.5);
    color: var(--text-primary);
    transition: all var(--transition-base);
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(19, 22, 28, 0.7);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15);
}

.filter-select {
    padding: 0.75rem 1rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    background: rgba(19, 22, 28, 0.5);
    color: var(--text-primary);
    transition: all var(--transition-base);
}

.filter-select:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15);
}

.date-input {
    padding: 0.75rem 1rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.9375rem;
    background: rgba(19, 22, 28, 0.5);
    color: var(--text-primary);
    transition: all var(--transition-base);
}

.date-input:focus {
    outline: none;
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15);
}

select {
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23cccccc' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 20px;
    padding-right: 40px;
}

/* ============================================================================
   TABLES
   ============================================================================ */
.table-container {
    background: linear-gradient(135deg, rgba(19, 22, 28, 0.7) 0%, rgba(33, 38, 47, 0.85) 100%);
    border-radius: var(--radius-lg);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2), 0 4px 16px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    border: 1px solid rgba(91, 141, 239, 0.15);
}

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

th {
    background: linear-gradient(135deg, rgba(33, 38, 47, 0.95) 0%, rgba(40, 46, 56, 0.95) 100%);
    padding: 1.125rem 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.8125rem;
    color: var(--text-bright);
    border-bottom: 2px solid rgba(91, 141, 239, 0.2);
    text-transform: uppercase;
    letter-spacing: 0.075em;
    position: relative;
}

th::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(90deg, var(--accent-cyan) 0%, var(--accent-primary) 50%, var(--accent-purple) 100%);
    opacity: 0.5;
}

td {
    padding: 1.125rem 1rem;
    border-bottom: 1px solid rgba(91, 141, 239, 0.1);
    color: var(--text-primary);
    font-size: 0.9375rem;
    transition: all var(--transition-fast);
    line-height: 1.6;
}

tbody tr {
    transition: all var(--transition-base);
    position: relative;
}

tbody tr:hover {
    background: linear-gradient(90deg, rgba(91, 141, 239, 0.1) 0%, rgba(167, 139, 250, 0.05) 50%, transparent 100%);
}

tbody tr:last-child td { border-bottom: none; }

.mini-table { width: 100%; font-size: 14px; margin-top: 10px; }
.mini-table th { background: var(--bg-tertiary); padding: 8px; font-size: 12px; color: var(--text-secondary); }
.mini-table td { padding: 8px; font-size: 12px; color: var(--text-primary); }

/* ============================================================================
   BADGES
   ============================================================================ */
.badge {
    display: inline-block;
    padding: 0.375rem 0.875rem;
    font-size: 0.75rem;
    font-weight: 600;
    border-radius: var(--radius-full);
    text-transform: uppercase;
    letter-spacing: 0.06em;
    border: 1px solid transparent;
    transition: all var(--transition-fast);
}

.badge-user { background: linear-gradient(135deg, rgba(91, 141, 239, 0.2), rgba(91, 141, 239, 0.3)); color: var(--accent-primary); border-color: rgba(91, 141, 239, 0.4); }
.badge-admin { background: linear-gradient(135deg, rgba(167, 139, 250, 0.2), rgba(167, 139, 250, 0.3)); color: var(--accent-purple); border-color: rgba(167, 139, 250, 0.4); }
.badge-active { background: linear-gradient(135deg, rgba(77, 222, 128, 0.2), rgba(77, 222, 128, 0.3)); color: var(--accent-secondary); border-color: rgba(77, 222, 128, 0.4); }
.badge-inactive { background: linear-gradient(135deg, rgba(251, 113, 133, 0.2), rgba(251, 113, 133, 0.3)); color: var(--accent-rose); border-color: rgba(251, 113, 133, 0.4); }
.badge-success { background: linear-gradient(135deg, rgba(45, 212, 191, 0.2), rgba(45, 212, 191, 0.3)); color: var(--accent-teal); border-color: rgba(45, 212, 191, 0.4); }
.badge-warning { background: linear-gradient(135deg, rgba(255, 140, 66, 0.2), rgba(255, 140, 66, 0.3)); color: var(--accent-orange); border-color: rgba(255, 140, 66, 0.4); }
.badge-error { background: linear-gradient(135deg, rgba(251, 113, 133, 0.2), rgba(251, 113, 133, 0.3)); color: var(--accent-rose); border-color: rgba(251, 113, 133, 0.4); }
.badge-info { background: linear-gradient(135deg, rgba(91, 141, 239, 0.2), rgba(91, 141, 239, 0.3)); color: var(--accent-primary); border-color: rgba(91, 141, 239, 0.4); }
.badge-default { background: linear-gradient(135deg, rgba(120, 130, 145, 0.15), rgba(120, 130, 145, 0.25)); color: var(--text-secondary); border-color: rgba(120, 130, 145, 0.3); }

.badge-sm {
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.625rem;
    border-radius: var(--radius-lg);
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
}

.status-badge-sm {
    padding: 0.125rem 0.5rem;
    font-size: 0.625rem;
}

.title-badges {
    display: flex;
    gap: 0.3125rem;
    align-items: center;
    margin-top: 0.375rem;
}

.status-badge.status-pending { background-color: #3a3d41; color: #b8b8b8; }
.status-badge.status-processing, .status-badge.status-in_progress { background-color: #0e639c; color: #ffffff; }
.status-badge.status-completed { background-color: #0e5a0e; color: #4ec9b0; }
.status-badge.status-failed, .status-badge.status-error { background-color: #5a1e1e; color: #f48771; }
.status-badge.status-error_retry { background-color: #5a4e1e; color: #d7ba7d; }
.status-badge.status-rejected { background-color: #5a1e3e; color: #d16dc3; }
.status-badge.status-active, .status-badge.status-ready { background: var(--status-success-bg); color: #7fd14c; }
.status-badge.status-staged { background-color: #3a3d41; color: #b8b8b8; }
.status-badge.status-unknown { background: var(--bg-input); color: #999; }
.status-badge.status-reviewed { background: #2196f3; color: #fff; }
.status-badge.status-dismissed { background: #757575; color: #fff; }
.status-badge.status-online { background: #c8e6c9; color: #2e7d32; }
.status-badge.status-offline { background: #ffcdd2; color: #c62828; }

/* ============================================================================
   MODALS
   ============================================================================ */
#modal-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background: linear-gradient(135deg, rgba(19, 22, 28, 0.97) 0%, rgba(33, 38, 47, 0.98) 100%);
    border-radius: var(--radius-lg);
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.5), 0 0 80px rgba(91, 141, 239, 0.15);
    max-width: 90vw;
    width: 90vw;
    max-height: 90vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(91, 141, 239, 0.2);
    z-index: 1001;
}

.modal::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--accent-cyan) 0%, var(--accent-primary) 50%, var(--accent-purple) 100%);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.75rem 2rem;
    border-bottom: 1px solid rgba(91, 141, 239, 0.15);
    background: linear-gradient(135deg, rgba(33, 38, 47, 0.7) 0%, rgba(40, 46, 56, 0.7) 100%);
}

.modal-header h3 { margin: 0; color: var(--text-heading); font-size: 1.375rem; font-weight: 600; }

.modal-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: var(--text-secondary);
    line-height: 1;
}

.modal-close:hover { color: var(--text-bright); }

.modal-content, .modal-body {
    padding: 2rem;
    overflow-y: auto;
    flex: 1;
    color: var(--text-primary);
    line-height: 1.65;
}

.modal-actions, .modal-footer {
    padding: 1.5rem 2rem;
    border-top: 1px solid rgba(91, 141, 239, 0.15);
    display: flex;
    justify-content: flex-end;
    gap: 0.75rem;
    background: linear-gradient(135deg, rgba(19, 22, 28, 0.6) 0%, rgba(33, 38, 47, 0.6) 100%);
}

/* ============================================================================
   PAGINATION
   ============================================================================ */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 5px;
    margin-top: 20px;
    padding: 1rem;
}

.page-btn {
    padding: 0.625rem 1rem;
    background: rgba(19, 22, 28, 0.6);
    border: 1px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
    color: var(--text-secondary);
    font-weight: 500;
    font-size: 0.875rem;
}

.page-btn:hover {
    background: rgba(91, 141, 239, 0.15);
    border-color: var(--accent-primary);
    color: var(--text-bright);
    transform: translateY(-1px);
}

.page-number {
    padding: 0.625rem 1rem;
    color: var(--text-secondary);
    font-size: 0.875rem;
}

.page-number.active {
    background: linear-gradient(135deg, var(--accent-primary) 0%, var(--accent-purple) 100%);
    color: white;
    border-radius: var(--radius-md);
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(91, 141, 239, 0.3);
}

.page-ellipsis { padding: 8px; color: var(--text-muted); }

/* ============================================================================
   METRICS GRID
   ============================================================================ */
.metrics-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

/* ============================================================================
   LOADING OVERLAY
   ============================================================================ */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
}

.spinner {
    width: 64px;
    height: 64px;
    border: 5px solid transparent;
    border-top: 5px solid var(--accent-cyan);
    border-right: 5px solid var(--accent-primary);
    border-bottom: 5px solid var(--accent-purple);
    border-left: 5px solid var(--accent-pink);
    border-radius: 50%;
    animation: spin 1s cubic-bezier(0.68, -0.55, 0.265, 1.55) infinite;
    box-shadow: 0 0 40px rgba(91, 141, 239, 0.3), inset 0 0 20px rgba(91, 141, 239, 0.1);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* ============================================================================
   TOAST NOTIFICATIONS
   ============================================================================ */
.toast {
    position: fixed;
    top: 24px;
    right: 24px;
    padding: 1rem 1.5rem;
    border-radius: var(--radius-md);
    color: white;
    font-size: 0.9375rem;
    font-weight: 500;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
    animation: slideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 3000;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.toast.success {
    background: linear-gradient(135deg, rgba(45, 212, 191, 0.95), rgba(52, 211, 153, 0.95));
    box-shadow: 0 8px 24px rgba(45, 212, 191, 0.3);
}

.toast.error {
    background: linear-gradient(135deg, rgba(251, 113, 133, 0.95), rgba(244, 63, 94, 0.95));
    box-shadow: 0 8px 24px rgba(251, 113, 133, 0.3);
}

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

/* ============================================================================
   ERROR MESSAGE
   ============================================================================ */
.error-message {
    color: var(--status-error);
    text-align: center;
    margin-top: 10px;
    font-size: 14px;
}

/* ============================================================================
   CURATION SECTION
   ============================================================================ */
.curation-section {
    background-color: var(--bg-tertiary);
    padding: 1rem;
    margin: 1.25rem 0;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-primary);
}

.curation-section h3 {
    margin-top: 0;
    margin-bottom: 1rem;
    color: var(--text-bright);
}

.curation-stats {
    flex: 1;
}

.curation-stats p {
    margin: 0.3125rem 0;
    color: var(--text-secondary);
}

.curation-actions {
    display: flex;
    gap: 0.625rem;
    flex-wrap: wrap;
}

.status-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 0.625rem;
    margin-top: 0.625rem;
}

.status-item {
    background-color: var(--bg-primary);
    padding: 0.625rem;
    border-radius: var(--radius-sm);
    border: 1px solid var(--border-primary);
}

.status-item strong {
    color: var(--text-bright);
}

/* ============================================================================
   TWO PANEL LAYOUT
   ============================================================================ */
.two-panel-layout {
    display: grid;
    grid-template-columns: 350px 1fr;
    gap: 2rem;
    min-height: 500px;
}

.panel {
    background: linear-gradient(135deg, rgba(19, 22, 28, 0.7) 0%, rgba(33, 38, 47, 0.85) 100%);
    border: 1px solid rgba(91, 141, 239, 0.15);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    overflow-y: auto;
}

.card-list { display: flex; flex-direction: column; gap: 0.5rem; }

.selectable-card {
    padding: 1rem;
    border: 1px solid var(--border-primary);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: all var(--transition-base);
}

.selectable-card:hover { border-color: var(--accent-primary); background: rgba(91, 141, 239, 0.05); }
.selectable-card.selected { border-color: var(--accent-primary); background: rgba(91, 141, 239, 0.1); }

.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.form-actions { display: flex; gap: 0.75rem; margin-top: 1.5rem; }

/* ============================================================================
   SETTINGS SECTIONS & ROWS
   ============================================================================ */
.settings-section {
    background: rgba(19, 22, 28, 0.4);
    border: 1px solid rgba(91, 141, 239, 0.12);
    border-radius: var(--radius-md);
    padding: 1.25rem;
    margin-top: 1.5rem;
}

.settings-section h4 {
    margin-bottom: 0.5rem;
    color: var(--text-bright);
    font-size: 1rem;
    font-weight: 600;
}

.settings-section > p {
    margin-bottom: 1rem;
}

.settings-row {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.5rem 0;
}

.settings-row label {
    min-width: 140px;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-bright);
    flex-shrink: 0;
}

.settings-row input {
    padding: 0.5rem 0.75rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    font-size: 0.875rem;
    background: rgba(19, 22, 28, 0.5);
    color: var(--text-primary);
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: inset 0 1px 3px rgba(0, 0, 0, 0.2);
}

.settings-row input:focus {
    outline: none;
    border-color: var(--accent-primary);
    background: rgba(19, 22, 28, 0.8);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15), inset 0 1px 3px rgba(0, 0, 0, 0.15);
}

.settings-row small {
    color: var(--text-muted);
    font-size: 0.8125rem;
}

/* ============================================================================
   STATS GRID
   ============================================================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: linear-gradient(135deg, rgba(19, 22, 28, 0.7) 0%, rgba(33, 38, 47, 0.85) 100%);
    border: 1px solid rgba(91, 141, 239, 0.15);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    text-align: center;
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--accent-cyan) 0%, var(--accent-primary) 50%, var(--accent-purple) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

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

/* ============================================================================
   USER CELL
   ============================================================================ */
.user-cell { display: flex; flex-direction: column; gap: 0.125rem; }
.user-email { font-size: 0.875rem; color: var(--text-primary); }
.user-display-name { font-size: 0.75rem; color: var(--text-muted); }
.user-status { margin-top: 0.25rem; }
.user-roles { margin-top: 0.25rem; flex-wrap: wrap; }
.user-status .badge,
.user-roles .badge { font-size: 0.65rem; padding: 0.1rem 0.35rem; }

/* ============================================================================
   CONTENT COUNTS (stacked in table cell)
   ============================================================================ */
.content-counts { line-height: 1.4; }
.content-counts div { white-space: nowrap; font-size: 0.75rem; }
.content-counts small { display: inline-block; width: 4rem; color: var(--text-muted); font-size: 0.5rem; text-transform: uppercase; }

/* ============================================================================
   CREDITS CELL
   ============================================================================ */
.credits-cell { font-size: 0.8125rem; }
.credits-row { margin-bottom: 0.25rem; }

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

.credits-fill {
    height: 100%;
    border-radius: var(--radius-full);
    transition: width var(--transition-base);
    background: linear-gradient(90deg, var(--accent-teal), var(--accent-primary));
}

/* ============================================================================
   FILTER BANNER
   ============================================================================ */
.filter-banner {
    background: linear-gradient(135deg, rgba(91, 141, 239, 0.1) 0%, rgba(167, 139, 250, 0.05) 100%);
    border: 1px solid rgba(91, 141, 239, 0.25);
    border-radius: var(--radius-md);
    padding: 0.75rem 1.25rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    font-size: 0.9375rem;
    color: var(--text-secondary);
}

/* ============================================================================
   TAG INPUT (for benefits, product mappings, etc.)
   ============================================================================ */
.tag-input-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1.5px solid rgba(91, 141, 239, 0.2);
    border-radius: var(--radius-md);
    background: rgba(19, 22, 28, 0.5);
    min-height: 2.75rem;
    align-items: center;
}

.tag-input-container:focus-within {
    border-color: var(--accent-primary);
    box-shadow: 0 0 0 3px rgba(91, 141, 239, 0.15);
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.375rem;
    padding: 0.25rem 0.5rem;
    background: linear-gradient(135deg, rgba(91, 141, 239, 0.2), rgba(167, 139, 250, 0.2));
    border: 1px solid rgba(91, 141, 239, 0.3);
    border-radius: var(--radius-sm);
    font-size: 0.8125rem;
    color: var(--text-bright);
    white-space: nowrap;
}

.tag-remove {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 1rem;
    line-height: 1;
    padding: 0;
    margin-left: 0.125rem;
    transition: color var(--transition-fast);
}

.tag-remove:hover {
    color: var(--accent-rose);
}

.tag-input {
    flex: 1;
    min-width: 120px;
    border: none;
    background: transparent;
    color: var(--text-primary);
    font-size: 0.875rem;
    padding: 0.25rem;
    outline: none;
}

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