/* Стили для страницы профессии */

/* Вкладки */
.tabs {
    margin-bottom: 2rem;
}

.tabs ul {
    border-bottom: 2px solid var(--border);
}

.tabs li.is-active a {
    background-color: var(--primary);
    border-color: var(--primary);
}

.tabs a {
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}

.tabs a:hover {
    border-bottom-color: var(--primary);
    background-color: var(--surface);
}

/* Контент вкладок */
.tab-content {
    min-height: 20px;
}

.mt-6 {
    margin-top: 0.7rem !important;
}

.tab-pane {
    display: none;
}

.tab-pane.is-active {
    display: block;
    animation: fadeIn 0.5s ease-in-out;
}

/* Таблица */
.table-container {
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 10px var(--shadow);
}

.table {
    background-color: var(--surface);
    color: var(--text);
    width: 100% !important;
    table-layout: fixed; /* Фиксированная раскладка таблицы */
}

.table thead th {
    background-color: var(--primary) !important;
    border: none;
    font-weight: 600;
    font-size: 1.1rem;
    vertical-align: middle;
}

.table tbody tr {
    transition: all 0.3s ease;
    border-bottom: 1px solid var(--border);
}

.table tbody tr:last-child {
    border-bottom: none;
}

.table tbody tr:hover {
    background-color: var(--primary) !important;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px var(--shadow);
}

/* ВЫРАВНИВАНИЕ ПО ЦЕНТРУ */
.table td {
    vertical-align: middle !important;
}

/* Теги/бейджи */
.tag {
    font-weight: 600;
    font-size: 0.9rem;
    padding: 0.5rem 0.75rem;
}

/* Описания */
.description-content {
    line-height: 1.7;
}

.description-content p {
    margin-bottom: 1rem;
}

.description-content ul,
.description-content ol {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.description-content li {
    margin-bottom: 0.5rem;
}

/* Уведомления */
.notification.is-info {
    background-color: var(--primary);
    color: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px var(--shadow);
}

.notification.is-info .title,
.notification.is-info .subtitle {
    color: white;
}

/* Тени и анимации */
.shadow-lg {
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1) !important;
}
/* Устанавливаем фиксированные ширины для колонок */
    .table thead th:nth-child(1),
    .table tbody td:nth-child(1) {
        width: 15%; /* Область аттестации */
        text-align: center;
    }

    .table thead th:nth-child(2),
    .table tbody td:nth-child(2) {
        width: 15%; /* Код */
    }

    .table thead th:nth-child(3),
    .table tbody td:nth-child(3) {
        width: 70%; /* Название теста */
    }

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Адаптивность */
@media (max-width: 768px) {
    .tabs {
        font-size: 0.9rem;
    }

    .tabs .icon {
        display: none;
    }

    /* Убираем горизонтальную прокрутку */
    .table-container {
        overflow-x: hidden !important; /* Запрещаем горизонтальный скролл */
        width: 100%;
    }

    .table {
        width: 100% !important;
        min-width: auto !important;
    }

    /* Разрешаем перенос текста */
    .table thead th {
        font-size: 0.8rem;
        padding: 0.75rem 0.5rem;
        white-space: normal;
        word-wrap: break-word;
        text-align: center;
        vertical-align: middle;
        overflow: hidden;
    }

    .table tbody td {
        font-size: 0.9rem;
        padding: 0.75rem 0.5rem;
        white-space: normal;
        word-wrap: break-word;
        vertical-align: middle !important;
        overflow: hidden;
    }

    /* Устанавливаем фиксированные ширины для колонок */
    .table thead th:nth-child(1),
    .table tbody td:nth-child(1) {
        width: 20%; /* Область аттестации */
        text-align: center;
    }

    .table thead th:nth-child(2),
    .table tbody td:nth-child(2) {
        width: 20%; /* Код */
    }

    .table thead th:nth-child(3),
    .table tbody td:nth-child(3) {
        width: 60%; /* Название теста */
    }

    .tag {
        font-size: 0.8rem;
        padding: 0.3rem 0.5rem;
        white-space: nowrap;
        vertical-align: middle;
        display: inline-flex !important;
        align-items: center !important;
        justify-content: center !important;
        max-width: 100%;
        overflow: hidden;
    }

    .test-name {
        font-size: 0.9rem;
        line-height: 1.3;
    }
}

/* Дополнительные стили для очень маленьких экранов */
@media (max-width: 480px) {
    .box {
        padding: 0.5rem !important;
        margin: 0.5rem 0 !important;
    }
    
    .section {
        padding: 0.5rem 0 !important;
    }

    .tabs li span {
        font-size: 0.8rem !important;
    }

    .tabs.is-boxed li a {
        padding: 0.5rem 0.75rem !important;
    }

    .title.is-4 {
        font-size: 0.8rem;
    }

    /* Еще более компактная таблица */
    .table thead th {
        font-size: 0.7rem;
        padding: 0.4rem 0.3rem;
    }

    .table tbody td {
        font-size: 0.8rem;
        padding: 0.4rem 0.3rem;
        vertical-align: middle !important;
    }

    /* Уменьшаем ширину колонок */
    .table thead th:nth-child(1),
    .table tbody td:nth-child(1) {
        width: 20%; /* Увеличиваем для текста */
    }

    .table thead th:nth-child(2),
    .table tbody td:nth-child(2) {
        width: 20%; /* Уменьшаем для кода */
    }

    .table thead th:nth-child(3),
    .table tbody td:nth-child(3) {
        width: 60%; /* Название теста */
    }

    .tag {
        font-size: 0.7rem;
        padding: 0.2rem 0.3rem;
    }

    .tag.is-medium {
        font-size: 0.7rem !important;
    }

    .test-name {
        font-size: 0.8rem;
    }

    .icon {
        font-size: 0.8rem;
    }

    .py-3 {
        padding-bottom: 0.25rem !important;
        padding-top: 0.25rem !important;
    }

    .py-4 {
        padding-bottom: 0.25rem !important;
        padding-top: 0.25rem !important;
    }

    .title.is-5.mb-3 {
        font-size: 0.8rem;
    }

    .subtitle.is-6.mb-0 {
        font-size: 0.6rem;
    }
    
    .is-size-5 {
        font-size: 0.8rem !important;
    }
}

/* Специальные стили для экранов 380px и меньше */
@media (max-width: 380px) {
    .table-container {
        overflow-x: hidden !important;
        width: 100%;
    }
     .tag.is-medium {
    font-size: 0.5rem !important;
  }
    .table {
        width: 100% !important;
    }
    
    /* Еще более компактные колонки */
    .table thead th:nth-child(1),
    .table tbody td:nth-child(1) {
        width: 20%;
        font-size: 0.7rem;
    }
    
    .table thead th:nth-child(2),
    .table tbody td:nth-child(2) {
        width: 20%;
    }
    
    .table thead th:nth-child(3),
    .table tbody td:nth-child(3) {
        width: 60%;
    }
    
    .tag {
        font-size: 0.65rem;
        padding: 0.15rem 0.25rem;
    }
    
    .test-name {
        font-size: 0.75rem;
    }
    
    /* Скрываем иконку стрелки на очень маленьких экранах */
    .table tbody td .icon {
        display: none;
    }
    
    /* Уменьшаем отступы */
    .table thead th,
    .table tbody td {
        padding: 0.3rem 0.2rem !important;
    }
}

/* Иконки */
.icon i {
    font-style: normal;
}

/* Полосы для таблицы */
.table.is-striped tbody tr:nth-child(even) {
    background-color: var(--surface);
}

.table.is-striped tbody tr:nth-child(odd) {
    background-color: var(--background);
}