/* Сброс стилей */
* { margin:0; padding:0; box-sizing: border-box; }

body { font-family: 'Roboto', sans-serif; background: #f4f7f9; color: #333; }

.container {
    max-width: 500px;
    margin: 50px auto;
    padding: 20px;
}

h1 {
    text-align: center;
    margin-bottom: 30px;
    color: #007bff;
}

.form-card {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
}

.form-card label {
    display: block;
    margin-bottom: 6px;
    font-weight: 700;
    color: #555;
}

.form-card input,
.form-card textarea {
    width: 100%;
    padding: 12px 15px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 8px;
    transition: 0.3s all;
    font-size: 1rem;
}

.form-card input:focus,
.form-card textarea:focus {
    border-color: #007bff;
    box-shadow: 0 0 8px rgba(0,123,255,0.2);
    outline: none;
}

textarea { resize: vertical; min-height: 80px; }

.btn-primary {
    width: 100%;
    background: #007bff;
    color: #fff;
    font-size: 1.1rem;
    font-weight: 700;
    padding: 15px;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: 0.3s all;
}

.btn-primary:hover { background: #0056b3; }

@media(max-width: 576px){
    .container { margin: 20px; padding: 15px; }
    .form-card { padding: 20px; }
    h1 { font-size: 1.8rem; }
    .btn-primary { padding: 12px; font-size: 1rem; }
}

/* Стиль для поля загрузки фото */
.form-card input[type="file"] {
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 8px;
    width: 100%;
    background: #f9f9f9;
    cursor: pointer;
    margin-bottom: 20px;
    transition: 0.3s all;
}

.form-card input[type="file"]:hover {
    border-color: #007bff;
}

/* Стиль для страницы результата сохранения */
.result-card {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    text-align: center;
    max-width: 500px;
    margin: 50px auto;
}

.result-card h2 {
    color: #28a745; /* зеленый для успеха */
    margin-bottom: 20px;
}

.result-card .btn-primary {
    display: inline-block;
    padding: 12px 25px;
    font-size: 1.1rem;
    border-radius: 50px;
    background: #007bff;
    color: #fff;
    text-decoration: none;
    font-weight: 700;
    transition: 0.3s all;
}

.result-card .btn-primary:hover { background: #0056b3; }

/* Карточки кандидатов 2 в ряд, квадратные */
.cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 20px auto;
    max-width: 1000px; /* увеличиваем максимальную ширину */
}

.candidate-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
    width: 48%; /* 2 карточки в ряд с промежутком */
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    box-sizing: border-box;
}

/* Квадратная форма */
.candidate-card img {
    width: 100%;
    height: auto;
    max-height: 250px; /* фото не выходит за пределы квадрата */
    object-fit: cover;
    border-radius: 12px;
    margin-bottom: 10px;
}

.candidate-card h3 { 
    color: #007bff; 
    margin-bottom: 5px; 
    font-size: 1.1rem;
}

.candidate-card p { 
    margin: 2px 0; 
    color: #555; 
    font-size: 0.9rem; 
}

/* Hover эффект */
.candidate-card:hover { transform: translateY(-5px); }

/* Адаптивность */
@media(max-width: 768px) { .candidate-card { width: 48%; } }
@media(max-width: 480px) { .candidate-card { width: 100%; } }

/* Блок кнопок на результатах */
.save-buttons {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btn-secondary {
    display: inline-block;
    padding: 12px 18px;
    background: #4a4a4a;
    color: #fff;
    border-radius: 8px;
    text-align: center;
    text-decoration: none;
    font-size: 16px;
    transition: 0.3s;
}

.btn-secondary:hover { background: #000; }

/* На больших экранах кнопки в ряд */
@media(min-width: 600px){ .save-buttons { flex-direction: row; justify-content: center; } }

/* -------------------
   Стиль для карточек вакансий
------------------- */
.vacancies-cards {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    margin: 20px auto;
    max-width: 1000px;
}

.vacancy-card {
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    text-align: center;
    transition: transform 0.3s;
    width: 48%; /* 2 карточки в ряд */
    margin-bottom: 20px;
    padding: 15px;
    box-sizing: border-box;
}

.vacancy-card h3 {
    color: #007bff;
    margin-bottom: 10px;
    font-size: 1.2rem;
}

.vacancy-card p {
    margin: 4px 0;
    color: #555;
    font-size: 0.95rem;
}

.vacancy-card:hover { transform: translateY(-5px); }

@media(max-width: 768px) { .vacancy-card { width: 48%; } }
@media(max-width: 480px) { .vacancy-card { width: 100%; } }

/* Фильтр вакансий */
.vacancy-filter {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.vacancy-filter .filter-group {
    flex: 1 1 100%;
}

@media(min-width: 600px) {
    .vacancy-filter .filter-group {
        flex: 1 1 calc(33% - 10px);
    }
}

.vacancy-filter input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ccc;
    border-radius: 8px;
    font-size: 1rem;
    transition: 0.3s all;
}

.vacancy-filter input:focus {
    border-color: #007bff;
    box-shadow: 0 0 6px rgba(0,123,255,0.2);
    outline: none;
}

.vacancy-filter button {
    flex: 1 1 100%;
    margin-top: 5px;
}
