* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    color: #1a1a1a;
    line-height: 1.6;
    overflow-x: hidden;
    max-width: 100vw;
}

.header {
    border-bottom: 1px solid #e0e0e0;
    padding: 0 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 64px;
    gap: 1rem;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-size: 1.5rem;
    font-weight: 600;
    color: #003a37;
}

.logo img {
    height: 40px;
    width: auto;
}

.nav-tabs {
    display: flex;
    gap: 1rem;
}

.nav-tab {
    padding: 0.5rem 1rem;
    cursor: pointer;
    color: #666;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
}

.nav-tab:hover {
    color: #003a37;
}

.nav-tab.active {
    color: #003a37;
    border-bottom-color: #003a37;
    font-weight: 500;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 1rem;
    flex-shrink: 0;
}

.search-bar {
    position: relative;
}

.search-bar input {
    width: 180px;
    padding: 0.5rem 1rem 0.5rem 2.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.9rem;
}

.search-bar input:focus {
    outline: none;
    border-color: #003a37;
}

.search-icon {
    position: absolute;
    left: 0.75rem;
    top: 50%;
    transform: translateY(-50%);
    color: #666;
    display: flex;
    align-items: center;
}

.notification-bell {
    position: relative;
    cursor: pointer;
    display: flex;
    align-items: center;
    padding: 0.5rem;
    transition: opacity 0.2s;
}

.notification-bell:hover {
    opacity: 0.7;
}

.notification-bell .icon-bell,
.notification-bell .bell-icon {
    width: 24px;
    height: 24px;
    flex-shrink: 0;
}

.notification-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: #003a37;
    color: white;
    font-size: 0.7rem;
    padding: 2px 6px;
    border-radius: 10px;
    font-weight: 600;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.avatar {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #003a37;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: 500;
}

.page-view {
    display: none;
}

.page-view.active {
    display: block;
}

.container {
    display: flex;
    height: calc(100vh - 64px);
}

.sidebar {
    width: 280px;
    border-right: 1px solid #e0e0e0;
    padding: 1.5rem;
    overflow-y: auto;
    position: relative;
}

.sidebar-content {
    padding-bottom: 80px;
}

.sidebar-footer {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 1rem 1.5rem;
    background: white;
    border-top: 1px solid #e0e0e0;
}

.filter-section {
    margin-bottom: 2rem;
}

.filter-title {
    font-size: 0.85rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-options {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.checkbox-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    cursor: pointer;
}

.checkbox-item input[type="checkbox"] {
    width: 16px;
    height: 16px;
    cursor: pointer;
    accent-color: #003a37;
}

.checkbox-item label {
    font-size: 0.9rem;
    cursor: pointer;
    color: #333;
}

.checkbox-item .count {
    margin-left: auto;
    font-size: 0.8rem;
    color: #999;
}

.date-range {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.date-range input {
    padding: 0.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 0.9rem;
}

.confidence-slider {
    margin-top: 0.5rem;
}

.confidence-slider input[type="range"] {
    width: 100%;
    accent-color: #003a37;
}

.slider-value {
    text-align: right;
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.25rem;
}

.apply-filters-btn {
    width: 100%;
    padding: 0.65rem;
    background: #003a37;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    font-size: 0.9rem;
}

.apply-filters-btn:hover {
    background: #00524e;
}

.main-content {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem 2rem;
}

.content-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.content-header h1 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #003a37;
}

.header-actions {
    display: flex;
    gap: 0.75rem;
}

.btn {
    padding: 0.5rem 1.25rem;
    border: 1px solid #003a37;
    background: white;
    color: #003a37;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s;
}

.btn:hover {
    background: #003a37;
    color: white;
}

.btn-primary {
    background: #003a37;
    color: white;
}

.btn-primary:hover {
    background: #00524e;
}

.btn-secondary {
    background: white;
    border: 1px solid #e0e0e0;
    color: #666;
}

.btn-secondary:hover {
    border-color: #003a37;
    color: #003a37;
    background: white;
}

.signal-grid {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.signal-card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.25rem;
    transition: all 0.2s;
    cursor: pointer;
}

.signal-card.hidden {
    display: none;
}

.signal-card:hover {
    border-color: #003a37;
    box-shadow: 0 2px 8px rgba(0, 58, 55, 0.1);
}

.signal-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 0.75rem;
}

