/* Подключаем Google Fonts - чистые шрифты без засечек */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600&display=swap');

/* Сброс стилей и базовые настройки */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Основные CSS переменные для цветовой палитры */
:root {
    --primary-color: #4A5568;      /* Темно-серый */
    --accent-color: #718096;       /* Приглушенный синий-серый */
    --accent-secondary: #A0522D;   /* Бордовый */
    --background-light: #FAFAFA;   /* Светло-серый фон */
    --white: #FFFFFF;
    --text-primary: #2D3748;       /* Основной цвет текста */
    --text-secondary: #4A5568;     /* Вторичный цвет текста */
    --border-light: #E2E8F0;       /* Светлые границы */
    --shadow-light: 0 2px 12px rgba(74, 85, 104, 0.1);
    --border-radius: 12px;
    --transition: all 0.3s ease;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.6;
    color: var(--text-primary);
    background-color: var(--white);
}

/* Контейнеры для создания "воздуха" между элементами */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

.section {
    padding: 80px 0;
}

/* Заголовки */
h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
    margin-bottom: 1.5rem;
    color: var(--text-primary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }

/* HEADER - Шапка сайта */
header {
    background: var(--white);
    box-shadow: var(--shadow-light);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
}

/* Навигационное меню */
nav ul {
    display: flex;
    list-style: none;
    gap: 2rem;
}

nav a {
    text-decoration: none;
    color: var(--text-secondary);
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: 6px;
}

nav a:hover,
nav a.active {
    color: var(--accent-secondary);
    background-color: var(--background-light);
}

/* Бургер-меню для мобильных */
.burger {
    display: none;
    flex-direction: column;
    cursor: pointer;
    gap: 4px;
}

.burger span {
    width: 25px;
    height: 3px;
    background: var(--primary-color);
    transition: var(--transition);
}

/* HERO SECTION - Главная секция */
.hero {
    background: linear-gradient(135deg, var(--background-light) 0%, rgba(250, 250, 250, 0.8) 100%);
    min-height: 80vh;
    display: flex;
    align-items: center;
    text-align: center;
    position: relative;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg width="100" height="100" xmlns="http://www.w3.org/2000/svg"><defs><pattern id="textile" patternUnits="userSpaceOnUse" width="100" height="100"><path d="M 0,100 L 100,0" stroke="%23E2E8F0" stroke-width="1" opacity="0.3"/><path d="M 0,0 L 100,100" stroke="%23E2E8F0" stroke-width="1" opacity="0.3"/></pattern></defs><rect width="100" height="100" fill="url(%23textile)"/></svg>');
    opacity: 0.5;
}

.hero-content {
    position: relative;
    z-index: 2;
}

.hero h1 {
    font-size: 3.5rem;
    margin-bottom: 1rem;
    font-weight: 600;
    color: var(--primary-color);
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 3rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* Кнопки */
.btn-group {
    display: flex;
    gap: 1.5rem;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    display: inline-block;
    padding: 1rem 2rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 1rem;
}

.btn-primary {
    background: var(--accent-secondary);
    color: var(--white);
}

.btn-primary:hover {
    background: #8B4513;
    transform: translateY(-2px);
    box-shadow: var(--shadow-light);
}

.btn-secondary {
    background: var(--white);
    color: var(--primary-color);
    border: 2px solid var(--border-light);
}

.btn-secondary:hover {
    background: var(--background-light);
    border-color: var(--accent-color);
    transform: translateY(-2px);
}

/* ADVANTAGES SECTION - Блок преимуществ */
.advantages {
    background: var(--white);
    text-align: center;
}

.advantages h2 {
    margin-bottom: 3rem;
    color: var(--primary-color);
}

.advantages-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.advantage-card {
    padding: 2rem;
    background: var(--background-light);
    border-radius: var(--border-radius);
    transition: var(--transition);
}

.advantage-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-light);
}

.advantage-icon {
    width: 60px;
    height: 60px;
    background: var(--accent-secondary);
    border-radius: 50%;
    margin: 0 auto 1.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--white);
    font-size: 1.5rem;
}

