/* Course archive (Figma «Все курсы») */

.vb-catalog-page {
    background: #f0f8fa;
    padding-bottom: 100px;
}

.vb-catalog-page__inner {
    width: 100%;
    max-width: 1760px;
    margin-inline: auto;
    padding: 32px 24px 0;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 52px;
}

/* Hero */
.vb-catalog-hero {
    position: relative;
    width: 100%;
    min-height: 750px;
    border-radius: 32px;
    overflow: hidden;
    background: #232929;
    isolation: isolate;
}

.vb-catalog-hero__layers {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.vb-catalog-hero__ellipse {
    position: absolute;
    width: 538px;
    height: 538px;
    left: 50%;
    top: 50%;
    transform: translate(calc(-50% + 505px), calc(-50% - 51px));
    border-radius: 50%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.12) 0%, transparent 70%);
    opacity: 0.9;
}

.vb-catalog-hero__pattern {
    position: absolute;
    left: calc(100% * 1007 / 1760);
    bottom: 66px;
    width: min(602px, calc(100% * 602 / 1760));
    height: 654px;
    max-width: 100%;
    opacity: 0.2;
    overflow: hidden;
    z-index: 0;
    box-sizing: border-box;
}

.vb-catalog-hero__pattern img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: contain;
    object-position: left bottom;
}

.vb-catalog-hero__photo-wrap {
    position: absolute;
    left: calc(100% * 945 / 1760);
    top: 4px;
    width: min(759px, calc(100% * 759 / 1760));
    aspect-ratio: 759 / 746;
    height: auto;
    overflow: hidden;
    pointer-events: none;
    z-index: 1;
}

.vb-catalog-hero__photo {
    position: absolute;
    left: -0.03%;
    top: -9.17%;
    width: 100.06%;
    height: 152.78%;
    max-width: none;
    display: block;
}

.vb-catalog-hero__content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    min-height: 750px;
    padding: 42px 32px;
    box-sizing: border-box;
    gap: 40px;
}

.vb-catalog-hero__text {
    display: flex;
    flex-direction: column;
    gap: 24px;
    max-width: min(900px, 100%);
}

.vb-catalog-hero__title {
    margin: 0;
    font-size: clamp(28px, 4vw, 52px);
    font-weight: 800;
    line-height: 1.2;
    color: #fff;
    display: flex;
    flex-direction: column;
}

.vb-catalog-hero__lead {
    margin: 0;
    font-size: clamp(16px, 2vw, 24px);
    font-weight: 500;
    line-height: 1.4;
    color: #b8cccc;
    display: flex;
    flex-direction: column;
}

.vb-catalog-hero__cards {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
    width: 100%;
    align-items: stretch;
}

.vb-catalog-hero-card {
    border-radius: 24px;
    padding: 24px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 12px;
    color: #232929;
}

.vb-catalog-hero-card--accent {
    position: relative;
    overflow: visible;
    color: #fff;
    padding: 0;
    min-height: 139px;
    isolation: isolate;
}

.vb-catalog-hero-card--accent .vb-catalog-hero-card__title,
.vb-catalog-hero-card--accent .vb-catalog-hero-card__text,
.vb-catalog-hero-card--accent .vb-catalog-hero-card__line {
    color: #fff;
}

.vb-catalog-hero-card__accent-layers {
    position: absolute;
    inset: 0;
    z-index: 0;
    border-radius: 24px;
    overflow: hidden;
    pointer-events: none;
}

.vb-catalog-hero-card__accent-gradient {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background: linear-gradient(166.90664815336334deg, #54bfd1 0%, #239cb1 80.895%);
}

.vb-catalog-hero-card__accent-texture {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background-image: url("../images/main-page/catalog-hero-internship-texture.png");
    background-size: 183.2px 245.2px;
    background-position: 0 0;
    background-repeat: repeat;
    opacity: 0.07;
}

.vb-catalog-hero-card__accent-radial {
    position: absolute;
    inset: 0;
    border-radius: inherit;
    background-image: url("../images/main-page/catalog-hero-internship-radial.svg");
    background-size: 100% 100%;
    background-repeat: no-repeat;
    background-position: center;
}

.vb-catalog-hero-card__accent-copy {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: 24px;
    max-width: min(100%, calc(100% - 200px));
    box-sizing: border-box;
}

.vb-catalog-hero-card__accent-visual {
    position: absolute;
    z-index: 1;
    bottom: 0;
    left: calc(50% + 179.5px);
    width: min(443px, 52%);
    aspect-ratio: 443 / 186;
    height: auto;
    transform: translateX(-50%);
    pointer-events: none;
}

.vb-catalog-hero-card__accent-visual-frame {
    position: absolute;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
}

.vb-catalog-hero-card__accent-photo {
    position: absolute;
    left: -0.05%;
    top: -23.66%;
    width: 131.7%;
    height: 209.14%;
    max-width: none;
    display: block;
}

@media (max-width: 1200px) {
    .vb-catalog-hero-card__accent-visual {
        left: auto;
        right: 0;
        transform: none;
        width: min(320px, 48%);
    }

    .vb-catalog-hero-card__accent-copy {
        max-width: min(100%, calc(100% - 140px));
    }
}

@media (max-width: 640px) {
    .vb-catalog-hero-card__accent-visual {
        position: relative;
        left: auto;
        right: auto;
        transform: none;
        width: 100%;
        max-width: 443px;
        margin-inline: auto;
        margin-top: auto;
    }

    .vb-catalog-hero-card--accent {
        display: flex;
        flex-direction: column;
        min-height: 0;
    }

    .vb-catalog-hero-card__accent-copy {
        max-width: 100%;
    }
}

.vb-catalog-hero-card--white {
    background: #fff;
}

.vb-catalog-hero-card__title {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
    letter-spacing: -0.02em;
}

.vb-catalog-hero-card__text {
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.4;
}

.vb-catalog-hero-card__line {
    display: block;
}

/* Main block */
.vb-catalog-form {
    display: flex;
    flex-direction: column;
    gap: 32px;
    width: 100%;
}

.vb-catalog-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    width: 100%;
}