.signal-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border: 1px solid #003a37;
    color: #003a37;
    font-size: 0.75rem;
    font-weight: 500;
    border-radius: 12px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.signal-meta {
    display: flex;
    align-items: center;
    gap: 1rem;
    font-size: 0.8rem;
    color: #666;
}

.signal-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.signal-summary {
    font-size: 0.95rem;
    color: #333;
    margin-bottom: 0.75rem;
    line-height: 1.5;
}

.signal-insight {
    display: flex;
    align-items: start;
    gap: 0.5rem;
    padding: 0.75rem;
    background: rgba(0, 58, 55, 0.03);
    border-left: 2px solid #003a37;
    font-size: 0.9rem;
    color: #003a37;
    margin-bottom: 0.75rem;
}

.signal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 0.75rem;
    border-top: 1px solid #f0f0f0;
}

.signal-source {
    font-size: 0.85rem;
    color: #666;
}

.signal-actions {
    display: flex;
    gap: 0.75rem;
}

.icon-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.25rem;
    color: #666;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.icon-btn:hover {
    opacity: 0.7;
}

.icon-btn .icon {
    width: 18px;
    height: 18px;
}

.icon-btn .icon-star {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/%3E%3C/svg%3E");
}

.icon-btn.bookmarked .icon-star,
.icon-btn .icon-star.active {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23003a37' stroke='%23003a37' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolygon points='12 2 15.09 8.26 22 9.27 17 14.14 18.18 21.02 12 17.77 5.82 21.02 7 14.14 2 9.27 8.91 8.26 12 2'/%3E%3C/svg%3E");
}

.confidence-bar {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: #666;
}

.confidence-bar-fill {
    width: 60px;
    height: 4px;
    background: #e0e0e0;
    border-radius: 2px;
    overflow: hidden;
}

.confidence-bar-value {
    height: 100%;
    background: #003a37;
    transition: width 0.3s;
}

.config-section {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.config-section-title {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 1rem;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    font-size: 0.9rem;
    font-weight: 500;
    color: #333;
    margin-bottom: 0.5rem;
}

.form-input {
    width: 100%;
    padding: 0.65rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.9rem;
}

.form-input:focus {
    outline: none;
    border-color: #003a37;
}

.form-textarea {
    width: 100%;
    padding: 0.65rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.9rem;
    min-height: 100px;
    resize: vertical;
}

.form-textarea:focus {
    outline: none;
    border-color: #003a37;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
}

.tag-input-container {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    padding: 0.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    min-height: 44px;
}

.tag {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.25rem 0.75rem;
    background: rgba(0, 58, 55, 0.1);
    border: 1px solid #003a37;
    color: #003a37;
    border-radius: 12px;
    font-size: 0.85rem;
}

.tag-remove {
    cursor: pointer;
    font-weight: bold;
}

.tag-input {
    border: none;
    outline: none;
    flex: 1;
    min-width: 120px;
    font-size: 0.9rem;
}

.source-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 1rem;
}

.source-table th {
    text-align: left;
    padding: 0.75rem;
    border-bottom: 2px solid #e0e0e0;
    font-size: 0.85rem;
    font-weight: 600;
    color: #003a37;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.source-table td {
    padding: 0.75rem;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.9rem;
}

.source-table tr:hover {
    background: rgba(0, 58, 55, 0.02);
}

.status-badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.75rem;
    font-weight: 500;
}

.status-active {
    background: rgba(0, 150, 100, 0.1);
    color: #009664;
    border: 1px solid #009664;
}

.status-failed {
    background: rgba(200, 50, 50, 0.1);
    color: #c83232;
    border: 1px solid #c83232;
}

.notification-card {
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.25rem;
    margin-bottom: 1rem;
}

.notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.notification-title {
    font-size: 1rem;
    font-weight: 600;
    color: #333;
}

.toggle-switch {
    position: relative;
    width: 48px;
    height: 24px;
}

.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.toggle-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.3s;
    border-radius: 24px;
}

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.3s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: #003a37;
}

input:checked + .toggle-slider:before {
    transform: translateX(24px);
}

.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal.active {
    display: flex;
}

.modal-content {
    background: white;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    border-radius: 12px;
    padding: 2rem;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1.5rem;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: #666;
    line-height: 1;
}

.modal-badge {
    margin-bottom: 1rem;
}

