/* Основные стили */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #f5f7fa;
    min-height: 100vh;
    color: #333;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Заголовок */
.header {
    background: white;
    border-radius: 12px;
    padding: 20px 30px;
    margin-bottom: 30px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    display: flex;
    justify-content: space-between;
    align-items: center;
    border: 1px solid #e1e5e9;
    flex-wrap: wrap;
    gap: 15px;
}

.header h1 {
    color: #2d3748;
    font-size: 2rem;
    font-weight: 600;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
    font-size: 0.9rem;
    color: #4a5568;
    font-weight: 500;
}

.user-info span {
    color: #4a5568;
    font-weight: 500;
}

.nav {
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.nav-btn {
    padding: 8px 16px !important;
    min-height: 36px !important;
    font-size: 0.85rem !important;
    border-radius: 6px !important;
    font-weight: 500;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.nav-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* Дашборд */
.dashboard {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

/* Статистика */
.stats-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e1e5e9;
}

.asn-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.asn-info-card {
    background: linear-gradient(135deg, rgba(226, 232, 240, 0.25), rgba(226, 232, 240, 0.08));
    border: 1px solid rgba(203, 213, 225, 0.6);
    border-radius: 12px;
    padding: 18px 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.asn-info-card h3 {
    margin: 0;
    color: #1e293b;
    font-size: 1.1rem;
    font-weight: 600;
}

.asn-info-card ul {
    margin: 0;
    padding-left: 20px;
    color: #334155;
}

.asn-info-card li {
    margin-bottom: 6px;
}

.asn-info-note {
    margin: 0;
    font-size: 0.9rem;
    color: #475569;
}

.asn-manager-toolbar {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
    padding: 16px;
    background: rgba(248, 250, 252, 0.9);
    border: 1px solid rgba(226, 232, 240, 0.9);
    border-radius: 12px;
}

.asn-manager-toolbar .btn {
    flex: 1 1 220px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.asn-table-wrapper {
    margin-top: 18px;
    border-radius: 12px;
    overflow: hidden;
}

.asn-table {
    width: 100%;
    border-collapse: collapse;
}

.asn-table th,
.asn-table td {
    padding: 14px 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.asn-table th {
    background: #1e293b;
    color: #f8fafc;
    text-transform: uppercase;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
}

.asn-table tbody tr:nth-child(odd) {
    background: #ffffff;
}

.asn-table tbody tr:hover {
    background: rgba(248, 250, 252, 0.85);
}

.asn-table td:last-child {
    text-align: right;
}

.asn-apply-summary {
    background: rgba(236, 252, 203, 0.45);
    border: 1px solid rgba(202, 230, 138, 0.9);
    border-radius: 10px;
    padding: 18px;
    color: #365314;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.asn-apply-summary p {
    margin: 0;
    line-height: 1.45;
}

.asn-apply-summary .checkbox-label {
    font-weight: 500;
}

.stats-section h2 {
    color: #2d3748;
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 600;
}

/* Таблица статистики */
.stats-table-container {
    overflow-x: auto;
}

.stats-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.stats-table thead {
    background: #f8f9fa;
}

.stats-table th {
    padding: 15px 20px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
    font-size: 0.9em;
}

.stats-table td {
    padding: 15px 20px;
    vertical-align: middle;
    border-bottom: 1px solid #f1f3f4;
    font-size: 0.95em;
}

.stats-table tbody tr:hover {
    background-color: #f8f9fa;
}

.stats-table tbody tr:last-child td {
    border-bottom: none;
}

/* Колонки таблицы статистики */
.stats-table th:first-child,
.stats-table td:first-child {
    width: 30%;
    font-weight: 500;
}

.stats-table th:nth-child(2),
.stats-table td:nth-child(2),
.stats-table th:nth-child(3),
.stats-table td:nth-child(3) {
    width: 20%;
    text-align: center;
}

.stats-table th:last-child,
.stats-table td:last-child {
    width: 30%;
    text-align: center;
    color: #2c3e50;
}

.resource-icon {
    font-size: 1.1em;
    margin-right: 8px;
}

/* Адаптивность для статистики */
@media (max-width: 768px) {
    .stats-table {
        font-size: 0.85em;
    }
    
    .stats-table th,
    .stats-table td {
        padding: 10px 8px;
    }
    
    .stats-table th:nth-child(2),
    .stats-table td:nth-child(2) {
        display: none; /* Скрываем пользовательские на мобильных */
    }
}

/* Управление файлами */
.files-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e1e5e9;
}

.files-section h2 {
    color: #2d3748;
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 600;
}

.files-actions {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
}

/* Источники */
.sources-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e1e5e9;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.section-header h2 {
    color: #2d3748;
    font-size: 1.5rem;
    font-weight: 600;
    margin: 0;
}

.header-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Таблица */
.table-container {
    overflow-x: auto;
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    border: 1px solid #e1e5e9;
}

.sources-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 10px;
    overflow: hidden;
}

.sources-table thead {
    background: #4a5568;
    color: white;
}

.sources-table th,
.sources-table td {
    padding: 15px 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.sources-table th {
    font-weight: 600;
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Выравнивание заголовков таблицы источников под содержимое */
.sources-table th:nth-child(1) { /* № */
    text-align: center;
}

.sources-table th:nth-child(2) { /* Название */
    text-align: left;
}

.sources-table th:nth-child(3) { /* URL */
    text-align: left;
}

.sources-table th:nth-child(4) { /* Домены */
    text-align: center;
}

.sources-table th:nth-child(5) { /* IP */
    text-align: center;
}

.sources-table th:nth-child(6) { /* Дата добавления */
    text-align: left;
}

.sources-table th:nth-child(7) { /* Последний доступ */
    text-align: left;
}

.sources-table th:nth-child(8) { /* Статус */
    text-align: left;
}

.sources-table th:nth-child(9) { /* Действия */
    text-align: center;
}

.sources-table tbody tr {
    transition: background-color 0.2s ease;
}

.sources-table tbody tr:hover {
    background-color: #f7fafc;
}

.url-column {
    max-width: 200px;
}

.url-link {
    display: inline-block;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    text-decoration: none;
    position: relative;
}

.url-link:hover {
    text-decoration: underline;
}

/* Tooltip для полного URL при наведении */
.url-link:hover::after {
    content: attr(title);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #2d3748;
    color: white;
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    white-space: nowrap;
    z-index: 1000;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    margin-bottom: 5px;
}

.url-link:hover::before {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: #2d3748;
    z-index: 1000;
}

.url-column span {
    display: inline-block;
    max-width: 100%;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    cursor: help;
}

.status-column {
    font-size: 0.9rem;
    max-width: 200px;
}

.actions-column {
    white-space: nowrap;
}

/* Выравнивание содержимого ячеек в таблице источников */
.sources-table td:nth-child(1) { /* № */
    text-align: center;
}

.sources-table td:nth-child(4) { /* Домены */
    text-align: center;
}

.sources-table td:nth-child(5) { /* IP */
    text-align: center;
}

.sources-table td:nth-child(9) { /* Действия */
    text-align: center;
}

/* Кнопки */
.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s ease;
    min-height: 40px;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: #4299e1;
    color: white;
}

.btn-primary:hover {
    background: #3182ce;
}

.btn-success {
    background: #48bb78;
    color: white;
}

.btn-success:hover {
    background: #38a169;
}

.btn-warning {
    background: #ed8936;
    color: white;
}

.btn-warning:hover {
    background: #dd6b20;
}

.btn-danger {
    background: #f56565;
    color: white;
}

.btn-danger:hover {
    background: #e53e3e;
}

.btn-secondary {
    background: #a0aec0;
    color: white;
}

.btn-secondary:hover {
    background: #718096;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.8rem;
    min-height: 32px;
}

/* Модальные окна */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 1000;
    padding: 40px 20px;
    overflow-y: auto;
    background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
    background: #fff;
    margin: auto;
    padding: 32px 36px;
    border-radius: 16px;
    width: min(95%, 640px);
    max-height: calc(100vh - 80px);
    position: relative;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
    animation: modalSlideIn 0.28s ease;
    border: 1px solid rgba(226, 232, 240, 0.8);
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow: hidden;
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    position: relative;
}

.modal-header h2 {
    margin: 0;
}

.modal-large {
    width: min(96%, 860px);
}

.modal-content .modal-body {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 18px;
    overflow-y: auto;
    padding-right: 6px;
}

.modal-content .modal-body::-webkit-scrollbar {
    width: 8px;
}

.modal-content .modal-body::-webkit-scrollbar-thumb {
    background: rgba(148, 163, 184, 0.6);
    border-radius: 4px;
}

.modal-content .modal-body::-webkit-scrollbar-thumb:hover {
    background: rgba(100, 116, 139, 0.75);
}

.modal-content .form-actions {
    margin-top: 12px;
    padding-top: 16px;
    justify-content: flex-end;
    gap: 12px;
    border-top: 1px solid rgba(226, 232, 240, 0.9);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(255, 255, 255, 0.92) 45%, #fff 100%);
    position: sticky;
    bottom: -1px;
}

#createListModal .modal-content {
    width: min(96%, 740px);
    padding: 36px 42px;
    gap: 22px;
}

#createListModal .help-text {
    margin-bottom: 18px;
    border-radius: 10px;
    background: linear-gradient(135deg, rgba(237, 248, 255, 0.95), rgba(226, 241, 255, 0.95));
    border-color: rgba(190, 227, 248, 0.8);
}

#createListModal textarea,
#listEditorModal textarea,
#addToListModal textarea,
#asnResolveModal textarea,
#asnEditorModal textarea {
    min-height: 220px;
    font-family: 'JetBrains Mono', 'Fira Code', 'Courier New', monospace;
    font-size: 0.92rem;
    line-height: 1.5;
    background: #f8fafc;
    border: 1px solid rgba(203, 213, 225, 0.9);
    box-shadow: inset 0 1px 3px rgba(148, 163, 184, 0.15);
    color: #1f2937;
}

