body.solartek-portfolio-pages-v2,
body.solartek-portfolio-pages-v2 * {
    box-sizing: border-box;
}

body.solartek-portfolio-pages-v2 h1.w-post-elm.post_title {
    max-width: 1100px;
    margin-bottom: 10px;
    font-size: clamp(40px, 5vw, 60px);
    line-height: 1.02;
    letter-spacing: -.045em;
    text-wrap: balance;
}

body.solartek-portfolio-pages-v2 .g-breadcrumbs {
    margin-bottom: 10px;
    color: #777;
    font-size: 13px;
}

.solartek-portfolio-intro {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    margin: 2px 0 22px;
}

.solartek-portfolio-intro__subtitle {
    margin: 0 !important;
    color: #686868;
    font-size: 16px;
    line-height: 1.45;
}

.solartek-portfolio-intro__tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.solartek-portfolio-intro__tag {
    display: inline-flex;
    min-height: 34px;
    align-items: center;
    padding: 6px 11px;
    border: 1px solid #deded9;
    border-radius: 999px;
    color: #555;
    background: #fff;
    font-size: 14px;
    line-height: 1.2;
}

.solartek-portfolio-showcase {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(270px, .82fr);
    align-items: stretch;
    gap: clamp(14px, 2vw, 22px);
}