.modal-title {
    font-size: 1.75rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 1rem;
}

.modal-meta {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
    color: #666;
    margin-bottom: 1.5rem;
    padding-bottom: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.modal-section {
    margin-bottom: 1.5rem;
}

.modal-section-title {
    font-size: 0.9rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.modal-text {
    font-size: 0.95rem;
    line-height: 1.7;
    color: #333;
}

.extracted-data {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.data-item {
    padding: 0.75rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
}

.data-label {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.data-value {
    font-size: 0.95rem;
    font-weight: 500;
    color: #1a1a1a;
}

.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: #999;
}

.empty-state-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.3;
}

.workspace-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.95rem;
    background: white;
    transition: all 0.2s;
}

.workspace-selector:hover {
    border-color: #003a37;
    background: rgba(0, 58, 55, 0.02);
}

.success-message {
    position: fixed;
    top: 80px;
    right: 2rem;
    background: #003a37;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 1001;
    display: none;
    animation: slideIn 0.3s ease-out;
}

.success-message.show {
    display: block;
}

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

.notification-panel {
    position: fixed;
    top: 64px;
    right: -400px;
    width: 400px;
    height: calc(100vh - 64px);
    background: white;
    box-shadow: -4px 0 20px rgba(0, 0, 0, 0.15);
    z-index: 1002;
    transition: right 0.3s ease-out;
    display: flex;
    flex-direction: column;
}

.notification-panel.active {
    right: 0;
}

.notification-panel-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    border-bottom: 1px solid #e0e0e0;
}

.notification-panel-header h3 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #003a37;
    margin: 0;
}

.close-notification-btn {
    background: none;
    border: none;
    font-size: 1.75rem;
    cursor: pointer;
    color: #666;
    line-height: 1;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s;
}

.close-notification-btn:hover {
    background: #f0f0f0;
    color: #003a37;
}

.notification-panel-content {
    flex: 1;
    overflow-y: auto;
    padding: 0;
}

.notification-item {
    display: flex;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: background 0.2s;
    position: relative;
}

.notification-item:hover {
    background: rgba(0, 58, 55, 0.02);
}

.notification-item.unread {
    background: rgba(0, 58, 55, 0.03);
}

.notification-item.unread::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: #003a37;
}

.notification-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 58, 55, 0.1);
    border-radius: 8px;
}

.notification-icon .icon {
    width: 24px;
    height: 24px;
}

.notification-body {
    flex: 1;
    min-width: 0;
}

.notification-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.25rem;
}

.notification-text {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.notification-time {
    font-size: 0.75rem;
    color: #999;
}

.notification-dot {
    width: 8px;
    height: 8px;
    background: #003a37;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 0.5rem;
}

.notification-item:not(.unread) .notification-dot {
    display: none;
}

.notification-panel-footer {
    display: flex;
    gap: 1rem;
    padding: 1rem 1.5rem;
    border-top: 1px solid #e0e0e0;
    background: #fafafa;
}

.btn-text {
    background: none;
    border: none;
    color: #003a37;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    padding: 0.5rem;
    transition: opacity 0.2s;
}

.btn-text:hover {
    opacity: 0.7;
}

.notification-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 1001;
    display: none;
}

.notification-overlay.active {
    display: block;
}

.dashboard-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.stat-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    display: flex;
    gap: 1rem;
    align-items: start;
}

.stat-icon {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    flex-shrink: 0;
}

.stat-content {
    flex: 1;
}

.stat-value {
    font-size: 1.75rem;
    font-weight: 700;
    color: #003a37;
    line-height: 1;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.25rem;
}

.stat-change {
    font-size: 0.8rem;
    font-weight: 500;
}

.stat-change.positive {
    color: #00a396;
}

.stat-change.neutral {
    color: #666;
}

.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.dashboard-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
}

.dashboard-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid #f0f0f0;
}

.dashboard-card-header h3 {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin: 0;
}

.activity-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.activity-item {
    display: flex;
    gap: 1rem;
    padding: 1rem;
    background: #fafafa;
    border-radius: 6px;
    align-items: start;
}

.activity-icon {
    width: 40px;
    height: 40px;
    background: white;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    flex-shrink: 0;
}

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

.activity-title {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1a1a1a;
    margin-bottom: 0.5rem;
}