/* FILTERS - Фильтры на страницах вакансий и резюме */
.filters {
    background: var(--background-light);
    padding: 2rem 0;
}

.filter-form {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
}

.filter-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 500;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

select, input[type="text"] {
    padding: 0.75rem;
    border: 2px solid var(--border-light);
    border-radius: 8px;
    background: var(--white);
    color: var(--text-primary);
    font-size: 1rem;
    transition: var(--transition);
}

select:focus, input[type="text"]:focus {
    outline: none;
    border-color: var(--accent-color);
    box-shadow: 0 0 0 3px rgba(113, 128, 150, 0.1);
}

/* CARDS - Карточки вакансий и резюме */
.cards-section {
    padding: 3rem 0;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.card {
    background: var(--white);
    border: 1px solid var(--border-light);
    border-radius: var(--border-radius);
    padding: 1.5rem;
    transition: var(--transition);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-light);
}

.card-header {
    margin-bottom: 1rem;
}

.card-title {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--primary-color);
}

.card-subtitle {
    color: var(--text-secondary);
    font-weight: 500;
}

.card-location {
    color: var(--accent-color);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.card-content {
    margin-bottom: 1.5rem;
}

.requirements {
    list-style: none;
    margin: 1rem 0;
}

.requirements li {
    position: relative;
    padding-left: 1.5rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
}

.requirements li::before {
    content: '•';
    color: var(--accent-secondary);
    font-weight: bold;
    position: absolute;
    left: 0;
}

.salary {
    font-weight: 600;
    color: var(--accent-secondary);
    font-size: 1.1rem;
    margin-bottom: 1rem;
}

.tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.tag {
    background: var(--background-light);
    color: var(--text-secondary);
    padding: 0.3rem 0.8rem;
    border-radius: 16px;
    font-size: 0.85rem;
    border: 1px solid var(--border-light);
}

/* Детали карточки (раскрывающиеся) */
.card-details {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
    margin-top: 1rem;
    padding-top: 0;
    border-top: 1px solid var(--border-light);
}

.card-details.expanded {
    max-height: 600px;
    padding-top: 1rem;
}

.card-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.btn-small {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
    border-radius: 8px;
}

/* FOOTER */
footer {
    background: var(--primary-color);
    color: var(--white);
    text-align: center;
    padding: 3rem 0;
    margin-top: 4rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    color: var(--white);
    margin-bottom: 1rem;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin: 1rem 0;
}

.social-links a {
    color: var(--white);
    text-decoration: none;
    padding: 0.5rem;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transition: var(--transition);
}

.social-links a:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

/* RESPONSIVE DESIGN - Адаптивность */

@media (max-width: 768px) {
    /* Мобильная навигация */
    nav ul {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: var(--white);
        flex-direction: column;
        box-shadow: var(--shadow-light);
        padding: 1rem 0;
    }

    nav ul.mobile-menu-open {
        display: flex;
    }

    .burger {
        display: flex;
    }

    /* Адаптация hero секции */
    .hero h1 {
        font-size: 2.5rem;
    }

    .hero p {
        font-size: 1.1rem;
    }

    .btn-group {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 280px;
        text-align: center;
    }

    /* Адаптация фильтров */
    .filter-form {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-group {
        width: 100%;
    }

    /* Адаптация карточек */
    .cards-grid {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .card-actions {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }

    .btn-small {
        width: 100%;
        text-align: center;
    }

    /* Футер */
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
}

/* Дополнительные адаптивные настройки для маленьких экранов */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }
    
    .section {
        padding: 60px 0;
    }
    
    .hero {
        min-height: 70vh;
    }
    
    .hero h1 {
        font-size: 2rem;
    }
    
    .card {
        padding: 1rem;
    }
}

/* Анимации для плавных переходов */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.fade-in {
    animation: fadeIn 0.6s ease forwards;
}

/* Утилитарные классы */
.text-center { text-align: center; }
.mb-2 { margin-bottom: 1rem; }
.mb-3 { margin-bottom: 1.5rem; }
.mb-4 { margin-bottom: 2rem; }
.hidden { display: none; }
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}