#createListModal textarea::placeholder,
#listEditorModal textarea::placeholder,
#addToListModal textarea::placeholder,
#asnResolveModal textarea::placeholder,
#asnEditorModal textarea::placeholder {
    color: #94a3b8;
    opacity: 0.85;
}

#listEditorModal .modal-content {
    width: min(96%, 900px);
    max-height: calc(100vh - 80px);
    padding: 36px 44px 32px;
}

#listEditorModal .modal-body {
    flex: 1;
}

#listEditorModal .form-actions {
    background: linear-gradient(180deg, rgba(255, 255, 255, 0) 0%, rgba(248, 250, 252, 0.96) 50%, #fff 100%);
}


/* Стили для textarea в модальном окне */
#listEditorContent {
    width: 100%;
    padding: 18px;
    border-radius: 10px;
    font-size: 0.95rem;
    line-height: 1.55;
    resize: vertical;
    background: #f8fafc;
    border: 1px solid rgba(203, 213, 225, 0.9);
    box-shadow: inset 0 1px 2px rgba(148, 163, 184, 0.12);
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.modal-content h2 {
    color: #2d3748;
    margin-bottom: 20px;
    font-size: 1.4rem;
    font-weight: 600;
}

.close {
    position: absolute;
    right: 20px;
    top: 20px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    color: #a0aec0;
    transition: color 0.2s ease;
}

