/* Исправления для уведомлений */
.notifications-container {
    position: fixed;
    right: 24px;
    top: 80px;
    width: 380px;
    max-height: 70vh;
    overflow-y: auto;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    display: none;
}

.notifications-container.show {
    display: block;
    animation: slideInRight 0.3s ease;
}

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

/* Исправления для таблиц в базе угроз */
.threats-table-container {
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    margin: 24px 0;
}

.threats-search {
    margin-bottom: 24px;
}

.search-filters {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.filter-tag {
    padding: 8px 16px;
    background: var(--bg-color);
    color: var(--text-secondary);
    border-radius: 20px;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.filter-tag:hover {
    background: var(--surface-color);
    color: var(--text-primary);
}

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

/* Исправления для панели результатов */
.results-panel {
    position: fixed;
    right: 0;
    top: 0;
    bottom: 0;
    width: 650px;
    background: var(--surface-color);
    border-left: 1px solid var(--border-color);
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.results-panel.hidden {
    transform: translateX(100%);
}

.results-panel:not(.hidden) {
    transform: translateX(0);
}

.results-header {
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--bg-color);
}

.results-content {
    flex: 1;
    overflow-y: auto;
    padding: 32px;
}

/* Улучшенный ввод URL */
.input-with-dropdown {
    position: relative;
}

.input-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--surface-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    margin-top: 4px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    display: none;
    z-index: 100;
}

.input-with-dropdown:focus-within .input-dropdown {
    display: block;
    animation: fadeIn 0.2s ease;
}

.dropdown-item {
    padding: 12px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    transition: background 0.2s ease;
    border-bottom: 1px solid var(--border-color);
}

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

.dropdown-item:hover {
    background: var(--bg-color);
}

/* Прогресс-бар сканирования */
.scan-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: linear-gradient(90deg, #10b981, #3b82f6, #8b5cf6);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 0 0 8px 8px;
}

/* Адаптивность */
@media (max-width: 1024px) {
    .results-panel {
        width: 500px;
    }
    
    .checks-overview {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .results-panel {
        width: 100%;
        border-left: none;
    }
    
    .results-summary {
        flex-direction: column;
        align-items: stretch;
        text-align: center;
    }
    
    .risk-score-card {
        min-width: auto;
    }
    
    .checks-overview {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .scan-meta {
        flex-direction: column;
        gap: 12px;
        align-items: center;
    }
    
    .results-actions {
        flex-direction: column;
    }
    
    .btn-primary, .btn-secondary, .btn-danger {
        width: 100%;
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .threats-table-container {
        overflow-x: auto;
    }
    
    .threats-table {
        min-width: 700px;
    }
    
    .history-table-container {
        overflow-x: auto;
    }
    
    .history-table {
        min-width: 600px;
    }
}
