:root {
    --bg: #0c0c12;
    --surface: #14141c;
    --surface-hover: #1b1b26;
    --surface-border: rgba(255,255,255,0.06);
    --surface-border-hover: rgba(255,255,255,0.12);
    --text: #eaeaf0;
    --text-sub: #9999ab;
    --text-faint: #555564;
    --accent: #6e56f8;
    --accent-hover: #8270ff;
    --accent-glow: rgba(110, 86, 248, 0.25);
    --accent-subtle: rgba(110, 86, 248, 0.08);
    --radius: 12px;
    --radius-sm: 8px;
    --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --font: 'Inter', system-ui, sans-serif;
}

*, *::before, *::after { margin:0; padding:0; box-sizing:border-box; }
html { scroll-behavior: smooth; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

::selection { background: var(--accent); color:#fff; }

/* ═══════════ HEADER ═══════════ */

.header {
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(12,12,18,0.75);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--surface-border);
}

.header-inner {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 28px;
    height: 62px;
    display: flex;
    align-items: center;
}

.header-logo {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    text-decoration: none;
    transition: color 0.2s;
}
.header-logo:hover { color: var(--accent-hover); }

/* ═══════════ HERO ═══════════ */

.hero {
    position: relative;
    height: 380px;
    display: flex;
    align-items: flex-end;
    overflow: hidden;
}

.hero-bg {
    position: absolute;
    inset: 0;
}

.hero-bg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0.45;
    object-position: 50% 10%;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(12,12,18,0.15) 0%,
        rgba(12,12,18,0.55) 50%,
        var(--bg) 100%
    );
}

.hero-content {
    position: relative;
    z-index: 2;
    max-width: 1080px;
    width: 100%;
    margin: 0 auto;
    padding: 0 28px 52px;
}

.hero-content h1 {
    font-size: clamp(2.2rem, 5vw, 3rem);
    font-weight: 800;
    letter-spacing: -0.03em;
    line-height: 1.15;
    margin-bottom: 12px;
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-sub);
}

/* ═══════════ CARDS ═══════════ */

.home { flex: 1; }
.home.hidden { display: none; }

.cards-wrap {
    max-width: 1080px;
    margin: 0 auto;
    padding: 0 28px 100px;
}

.cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 16px;
}

.card {
    position: relative;
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius);
    padding: 32px 28px;
    cursor: pointer;
    transition:
        transform 0.3s var(--ease),
        border-color 0.3s var(--ease),
        box-shadow 0.3s var(--ease),
        background 0.3s var(--ease);
    overflow: hidden;
}

.card::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: var(--radius);
    opacity: 0;
    background: radial-gradient(
        600px circle at var(--mx, 50%) var(--my, 50%),
        var(--accent-subtle),
        transparent 60%
    );
    transition: opacity 0.3s;
    pointer-events: none;
}

.card:hover::before { opacity: 1; }

.card:hover {
    transform: translateY(-5px);
    border-color: var(--surface-border-hover);
    box-shadow: 0 10px 36px rgba(0,0,0,0.4);
}

.card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
    background: var(--accent-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3rem;
    margin-bottom: 20px;
}

.card-title {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text);
}

.card-desc {
    font-size: 0.92rem;
    color: var(--text-sub);
    line-height: 1.55;
}

.card-arrow {
    position: absolute;
    bottom: 28px;
    right: 28px;
    font-size: 1rem;
    color: var(--text-faint);
    transition: color 0.2s, transform 0.2s;
}

.card-status {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 16px;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.card-status::before {
    content: '';
    width: 7px;
    height: 7px;
    border-radius: 50%;
    flex-shrink: 0;
}

.card-status.open {
    color: #4ade80;
}

.card-status.open::before {
    background: #4ade80;
    box-shadow: 0 0 8px rgba(74, 222, 128, 0.4);
}

.card-status.closed {
    color: #f87171;
}

.card-status.closed::before {
    background: #f87171;
    box-shadow: 0 0 8px rgba(248, 113, 113, 0.4);
}

/* Закрытая карточка */

.card.card-closed {
    opacity: 0.55;
}

.card.card-closed:hover {
    transform: none;
    box-shadow: none;
    cursor: default;
}

.card.card-closed::before {
    display: none;
}

.card.card-closed .card-arrow {
    display: none;
}

.card:hover .card-arrow {
    color: var(--accent);
    transform: translateX(4px);
}

/* ═══════════ VACANCY PAGE ═══════════ */

.page {
    display: none;
    flex: 1;
    max-width: 1080px;
    width: 100%;
    margin: 0 auto;
    padding: 44px 28px 100px;
}

.page.visible {
    display: block;
    animation: slideUp 0.5s var(--ease) both;
}

@keyframes slideUp {
    from { opacity:0; transform: translateY(24px); }
    to   { opacity:1; transform: translateY(0); }
}

/* Назад */

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 18px;
    margin-bottom: 40px;
    border: 1px solid var(--surface-border);
    background: var(--surface);
    color: var(--text-sub);
    font-family: var(--font);
    font-size: 0.9rem;
    font-weight: 500;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.2s var(--ease);
}

.back-btn:hover {
    color: var(--text);
    border-color: var(--surface-border-hover);
    background: var(--surface-hover);
}