.activity-meta {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    font-size: 0.8rem;
    color: #666;
}

.activity-time {
    color: #999;
    margin-left: auto;
}

.badge-sm {
    background: rgba(0, 58, 55, 0.1);
    color: #003a37;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.confidence-indicator {
    font-size: 0.85rem;
    font-weight: 600;
    padding: 0.25rem 0.75rem;
    border-radius: 4px;
    flex-shrink: 0;
}

.confidence-indicator.high {
    background: rgba(0, 163, 150, 0.1);
    color: #00a396;
}

.confidence-indicator.medium {
    background: rgba(255, 159, 64, 0.1);
    color: #ff9f40;
}

.breakdown-item {
    margin-bottom: 1rem;
}

.breakdown-bar {
    height: 32px;
    border-radius: 4px;
    margin-bottom: 0.25rem;
}

.breakdown-label {
    display: flex;
    justify-content: space-between;
    font-size: 0.85rem;
    color: #666;
    padding: 0 0.25rem;
}

.breakdown-label span:last-child {
    font-weight: 600;
    color: #003a37;
}

.opportunities-table {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.opp-row {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 0.75fr 0.75fr 0.75fr;
    gap: 1rem;
    align-items: center;
    padding: 0.75rem;
    border-radius: 4px;
}

.opp-row.opp-header {
    font-size: 0.8rem;
    font-weight: 600;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e0e0e0;
}

.opp-row:not(.opp-header) {
    background: #fafafa;
}

.opp-title {
    font-size: 0.9rem;
    font-weight: 500;
    color: #1a1a1a;
}

.opp-value {
    font-weight: 600;
    color: #003a37;
}

.confidence-badge {
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
}

.confidence-badge.high {
    background: rgba(0, 163, 150, 0.1);
    color: #00a396;
}

.confidence-badge.medium {
    background: rgba(255, 159, 64, 0.1);
    color: #ff9f40;
}

.btn-mini {
    padding: 0.35rem 0.75rem;
    background: white;
    border: 1px solid #003a37;
    color: #003a37;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-mini:hover {
    background: #003a37;
    color: white;
}

.workspace-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.workspace-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.workspace-item:hover {
    border-color: #003a37;
    background: #f8f9fa;
}

.workspace-item.active {
    border-color: #003a37;
    background: rgba(0, 58, 55, 0.05);
}

.workspace-icon {
    font-size: 2rem;
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f0f0f0;
    border-radius: 8px;
    flex-shrink: 0;
}

.workspace-details {
    flex: 1;
}

.workspace-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.25rem;
}

.workspace-meta {
    font-size: 0.85rem;
    color: #666;
}

.workspace-badge {
    padding: 0.25rem 0.75rem;
    background: #00a396;
    color: white;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
}

.icon-picker-btn {
    width: 48px;
    height: 48px;
    font-size: 1.5rem;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: white;
    cursor: pointer;
    transition: all 0.2s;
}

.icon-picker-btn:hover {
    border-color: #003a37;
}

.icon-picker-btn.active {
    border-color: #003a37;
    background: rgba(0, 58, 55, 0.05);
}

.workspace-selector {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: #f8f9fa;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.workspace-selector:hover {
    background: #e9ecef;
}

.workspace-selector-icon {
    font-size: 1.25rem;
}

.workspace-selector-name {
    font-weight: 500;
    color: #003a37;
}

.signal-type-card {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.2s;
}

.signal-type-card.selected {
    border-color: #003a37;
    background: rgba(0, 58, 55, 0.02);
}

.signal-type-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 1rem;
}

.signal-type-info {
    flex: 1;
}

.signal-type-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.25rem;
}

.signal-type-description {
    font-size: 0.9rem;
    color: #666;
}

.signal-type-toggle {
    flex-shrink: 0;
}

.nl-input-container {
    background: #f8f9fa;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
}

.nl-input-label {
    font-size: 0.9rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.5rem;
}

.nl-textarea {
    width: 100%;
    min-height: 120px;
    padding: 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    font-size: 0.95rem;
    font-family: inherit;
    resize: vertical;
}

.nl-textarea:focus {
    outline: none;
    border-color: #003a37;
}

.nl-examples {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid #e0e0e0;
}

