/* Стили для хлебных крошек */
.breadcrumbs {
    padding: 15px 0;
    margin: 0 auto 10px;
    max-width: 1200px;
    font-size: 0.9rem;
}

.breadcrumbs a {
    color: var(--accent-color);
    text-decoration: none;
    transition: color 0.3s;
}

.breadcrumbs a:hover {
    color: var(--text-color);
    text-decoration: underline;
}

.breadcrumb-separator {
    margin: 0 5px;
    color: var(--text-muted);
}

.breadcrumb-current {
    color: var(--text-muted);
    font-weight: 500;
}

/* Основные стили секции */
.vacancies-section {
    background-color: var(--bg-color);
    padding: 40px 0;
}

.vacancies-container {
    max-width: 1200px;
    margin: 0 auto;
}

.vacancies-title {
    color: var(--accent-color);
    text-align: center;
    margin-bottom: 15px;
    font-size: 2.5rem;
}

.vacancies-subtitle {
    color: var(--text-muted);
    text-align: center;
    max-width: 700px;
    margin: 0 auto 30px;
    font-size: 1.1rem;
    line-height: 1.6;
}

/* Сетка вакансий */
.vacancies-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    align-items: stretch;
}

/* Карточка вакансии */
.vacancy-card {
    display: flex;
    /* Делаем flex-контейнером */
    flex-direction: column;
    /* Вертикальное расположение элементов */
    height: 100%;
    /* Занимаем всю доступную высоту */
    background: var(--card-bg);
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s, border 0.3s;
    border: 2px solid transparent;
    position: relative;
}

.vacancy-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    border: 2px solid var(--accent-color);
}

.vacancy-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: var(--accent-color);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.3s ease;
}

.vacancy-card:hover::before {
    transform: scaleX(1);
}

.vacancy-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.vacancy-content {
    flex: 1;
    /* Занимает всё доступное пространство */
    display: flex;
    flex-direction: column;
    padding: 20px;
}

.vacancy-title {
    color: var(--accent-color);
    margin-top: 0;
    margin-bottom: 10px;
    font-size: 1.4rem;
    font-weight: 600;
    position: relative;
    padding-bottom: 8px;
}

.vacancy-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background: var(--accent-color);
}

.vacancy-description {
    color: var(--text-muted);
    margin-bottom: 15px;
    line-height: 1.5;
    font-size: 0.95rem;
}

.vacancy-salary {
    background: var(--accent-color-rgba);
    color: var(--accent-color);
    padding: 8px 12px;
    border-radius: 6px;
    display: inline-block;
    margin-bottom: 15px;
    font-weight: bold;
    font-size: 1.1rem;
    box-shadow: 0 2px 5px rgba(7, 155, 89, 0.2);
}

/* Блок с преимуществами */
.vacancy-benefits {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.benefit-tag {
    background: var(--hover-bg);
    color: var(--text-color);
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.85em;
    border: 1px solid var(--divider-color);
    transition: all 0.3s ease;
}

.benefit-tag:hover {
    background: var(--accent-color-rgba);
    color: var(--accent-color);
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

/* Кнопка отклика */
.vacancy-apply-btn {
    margin-top: auto;
    /* Автоматический отступ сверху */
    display: block;
    text-align: center;
    background: var(--accent-color);
    color: white;
    padding: 12px 15px;
    border-radius: var(--border-radius);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 10px rgba(7, 155, 89, 0.3);
    border: none;
    position: relative;
    overflow: hidden;
}

.vacancy-apply-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.7s ease;
}

.vacancy-apply-btn:hover {
    background: #068a50;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(7, 155, 89, 0.4);
    border-radius: var(--border-radius);
}

.vacancy-apply-btn:hover::before {
    left: 100%;
}

/* Сообщение об отсутствии вакансий */
.no-vacancies {
    grid-column: 1 / -1;
    text-align: center;
    padding: 40px;
    color: var(--text-muted);
}

/* Ссылка на все вакансии */
.vacancies-footer {
    text-align: center;
    margin-top: 40px;
}

.all-vacancies-link {
    display: inline-block;
    color: var(--accent-color);
    text-decoration: none;
    font-weight: bold;
    padding: 12px 25px;
    border: 2px solid var(--accent-color);
    border-radius: var(--border-radius);
    transition: all 0.3s;
    position: relative;
    overflow: hidden;
    z-index: 1;
}

.all-vacancies-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 0%;
    height: 100%;
    background-color: var(--accent-color);
    transition: width 0.3s ease;
    z-index: -1;
}