/* Hero блок */

.v-hero {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 52px;
    align-items: center;
    margin-bottom: 52px;
}

.v-text { display: flex; flex-direction: column; gap: 16px; }

.v-title-row {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

/* Кнопка «Подать заявку» inline */

.apply-btn-inline {
    display: inline-flex;
    align-items: center;
    padding: 10px 22px;
    border: 1px solid var(--surface-border-hover);
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-sub);
    text-decoration: none;
    font-family: var(--font);
    font-size: 0.88rem;
    font-weight: 600;
    transition: all 0.25s var(--ease);
    white-space: nowrap;
}

.apply-btn-inline.disabled {
    border-color: #f87171;
    color: #f87171;
    pointer-events: none;
    opacity: 0.6;
}

.apply-btn-inline:hover {
    background: var(--accent);
    border-color: var(--accent);
    color: #fff;
    box-shadow: 0 4px 20px var(--accent-glow);
    transform: translateY(-1px);
}

/* Картинка */

.v-hero img {
    width: 100%;
    border-radius: var(--radius);
    object-fit: cover;
    aspect-ratio: 4/3;
    transition: transform 0.5s var(--ease);
}

.v-hero img:hover {
    transform: scale(1.03);
}

/* Типография */

.page h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

.page h2 {
    font-size: 1.15rem;
    font-weight: 700;
    margin-bottom: 14px;
    color: var(--text);
}

.page p {
    font-size: 0.95rem;
    line-height: 1.75;
    color: var(--text-sub);
}

.page strong {
    color: var(--text);
    font-weight: 600;
}

.page ul {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.page li {
    font-size: 0.92rem;
    color: var(--text-sub);
    line-height: 1.6;
    padding-left: 18px;
    position: relative;
}

.page li::before {
    content: '';
    position: absolute;
    left: 0; top: 9px;
    width: 5px; height: 5px;
    border-radius: 50%;
    background: var(--accent);
    opacity: 0.55;
}

/* Текстовые секции */

.v-section-text {
    margin-bottom: 48px;
}

.v-section-text h2 {
    margin-bottom: 18px;
}

.v-section-text p {
    margin-bottom: 14px;
}

.v-section-text p:last-child {
    margin-bottom: 0;
}

/* Карточки баллов */

.score-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 14px;
    margin-top: 24px;
}

.score-card {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius);
    padding: 28px;
    transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}

.score-card:hover {
    transform: translateY(-3px);
    border-color: var(--surface-border-hover);
    box-shadow: 0 8px 28px rgba(0,0,0,0.3);
}

.score-card.accent {
    border-color: rgba(110, 86, 248, 0.25);
    background: linear-gradient(
        135deg,
        rgba(110, 86, 248, 0.06),
        var(--surface)
    );
}

.score-card.accent:hover {
    border-color: rgba(110, 86, 248, 0.4);
    box-shadow: 0 8px 32px var(--accent-glow);
}

.score-range {
    font-size: 2rem;
    font-weight: 800;
    color: var(--accent-hover);
    letter-spacing: -0.03em;
    line-height: 1;
}

.score-label {
    font-size: 0.8rem;
    color: var(--text-faint);
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 14px;
}

.score-card p {
    font-size: 0.88rem;
    color: var(--text-sub);
    line-height: 1.6;
    margin: 0;
}

/* Блоки (требования, предлагаем) */

.v-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-bottom: 52px;
}

.v-block {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    border-radius: var(--radius);
    padding: 28px;
    transition: transform 0.3s var(--ease), border-color 0.3s, box-shadow 0.3s;
}

.v-block:hover {
    transform: translateY(-3px);
    border-color: var(--surface-border-hover);
    box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}

/* ═══════════ FOOTER ═══════════ */

.footer {
    border-top: 1px solid var(--surface-border-hover);
    background: var(--surface);
}

.footer-inner {
    max-width: 1080px;
    margin: 0 auto;
    padding: 36px 28px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 28px;
}

.footer-col {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.footer-brand {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
}

.footer-copy {
    font-size: 0.82rem;
    color: var(--text-faint);
}

.footer-links { align-items: flex-end; gap: 8px; }

.footer-links a {
    font-size: 0.85rem;
    color: var(--text-sub);
    text-decoration: none;
    transition: color 0.2s;
}
.footer-links a:hover { color: var(--accent-hover); }

/* ═══════════ RESPONSIVE ═══════════ */

@media (max-width: 768px) {
    .hero { height: 280px; }
    .hero-content { padding-bottom: 36px; }
    .header-inner { padding: 0 20px; }
    .cards-wrap { padding: 0 20px 60px; }
    .cards-grid { grid-template-columns: 1fr; }

    .v-hero {
        grid-template-columns: 1fr;
        gap: 28px;
    }

    .v-hero img {
        width: 100%;
        border-radius: var(--radius);
        object-fit: cover;
        aspect-ratio: 4/3;
        transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
        will-change: transform;
    }

    .v-title-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .score-cards { grid-template-columns: 1fr; }
    .v-grid { grid-template-columns: 1fr; }
    .page { padding: 32px 20px 60px; }

    .footer-inner {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }
    .footer-links { align-items: center; }
}