.nl-examples-title {
    font-size: 0.8rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.nl-example {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 4px;
    font-size: 0.85rem;
    color: #666;
    margin-right: 0.5rem;
    margin-bottom: 0.5rem;
    cursor: pointer;
    transition: all 0.2s;
}

.nl-example:hover {
    border-color: #003a37;
    color: #003a37;
}

.signals-list-container {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.signal-list-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: white;
}

.signal-list-icon {
    width: 40px;
    height: 40px;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 58, 55, 0.1);
    flex-shrink: 0;
}

.signal-list-details {
    flex: 1;
}

.signal-list-name {
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.25rem;
}

.signal-list-meta {
    font-size: 0.85rem;
    color: #666;
}

.signal-list-actions {
    display: flex;
    gap: 0.5rem;
}

.campaign-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.campaign-card {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: white;
    transition: all 0.2s;
}

.campaign-card:hover {
    border-color: #003a37;
}

.campaign-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem;
    cursor: pointer;
}

.campaign-info {
    flex: 1;
}

.campaign-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.25rem;
}

.campaign-meta {
    font-size: 0.85rem;
    color: #666;
}

.campaign-expand {
    color: #666;
    transition: transform 0.2s;
}

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

.campaign-details {
    padding: 0 1.5rem 1.5rem 1.5rem;
    border-top: 1px solid #e0e0e0;
}

.detail-row {
    display: flex;
    gap: 1rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    font-weight: 600;
    color: #003a37;
    min-width: 120px;
    flex-shrink: 0;
}

.geo-tree {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.geo-country {
    border: 1px solid #e0e0e0;
    border-radius: 6px;
    padding: 0.75rem;
}

.geo-expand {
    display: inline-block;
    width: 16px;
    cursor: pointer;
    transition: transform 0.2s;
    user-select: none;
}

.geo-expand.expanded {
    transform: rotate(90deg);
}

.geo-states {
    margin-left: 2rem;
    margin-top: 0.5rem;
    padding-left: 1rem;
    border-left: 2px solid #e0e0e0;
}

.geo-state {
    margin: 0.25rem 0;
}

.tabs-container {
    margin-bottom: 2rem;
    border-bottom: 2px solid #e0e0e0;
}

.tabs {
    display: flex;
    gap: 2rem;
}

.tab {
    padding: 1rem 0;
    font-weight: 500;
    color: #666;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    margin-bottom: -2px;
    transition: all 0.2s;
}

.tab:hover {
    color: #003a37;
}

.tab.active {
    color: #003a37;
    border-bottom-color: #003a37;
}

.source-tab-content {
    display: none;
}

.source-tab-content.active {
    display: block;
}

.source-library-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
}

.library-source-card {
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    padding: 1.5rem;
    background: white;
    transition: all 0.2s;
}

.library-source-card:hover {
    border-color: #003a37;
    box-shadow: 0 4px 12px rgba(0, 58, 55, 0.1);
}

.library-source-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.library-source-icon {
    font-size: 2rem;
}

.library-source-name {
    font-size: 1.1rem;
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.5rem;
}

.library-source-description {
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
    margin-bottom: 0.75rem;
}

.library-source-meta {
    font-size: 0.8rem;
    color: #999;
}

.request-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.request-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    background: white;
}

.request-icon {
    font-size: 2rem;
    flex-shrink: 0;
}

.request-details {
    flex: 1;
}

.request-name {
    font-weight: 600;
    color: #003a37;
    margin-bottom: 0.25rem;
}

.request-meta {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 0.5rem;
}

.request-url {
    font-size: 0.85rem;
    color: #3b82f6;
    font-family: monospace;
}

@media (max-width: 768px) {
    .sidebar {
        display: none;
    }
    
    .search-bar input {
        width: 200px;
    }

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

    .extracted-data {
        grid-template-columns: 1fr;
    }
    
    .notification-panel {
        width: 100%;
        right: -100%;
    }
}

.priority-source {
    border: 2px solid #f57c00 !important;
    position: relative;
}

.priority-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #f57c00;
    color: white;
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 11px;
    font-weight: 600;
    z-index: 1;
}

.badge-company {
    background: #e8f4f8;
    color: #003a37;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 11px;
    margin-right: 6px;
    font-weight: 600;
}

.company-source-row {
    background: #f8fcfc;
}

.tags-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 12px;
    min-height: 36px;
    padding: 8px;
    background: #f9f9f9;
    border-radius: 6px;
}