.solartek-portfolio-showcase.has-no-bridge {
    grid-template-columns: minmax(0, 1fr);
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery {
    min-width: 0;
    margin: 0;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-list {
    display: grid !important;
    position: relative !important;
    width: 100% !important;
    height: clamp(470px, 47vw, 620px) !important;
    min-height: 470px;
    margin: 0 !important;
    grid-template-columns: minmax(0, 2fr) repeat(2, minmax(0, 1fr));
    grid-template-rows: repeat(2, minmax(0, 1fr));
    grid-auto-flow: dense;
    align-items: stretch !important;
    gap: 8px;
    aspect-ratio: 1.43 / 1;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item {
    position: relative !important;
    top: auto !important;
    left: auto !important;
    width: auto !important;
    min-width: 0;
    min-height: 0;
    padding: 0 !important;
    overflow: hidden;
    border-radius: 12px;
    transform: none !important;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item-img {
    position: absolute !important;
    inset: 0;
    height: 100% !important;
    padding: 0 !important;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item-img img {
    display: block;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover;
    transition: transform .28s ease;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item-link {
    position: absolute;
    z-index: 2;
    inset: 0;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item:first-child {
    grid-column: 1;
    grid-row: 1 / span 2;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item:first-child .w-gallery-item-link::after {
    content: "Открыть фото";
    position: absolute;
    right: 14px;
    bottom: 14px;
    padding: 7px 10px;
    border-radius: 7px;
    color: #fff;
    background: rgba(18, 19, 21, .82);
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
    pointer-events: none;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .solartek-portfolio-gallery--limited .solartek-portfolio-gallery__overflow {
    display: none !important;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .solartek-portfolio-gallery__more .w-gallery-item-link::after {
    content: attr(data-more-label);
    position: absolute;
    display: grid;
    z-index: 3;
    inset: 0;
    place-items: center;
    color: #fff;
    background: rgba(18, 19, 21, .56);
    font-size: clamp(18px, 2vw, 26px);
    font-weight: 800;
    line-height: 1;
    pointer-events: none;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_1 .w-gallery-list {
    display: block !important;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_1 .w-gallery-item {
    width: 100% !important;
    height: 100% !important;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_2 .w-gallery-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: minmax(0, 1fr);
    aspect-ratio: 1.8 / 1;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_2 .w-gallery-item:first-child {
    grid-column: auto;
    grid-row: auto;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_3 .w-gallery-list {
    grid-template-columns: minmax(0, 2fr) minmax(180px, .82fr);
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_4 .w-gallery-list {
    grid-template-columns: minmax(0, 2fr) minmax(180px, .82fr);
    grid-template-rows: repeat(3, minmax(0, 1fr));
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_4 .w-gallery-item:first-child {
    grid-row: 1 / span 3;
}

body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_5 .w-gallery-list {
    grid-template-columns: minmax(0, 2fr) repeat(2, minmax(135px, .82fr));
}

@media (hover: hover) and (pointer: fine) {
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item:hover img {
        transform: scale(1.025);
    }
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge {
    display: flex;
    min-width: 0;
    flex-direction: column;
    align-items: stretch;
    justify-content: center;
    gap: 22px;
    margin: 0 !important;
    padding: clamp(22px, 3vw, 32px) !important;
    border-radius: 14px;
    background:
        radial-gradient(circle at 100% 0, rgba(244, 122, 34, .58), transparent 42%),
        linear-gradient(145deg, #18191b, #0e0f10 82%);
    box-shadow: none;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge__copy,
body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge__actions {
    width: 100%;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge__eyebrow {
    margin-bottom: 8px;
    font-size: 11px;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge h2 {
    margin-bottom: 12px;
    font-size: clamp(28px, 3vw, 40px);
    line-height: 1.02;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge p {
    font-size: 15px;
    line-height: 1.55;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge__actions {
    display: grid;
    gap: 9px;
}

.solartek-portfolio-more-photos {
    margin-top: clamp(26px, 4vw, 40px);
}

.solartek-portfolio-more-photos__header {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
}

.solartek-portfolio-more-photos__header h2 {
    margin: 0;
    color: #18191b;
    font-size: clamp(27px, 3vw, 38px);
    line-height: 1.05;
    letter-spacing: -.035em;
}

.solartek-portfolio-more-photos__count {
    flex: 0 0 auto;
    padding: 7px 11px;
    border: 1px solid #deded9;
    border-radius: 999px;
    color: #5c5e61;
    background: #fff;
    font-size: 13px;
    font-weight: 700;
    line-height: 1;
}

.solartek-portfolio-more-photos__grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.solartek-portfolio-more-photos__item {
    position: relative;
    min-width: 0;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 12px;
    aspect-ratio: 4 / 3;
    background: #e9e9e6;
    cursor: pointer;
}

.solartek-portfolio-more-photos__item[hidden] {
    display: none !important;
}

.solartek-portfolio-more-photos__item img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .28s ease, filter .28s ease;
}

.solartek-portfolio-more-photos__item:focus-visible {
    outline: 3px solid #f47a22;
    outline-offset: 3px;
}

.solartek-portfolio-more-photos__toggle {
    display: inline-flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    margin-top: 16px;
    padding: 10px 18px;
    border: 1px solid #292a2d;
    border-radius: 8px;
    color: #fff;
    background: #18191b;
    font-size: 15px;
    font-weight: 700;
    line-height: 1.2;
    cursor: pointer;
}

.solartek-portfolio-more-photos__toggle:hover,
.solartek-portfolio-more-photos__toggle:focus-visible {
    border-color: #f47a22;
    background: #f47a22;
}

@media (hover: hover) and (pointer: fine) {
    .solartek-portfolio-more-photos__item:hover img {
        filter: brightness(.9);
        transform: scale(1.025);
    }
}

.solartek-portfolio-about {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(270px, .48fr);
    gap: clamp(26px, 4vw, 52px);
    margin-top: clamp(30px, 5vw, 54px);
    padding: clamp(24px, 4vw, 38px);
    border: 1px solid #e6e6e1;
    border-radius: 14px;
    background: #f7f7f5;
}

.solartek-portfolio-about h2 {
    margin: 0 0 10px;
    color: #18191b;
    font-size: clamp(28px, 3.4vw, 42px);
    line-height: 1.04;
    letter-spacing: -.035em;
}

.solartek-portfolio-about__copy > p {
    max-width: 760px;
    margin: 0;
    color: #56585c;
    font-size: 16px;
    line-height: 1.65;
}

.solartek-portfolio-about__facts {
    align-self: start;
    margin: 0;
}

.solartek-portfolio-about__fact {
    display: grid;
    grid-template-columns: minmax(90px, 1fr) minmax(0, 1.25fr);
    gap: 16px;
    padding: 12px 0;
    border-bottom: 1px solid #deded9;
}

.solartek-portfolio-about__fact:first-child {
    padding-top: 2px;
}

.solartek-portfolio-about__fact dt,
.solartek-portfolio-about__fact dd {
    margin: 0;
}

.solartek-portfolio-about__fact dt {
    color: #777;
}

.solartek-portfolio-about__fact dd {
    color: #18191b;
    font-weight: 700;
    text-align: right;
    overflow-wrap: anywhere;
}

.solartek-portfolio-about__details {
    margin-top: 22px;
    border-top: 1px solid #deded9;
}

.solartek-portfolio-about__details summary {
    padding: 16px 0 8px;
    color: #222326;
    font-weight: 700;
    cursor: pointer;
}

.solartek-portfolio-about__details-body {
    padding-top: 8px;
}

.solartek-portfolio-about__details-body p {
    margin: 0 0 16px;
    color: #56585c;
    font-size: 15px;
    line-height: 1.65;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 h2:not(.w-post-elm) {
    margin-bottom: 0;
    color: #fff;
    font-size: clamp(30px, 4vw, 48px);
    line-height: 1.05;
    letter-spacing: -.035em;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 .w-grid-item[hidden] {
    display: none !important;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 .w-grid-list {
    align-items: stretch;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 .w-grid-item-h {
    height: 100%;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, .16);
    border-radius: 12px;
    background: rgba(255, 255, 255, .06);
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 .post_image {
    margin-bottom: 0 !important;
    overflow: hidden;
    aspect-ratio: 3 / 2;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 .post_image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

body.solartek-portfolio-pages-v2 .solartek-portfolio-related-v2 h2.w-post-elm.post_title {
    margin: 0 !important;
    padding: 16px 18px 20px;
    color: #fff;
    font-size: 17px !important;
    line-height: 1.35;
    letter-spacing: -.01em;
}

@media (max-width: 960px) {
    .solartek-portfolio-showcase {
        grid-template-columns: minmax(0, 1.55fr) minmax(250px, .8fr);
    }

    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-list {
        min-height: 400px;
    }

    .solartek-portfolio-more-photos__grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    body.solartek-portfolio-pages-v2 h1.w-post-elm.post_title {
        margin-bottom: 8px;
        font-size: clamp(32px, 10vw, 40px);
        line-height: 1.02;
    }

    .solartek-portfolio-intro {
        display: block;
        margin-bottom: 18px;
    }

    .solartek-portfolio-intro__subtitle {
        margin-bottom: 12px !important;
    }

    .solartek-portfolio-intro__tags {
        justify-content: flex-start;
    }

    .solartek-portfolio-intro__tag {
        min-height: 32px;
        font-size: 13px;
    }

    .solartek-portfolio-showcase,
    .solartek-portfolio-about {
        grid-template-columns: minmax(0, 1fr);
    }

    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-list,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_2 .w-gallery-list,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_3 .w-gallery-list,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_4 .w-gallery-list,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_5 .w-gallery-list {
        height: auto !important;
        min-height: 0;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        grid-template-rows: none;
        grid-auto-rows: auto;
        aspect-ratio: auto;
    }

    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item:first-child,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_2 .w-gallery-item:first-child,
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_4 .w-gallery-item:first-child {
        grid-column: auto;
        grid-row: auto;
        aspect-ratio: 4 / 3;
    }

    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item:first-child {
        grid-column: 1 / -1;
    }

    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery.count_2 .w-gallery-item:nth-child(2) {
        grid-column: 1 / -1;
    }

    body.solartek-portfolio-pages-v2 .solartek-portfolio-showcase .solartek-portfolio-bridge {
        gap: 20px;
        padding: 24px 18px !important;
    }

    .solartek-portfolio-more-photos {
        margin-top: 28px;
    }

    .solartek-portfolio-more-photos__header {
        align-items: center;
        gap: 12px;
    }

    .solartek-portfolio-more-photos__header h2 {
        font-size: 28px;
    }

    .solartek-portfolio-more-photos__grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 8px;
        margin-top: 14px;
    }

    .solartek-portfolio-more-photos__item {
        border-radius: 10px;
    }

    .solartek-portfolio-more-photos__toggle {
        width: 100%;
    }

    .solartek-portfolio-about {
        gap: 24px;
        padding: 24px 18px;
    }

    .solartek-portfolio-about__fact {
        grid-template-columns: minmax(90px, 1fr) minmax(0, 1.2fr);
    }
}

@media (prefers-reduced-motion: reduce) {
    body.solartek-portfolio-pages-v2 .w-post-elm.post_content .w-gallery-item-img img,
    .solartek-portfolio-more-photos__item img {
        transition: none;
    }
}