.close:hover {
    color: #e53e3e;
}

/* Формы */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: #2d3748;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.9rem;
    transition: border-color 0.2s ease;
    resize: vertical;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #4299e1;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

.form-actions {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 25px;
    flex-wrap: wrap;
}

/* Специальные элементы */

.file-actions {
    display: flex;
    gap: 10px;
    margin-bottom: 15px;
    flex-wrap: wrap;
}

.help-text {
    background: #ebf8ff;
    border: 1px solid #bee3f8;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.help-text p {
    margin-bottom: 10px;
    color: #2d3748;
}

.help-text ul {
    margin-left: 20px;
}

.help-text li {
    margin-bottom: 5px;
    color: #4a5568;
}

.warning-text {
    background: #fed7d7;
    border: 1px solid #feb2b2;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.warning-text p {
    margin-bottom: 10px;
    color: #c53030;
}

.checkbox-label {
    display: flex !important;
    align-items: center;
    gap: 10px;
    cursor: pointer;
    padding: 10px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.checkbox-label:hover {
    background-color: #f7fafc;
}

.checkbox-label input[type="checkbox"] {
    width: auto !important;
    margin: 0;
}

/* Логин */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 20px;
}

.login-card {
    background: white;
    border-radius: 12px;
    padding: 40px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.15);
    width: 100%;
    max-width: 400px;
    border: 1px solid #e1e5e9;
}