.tag-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #003a37;
    color: white;
    padding: 4px 10px;
    border-radius: 16px;
    font-size: 13px;
    font-weight: 500;
}

.tag-remove {
    background: none;
    border: none;
    color: white;
    cursor: pointer;
    font-size: 16px;
    padding: 0;
    margin-left: 4px;
    opacity: 0.8;
}

.tag-remove:hover {
    opacity: 1;
}

.tag-input-group {
    display: flex;
    gap: 8px;
}

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

.bookmark-menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    margin-top: 8px;
    z-index: 1000;
}

.bookmark-menu-header {
    padding: 10px 14px;
    font-size: 12px;
    font-weight: 600;
    color: #666;
    border-bottom: 1px solid #eee;
}

.bookmark-menu button {
    width: 100%;
    text-align: left;
    padding: 10px 14px;
    border: none;
    background: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
}

.bookmark-menu button:hover {
    background: #f5f5f5;
}

.bookmark-menu button:first-of-type {
    border-radius: 8px 8px 0 0;
}

.bookmark-menu button:last-of-type {
    border-radius: 0 0 8px 8px;
}

.bookmark-category-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    color: white;
    z-index: 10;
}

.bookmark-category-badge.action-required {
    background: #d32f2f;
}

.bookmark-category-badge.high-priority {
    background: #f57c00;
}

.bookmark-category-badge.review-later {
    background: #1976d2;
}

.bookmark-category-badge.research {
    background: #7b1fa2;
}

.bookmark-category-badge.uncategorized {
    background: #757575;
}

.category-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 8px 16px;
    border: 1px solid #ddd;
    background: white;
    border-radius: 20px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    transition: all 0.2s;
}

.tab-btn:hover {
    background: #f5f5f5;
}

.tab-btn.active {
    background: #003a37;
    color: white;
    border-color: #003a37;
}

.tab-btn .count {
    background: rgba(0,0,0,0.1);
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
    min-width: 20px;
    text-align: center;
}

.data-lineage-section {
    background: #f8fafb;
    padding: 20px;
    border-radius: 8px;
}

.lineage-subtitle {
    color: #666;
    font-size: 14px;
    margin-top: -8px;
    margin-bottom: 20px;
}

.lineage-steps {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.lineage-step {
    display: flex;
    gap: 16px;
    background: white;
    padding: 16px;
    border-radius: 8px;
    border-left: 3px solid #003a37;
}

.step-number {
    width: 32px;
    height: 32px;
    background: #003a37;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
    flex-shrink: 0;
    font-size: 14px;
}

.step-content {
    flex: 1;
}

.step-content h4 {
    margin: 0 0 8px 0;
    color: #003a37;
    font-size: 15px;
}

.step-content p {
    margin: 4px 0;
    font-size: 14px;
    line-height: 1.5;
}

.reasoning {
    color: #555;
    font-style: italic;
    background: #f5f5f5;
    padding: 10px;
    border-radius: 6px;
    margin-top: 8px;
}

.source-link {
    display: inline-block;
    margin-top: 8px;
    color: #003a37;
    font-weight: 500;
    text-decoration: none;
    font-size: 14px;
}

.source-link:hover {
    text-decoration: underline;
}

.timestamp {
    font-size: 12px;
    color: #888;
    margin-top: 6px;
}

.confidence-badge {
    display: inline-block;
    background: #e8f5e9;
    color: #2e7d32;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    margin-top: 8px;
}

.campaign-badge {
    display: inline-block;
    background: #003a37;
    color: white;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 12px;
    margin-right: 6px;
    margin-top: 4px;
}

.technical-details {
    border-top: 1px solid #ddd;
    padding-top: 16px;
}

.technical-details summary {
    cursor: pointer;
    color: #003a37;
    font-weight: 500;
    font-size: 14px;
    user-select: none;
}

.technical-details summary:hover {
    text-decoration: underline;
}

.tech-info {
    margin-top: 12px;
    padding: 12px;
    background: white;
    border-radius: 6px;
    font-size: 13px;
}

.tech-info code {
    background: #f0f0f0;
    padding: 2px 6px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 12px;
}

.tech-info ul {
    margin: 8px 0;
    padding-left: 20px;
}

.tech-info li {
    margin: 4px 0;
}

.tech-info p {
    margin: 8px 0;
}