.all-vacancies-link:hover {
    color: white;
    border-radius: var(--border-radius);
}

.all-vacancies-link:hover::before {
    width: 100%;
}

/* Стили для детальной страницы вакансии */
.vacancy-details-btn {
    display: block;
    text-align: center;
    background: var(--accent-color);
    color: white;
    padding: 12px 15px;
    border-radius: var(--border-radius);
    text-decoration: none;
    transition: all 0.3s ease;
    margin-top: auto;
    font-weight: 600;
    letter-spacing: 0.5px;
    box-shadow: 0 4px 10px rgba(7, 155, 89, 0.3);
    border: none;
    position: relative;
    overflow: hidden;
}

.vacancy-details-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.7s ease;
}

.vacancy-details-btn:hover {
    background: #068a50;
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(7, 155, 89, 0.4);
    border-radius: var(--border-radius);
}

.vacancy-details-btn:hover::before {
    left: 100%;
}

/* Стили для детальной страницы вакансии */
.vacancy-detail {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    border-top: 5px solid var(--accent-color);
}

.divider {
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--accent-color), transparent);
    margin: 20px auto;
    width: 100%;
}

.vacancy-header {
    display: flex;
    align-items: center;
    margin-bottom: 30px;
}

.vacancy-header-image {
    width: 150px;
    height: 150px;
    object-fit: cover;
    border-radius: var(--border-radius);
    margin-right: 30px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    border: 3px solid var(--accent-color-rgba);
}

.vacancy-header-content h1 {
    margin-top: 0;
    color: var(--accent-color);
    font-size: 2rem;
    margin-bottom: 15px;
}

.vacancy-salary {
    font-size: 1.3rem;
    font-weight: bold;
    margin: 15px 0;
    color: var(--accent-color);
    display: inline-block;
    padding: 8px 15px;
    background: var(--accent-color-rgba);
    border-radius: var(--border-radius);
}

.vacancy-description {
    margin: 25px 0;
    line-height: 1.7;
    white-space: pre-line;
    color: var(--text-color);
    font-size: 1.05rem;
}

.vacancy-benefits-section {
    margin: 30px 0;
    padding: 20px;
    background: var(--bg-color);
    border-radius: var(--border-radius);
    border-left: 4px solid var(--accent-color);
}

.vacancy-benefits-section h2 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--accent-color);
}

.vacancy-apply {
    margin-top: 40px;
    text-align: center;
}

.back-link {
    display: inline-block;
    margin-top: 25px;
    color: var(--text-muted);
    text-decoration: none;
    transition: all 0.3s ease;
    font-weight: 500;
}

.back-link:hover {
    color: var(--accent-color);
    transform: translateX(-5px);
}

/* Стили для страницы отклика на вакансию */
.vacancy-application-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 30px;
    background-color: var(--card-bg);
    border-radius: var(--border-radius);
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.1);
    border-top: 5px solid var(--accent-color);
}

.vacancy-application-title {
    color: var(--accent-color);
    margin-bottom: 30px;
    font-size: 1.8rem;
    position: relative;
    padding-bottom: 10px;
}

.vacancy-application-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--accent-color);
}

.vacancy-application-form {
    margin-top: 20px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-color);
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid var(--divider-color);
    border-radius: var(--border-radius);
    background-color: var(--input-bg);
    color: var(--text-color);
    font-size: 1rem;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--accent-color);
    box-shadow: 0 0 0 2px var(--accent-color-rgba);
    outline: none;
}

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

.form-error {
    color: #e74c3c;
    font-size: 0.9rem;
    margin-top: 5px;
}

.form-actions {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 30px;
}

.form-actions .back-link {
    align-self: center;
}

/* Адаптивность */
@media (max-width: 768px) {
    .vacancies-grid {
        grid-template-columns: 1fr;
    }

    .vacancies-title {
        font-size: 1.5rem;
    }

    .vacancy-header {
        flex-direction: column;
        text-align: center;
    }

    .vacancy-header-image {
        margin-right: 0;
        margin-bottom: 20px;
    }

    .vacancy-header-content h1::after {
        left: 50%;
        transform: translateX(-50%);
    }

    .vacancy-detail {
        padding: 20px;
    }
}