.login-card h2 {
    text-align: center;
    color: #2d3748;
    margin-bottom: 30px;
    font-size: 1.8rem;
    font-weight: 600;
}

.login-card .form-group {
    margin-bottom: 25px;
}

.login-card .btn {
    width: 100%;
    margin-top: 10px;
}

/* Секция управления списками */
.lists-section {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 20px;
}

/* Таблица списков */
.lists-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    table-layout: fixed;
}

.lists-table thead {
    background: #f8f9fa;
}

.lists-table th {
    padding: 12px 8px;
    text-align: left;
    font-weight: 600;
    color: #495057;
    border-bottom: 2px solid #dee2e6;
    font-size: 0.9em;
}

/* Выравнивание заголовков под содержимое */
.lists-table th:nth-child(1) { /* Статус */
    text-align: center;
}

.lists-table th:nth-child(2) { /* Название */
    text-align: left;
}

.lists-table th:nth-child(3) { /* Описание */
    text-align: left;
}

.lists-table th:nth-child(4) { /* Домены */
    text-align: center;
}

.lists-table th:nth-child(5) { /* Обновлён */
    text-align: left;
}

.lists-table th:nth-child(6) { /* Действия */
    text-align: center;
}

.lists-table td {
    padding: 12px 8px;
    vertical-align: middle;
    border-bottom: 1px solid #dee2e6;
}

.lists-table tbody tr {
    transition: background-color 0.2s ease;
}

.lists-table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Колонки таблицы списков */
.lists-table .status-column {
    width: 80px;
    text-align: center;
}

.lists-table .name-column {
    width: 200px;
    font-weight: 500;
}

.lists-table .description-column {
    width: auto;
    min-width: 280px;
    color: #6c757d;
    font-style: italic;
}

.lists-table .count-column {
    width: 100px;
    text-align: center;
    font-weight: 500;
}

.lists-table .updated-column {
    width: 140px;
    font-size: 0.85em;
    color: #6c757d;
}

.lists-table .actions-column {
    width: 150px;
    text-align: center;
    white-space: nowrap;
}

/* Кнопки действий в таблице */
.action-buttons {
    display: flex;
    gap: 4px;
    flex-wrap: nowrap;
    justify-content: center;
    align-items: center;
}

.action-buttons .btn {
    font-size: 0.8em;
    padding: 4px 6px;
    min-width: 28px;
    border-radius: 4px;
    white-space: nowrap;
}

/* Переключатель включения/выключения списка */
.switch {
    position: relative;
    display: inline-block;
    width: 44px;
    height: 20px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: .3s;
    border-radius: 20px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 2px;
    bottom: 2px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: #28a745;
}

input:checked + .slider:before {
    transform: translateX(24px);
}

.empty-state {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

.empty-state p {
    margin: 5px 0;
}

/* Стили для модальных окон списков */

#listEditorHelp {
    margin: 0;
    padding-left: 20px;
}

#listEditorHelp li {
    margin: 5px 0;
}