.vb-catalog-search--toolbar {
    flex: 0 1 500px;
}

.vb-catalog-main__title {
    margin: 0;
    font-size: clamp(32px, 4vw, 52px);
    font-weight: 800;
    line-height: 1.2;
    color: #232929;
}

.vb-catalog-layout {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    width: 100%;
}

.vb-catalog-filters {
    flex: 0 0 425px;
    max-width: 100%;
    background: #fff;
    border-radius: 24px;
    padding: 24px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    gap: 24px;
    position: sticky;
    top: 24px;
    align-self: flex-start;
}

.vb-catalog-filters__section {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.vb-catalog-filters__heading {
    margin: 0;
    font-size: 24px;
    font-weight: 800;
    line-height: 1.2;
    color: #232929;
}

.vb-catalog-filters__hint {
    margin: -4px 0 0;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.35;
    color: #5a6b6b;
}

.vb-catalog-filters__dates {
    display: flex;
    flex-wrap: wrap;
    gap: 12px 16px;
}

.vb-catalog-filters__date {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-size: 15px;
    font-weight: 500;
    color: #232929;
}

.vb-catalog-filters__date-label {
    font-size: 14px;
    color: #5a6b6b;
}

.vb-catalog-filters__date input[type="date"] {
    min-width: 0;
    max-width: 100%;
    padding: 8px 10px;
    border: 1px solid #b8cccc;
    border-radius: 6px;
    font: inherit;
    color: #232929;
    background: #fff;
}

.vb-catalog-check {
    display: flex;
    align-items: center;
    gap: 9px;
    cursor: pointer;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.2;
    color: #232929;
}

.vb-catalog-check input {
    position: absolute;
    opacity: 0;
    width: 1px;
    height: 1px;
    pointer-events: none;
}

.vb-catalog-check__box {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
    border: 1px solid #b8cccc;
    border-radius: 4px;
    box-sizing: border-box;
    position: relative;
    background: #fff;
}

.vb-catalog-check input:checked + .vb-catalog-check__box {
    border-color: #239cb1;
    background: #239cb1;
}

.vb-catalog-check input:checked + .vb-catalog-check__box::after {
    content: "";
    position: absolute;
    left: 5px;
    top: 2px;
    width: 5px;
    height: 10px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
}

.vb-catalog-check input:focus-visible + .vb-catalog-check__box {
    outline: 2px solid #239cb1;
    outline-offset: 2px;
}

/* Доп. пункты фильтра: плавное раскрытие */
.vb-catalog-filters__extra-shell {
    display: grid;
    grid-template-rows: 0fr;
    opacity: 0;
    transition:
        grid-template-rows 0.4s cubic-bezier(0.4, 0, 0.2, 1),
        opacity 0.32s ease;
}

.vb-catalog-filters__extra-shell.is-open {
    grid-template-rows: 1fr;
    opacity: 1;
}

.vb-catalog-filters__extra-shell > .vb-catalog-filters__extra {
    min-height: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.vb-catalog-filters__toggle {
    margin-top: 4px;
    align-self: flex-start;
    padding: 8px 0;
    border: none;
    background: none;
    cursor: pointer;
    font-family: inherit;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.3;
    color: #232929;
    text-decoration: underline;
    text-underline-offset: 3px;
    text-align: left;
}

.vb-catalog-filters__toggle:hover {
    color: #000000;
}

.vb-catalog-filters__toggle:focus-visible {
    outline: 2px solid #232929;
    outline-offset: 2px;
    border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
    .vb-catalog-filters__extra-shell {
        transition: none;
    }
}

.vb-catalog-filters__toggle-label[hidden] {
    display: none !important;
}

.vb-catalog-filters__actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    width: 100%;
}

.vb-catalog-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    padding: 12px 32px;
    border-radius: 12px;
    font-family: inherit;
    font-size: 18px;
    font-weight: 700;
    line-height: 1.4;
    text-decoration: none;
    text-align: center;
    box-sizing: border-box;
    border: none;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.vb-catalog-btn--primary {
    background: #f8485e;
    color: #fff;
}

.vb-catalog-btn--primary:hover {
    opacity: 0.94;
}

.vb-catalog-btn--outline {
    background: #fff;
    color: #f8485e;
    border: 1px solid #f8485e;
}

.vb-catalog-btn--outline:hover {
    opacity: 0.92;
}

.vb-catalog-results {
    flex: 1 1 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.vb-catalog-results.vb-catalog-results--loading {
    pointer-events: none;
}

.vb-catalog-results__surface {
    display: flex;
    flex-direction: column;
    gap: 20px;
    min-height: 1px;
    opacity: 1;
    transform: translateY(0);
    transition:
        opacity 0.32s cubic-bezier(0.4, 0, 0.2, 1),
        transform 0.36s cubic-bezier(0.22, 1, 0.36, 1);
    will-change: opacity, transform;
}

.vb-catalog-results__surface.vb-catalog-results__surface--out {
    opacity: 0;
    transform: translateY(10px);
}

.vb-catalog-results__surface.vb-catalog-results__surface--in-from {
    opacity: 0;
    transform: translateY(14px);
    transition: none;
}

@media (prefers-reduced-motion: reduce) {
    .vb-catalog-results__surface,
    .vb-catalog-results__surface.vb-catalog-results__surface--out,
    .vb-catalog-results__surface.vb-catalog-results__surface--in-from {
        transition: none !important;
        transform: none !important;
    }

    .vb-catalog-results__surface.vb-catalog-results__surface--out,
    .vb-catalog-results__surface.vb-catalog-results__surface--in-from {
        opacity: 1;
    }
}

.vb-catalog-search {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    max-width: 500px;
    padding: 16px 24px;
    background: #fff;
    border: 2px solid #b8cccc;
    border-radius: 12px;
    box-sizing: border-box;
}

.vb-catalog-search__icon {
    flex-shrink: 0;
    display: flex;
}

.vb-catalog-search__input {
    flex: 1 1 auto;
    min-width: 0;
    border: none;
    background: transparent;
    font-family: inherit;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.4;
    color: #232929;
}

.vb-catalog-search__input::placeholder {
    color: #b8cccc;
}

.vb-catalog-search__input:focus {
    outline: none;
}

.vb-catalog-search:focus-within {
    border-color: #239cb1;
}

/* Сетка карточек — как .home-catalog-grid на главной */
.vb-catalog-grid {
    display: grid;
    width: 100%;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: minmax(472px, auto);
    gap: 20px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.vb-catalog-empty {
    margin: 0;
    padding: 32px 16px;
    text-align: center;
    font-size: 18px;
    font-weight: 500;
    line-height: 1.45;
    color: #232929;
    background: #fff;
    border-radius: 24px;
}

.vb-catalog-pagination {
    margin-top: 8px;
}

.vb-catalog-pagination .page-numbers {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 8px;
    align-items: center;
    list-style: none;
    margin: 0;
    padding: 0;
}

.vb-catalog-pagination a.page-numbers,
.vb-catalog-pagination span.page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 44px;
    height: 44px;
    padding: 0 12px;
    border-radius: 12px;
    font-size: 16px;
    font-weight: 600;
    text-decoration: none;
    color: #232929;
    background: #fff;
    border: 1px solid #b8cccc;
}

.vb-catalog-pagination a.page-numbers:hover {
    border-color: #239cb1;
    color: #239cb1;
}

.vb-catalog-pagination span.page-numbers.current {
    background: #239cb1;
    border-color: #239cb1;
    color: #fff;
}

@media (max-width: 1200px) {
    .vb-catalog-hero__cards {
        grid-template-columns: 1fr;
    }

    .vb-catalog-layout {
        flex-direction: column;
    }

    .vb-catalog-filters {
        flex: none;
        width: 100%;
        position: static;
    }

    .vb-catalog-search--toolbar {
        flex: 1 1 100%;
        max-width: none;
    }
}

@media (min-width: 1200px) and (max-width: 1759px) {
    .vb-catalog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-auto-rows: minmax(502px, auto);
        gap: 24px;
    }

    .vb-catalog-grid .home-course-card,
    .vb-catalog-grid .home-course-card__link {
        min-height: 502px;
    }
}

@media (min-width: 721px) and (max-width: 1199px) {
    .vb-catalog-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-auto-rows: minmax(472px, auto);
        gap: 20px;
    }
}

@media (max-width: 900px) {
    .vb-catalog-grid {
        grid-template-columns: 1fr;
        grid-auto-rows: minmax(472px, auto);
        gap: 16px;
    }
}

@media (max-width: 640px) {
    .vb-catalog-hero__photo-wrap {
        opacity: 0.35;
    }

    .vb-catalog-hero__content {
        min-height: auto;
    }

    .vb-catalog-hero {
        min-height: auto;
    }
}