/* Адаптивность для мобильных */
@media (max-width: 1024px) {
    .lists-table {
        font-size: 0.9em;
    }
    
    .description-column {
        max-width: 200px;
    }
    
    .action-buttons .btn {
        font-size: 0.7em;
        padding: 3px 5px;
        min-width: 24px;
    }
}

@media (max-width: 768px) {
    .lists-table {
        font-size: 0.8em;
    }
    
    .lists-table th,
    .lists-table td {
        padding: 8px 4px;
    }
    
    .description-column {
        display: none; /* Скрываем описание на малых экранах */
    }
    
    .updated-column {
        display: none; /* Скрываем дату обновления на малых экранах */
    }
    
    .action-buttons {
        flex-direction: column;
        gap: 2px;
    }
    
    .action-buttons .btn {
        font-size: 0.7em;
        padding: 2px 4px;
        width: 100%;
    }
    
    .actions-column {
        width: 60px;
    }
}
@media (max-width: 768px) {
    .container {
        padding: 15px;
    }
    
    .header {
        flex-direction: column;
        gap: 15px;
        text-align: center;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .section-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .files-actions,
    .header-actions {
        justify-content: center;
    }
    
    .sources-table {
        font-size: 0.8rem;
    }
    
    .sources-table th,
    .sources-table td {
        padding: 10px 8px;
    }
    
    .modal-content {
        margin: 10% auto;
        padding: 20px;
        width: 95%;
    }
    
    .form-actions {
        justify-content: center;
    }
} 

/* Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #4299e1;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
} 

/* Settings sections */
.settings-section {
    margin-bottom: 30px;
    padding: 20px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    background: #f8f9fa;
}

.settings-section h3 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 1.2rem;
    font-weight: 600;
    border-bottom: 2px solid #e2e8f0;
    padding-bottom: 8px;
}

.scheduler-status {
    display: grid;
    gap: 15px;
}

.status-badge {
    padding: 4px 12px;
    border-radius: 4px;
    font-weight: 500;
    font-size: 0.9rem;
}

.status-badge.active {
    background: #c6f6d5;
    color: #22543d;
}

.status-badge.inactive {
    background: #fed7d7;
    color: #c53030;
}

.status-badge.loading {
    background: #bee3f8;
    color: #2c5282;
}

.form-group select {
    width: 200px;
    padding: 8px 12px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
}

.form-group select:focus {
    outline: none;
    border-color: #4299e1;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

/* Scheduler log styles */
.loading-text {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 20px;
}

.status-cell {
    text-align: center;
    padding: 4px 8px;
}

.log-status {
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 500;
    text-transform: uppercase;
}

.log-status.success {
    background: #c6f6d5;
    color: #22543d;
}

.log-status.error {
    background: #fed7d7;
    color: #c53030;
}

.log-status.warning {
    background: #fef5e7;
    color: #dd6b20;
}

.log-status.info {
    background: #bee3f8;
    color: #2c5282;
}

.log-details {
    max-width: 300px;
    word-wrap: break-word;
    font-size: 0.9rem;
}

.log-timestamp {
    font-family: monospace;
    font-size: 0.85rem;
    white-space: nowrap;
} 

/* Поиск в модальном окне */
.search-container {
    margin-bottom: 15px;
    display: flex;
    gap: 10px;
    align-items: center;
}

.search-container input {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.3s;
}

.search-container input:focus {
    border-color: #667eea;
    box-shadow: 0 0 0 2px rgba(102, 126, 234, 0.1);
}

.search-container button {
    padding: 8px 16px;
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
}

.search-container button:hover {
    background: #e9ecef;
    border-color: #bbb;
}

/* Стили модальных кнопок */
.modal-buttons {
    display: flex;
    gap: 10px;
    justify-content: flex-end;
    margin-top: 20px;
    flex-wrap: wrap;
}

.modal-buttons button {
    padding: 10px 20px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s ease;
    min-height: 40px;
}

.modal-buttons button:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Цветовая схема кнопок модального окна */
.modal-buttons button:nth-child(1) { /* Сохранить */
    background: #48bb78;
    color: white;
}

.modal-buttons button:nth-child(1):hover {
    background: #38a169;
}

.modal-buttons button:nth-child(2) { /* Скачать */
    background: #4299e1;
    color: white;
}

.modal-buttons button:nth-child(2):hover {
    background: #3182ce;
}

.modal-buttons button:nth-child(3) { /* Обновить */
    background: #a0aec0;
    color: white;
}

.modal-buttons button:nth-child(3):hover {
    background: #718096;
}

.modal-buttons button:nth-child(4) { /* Закрыть */
    background: #f56565;
    color: white;
}

.modal-buttons button:nth-child(4):hover {
    background: #e53e3e;
}

/* Фиксируем размеры модального окна для управления файлами */
#fileManagerModal .modal-content {
    max-height: 80vh;
    overflow-y: auto;
    max-width: 800px;
}

/* Ограничиваем размер textarea */  
#fileContent {
    width: 100%;
    max-width: none;
    height: 400px;
    resize: vertical;
    box-sizing: border-box;
    padding: 12px;
    border: 2px solid #e2e8f0;
    border-radius: 6px;
    font-family: 'Consolas', 'Monaco', 'Courier New', monospace;
    font-size: 13px;
    line-height: 1.4;
}

#fileContent:focus {
    outline: none;
    border-color: #4299e1;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.1);
}

/* Убираем дублирование стилей file-stats */
.file-stats {
    margin-bottom: 10px;
    font-size: 14px;
    color: #666;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #f7fafc;
    padding: 12px 15px;
    border-radius: 6px;
    border: 1px solid #e2e8f0;
}

#searchStatsInfo {
    color: #667eea;
    font-weight: 500;
}

/* Выделение найденного текста */
.search-highlight {
    background-color: #fff3cd;
    color: #856404;
    padding: 1px 2px;
    border-radius: 2px;
}

/* Стили для textarea с поиском */
textarea.search-active {
    border-color: #667eea !important;
}

/* === Стили для пользовательского режима === */

.user-info-section {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 20px 30px;
    border-radius: 12px;
    margin-bottom: 30px;
    box-shadow: 0 4px 20px rgba(102, 126, 234, 0.3);
}

.user-info-section h1 {
    font-size: 1.8rem;
    margin-bottom: 5px;
}

.user-info-section p {
    opacity: 0.9;
    font-size: 0.95rem;
}

/* === Стили для ASN секции === */

.asn-section {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 30px;
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e1e5e9;
}

.asn-stats {
    background: #f7fafc;
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #667eea;
}

.asn-stats p {
    margin: 5px 0;
    font-size: 0.9rem;
    color: #4a5568;
}

.asn-list {
    margin-bottom: 20px;
}

.asn-list h3 {
    color: #2d3748;
    margin-bottom: 10px;
    font-size: 1.1rem;
}

.asn-items {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.asn-tag {
    background: #667eea;
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.asn-resolved {
    margin-top: 20px;
}

.asn-resolved h3 {
    color: #2d3748;
    margin-bottom: 15px;
    font-size: 1.1rem;
}

.asn-resolved-table {
    overflow-x: auto;
}

.asn-resolved-table table {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.9rem;
}

.asn-resolved-table th,
.asn-resolved-table td {
    padding: 10px 12px;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.asn-resolved-table th {
    background: #f7fafc;
    font-weight: 600;
    color: #4a5568;
}

.asn-resolved-table tr:hover {
    background: #f7fafc;
}

/* === Медиа запросы для мобильных устройств === */

@media (max-width: 768px) {
    .user-info-section {
        padding: 15px 20px;
    }
    
    .user-info-section h1 {
        font-size: 1.5rem;
    }
    
    .asn-section {
        padding: 20px 15px;
    }
    
    .asn-items {
        gap: 6px;
    }
    
    .asn-tag {
        font-size: 0.8rem;
        padding: 3px 10px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
} 