.team-section{
    position:relative;
    padding:72px 0;
    overflow:hidden;
    background:#f9eaea
}

.team-shell{
    position:relative;
    display:grid;
    grid-template-columns:minmax(270px,.78fr) minmax(0,2.15fr);
    align-items:center;
    gap:clamp(38px,5vw,76px)
}

.team-intro{
    position:relative;
    z-index:2;
    max-width:330px
}

.team-grid{
    position:relative;
    z-index:2;
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:14px;
    min-width:0
}

.team-grid--carousel{
    grid-template-columns:none;
    grid-auto-flow:column;
    grid-auto-columns:calc((100% - 42px) / 4);
    overflow-x:auto;
    scroll-snap-type:x mandatory;
    scrollbar-width:none;
    overscroll-behavior-x:contain
}

.team-grid--carousel>.team-card{
    scroll-snap-align:start
}

.team-carousel{
    position:relative;
    min-width:0
}

.team-carousel-controls{
    position:absolute;
    z-index:3;
    left:-28px;
    right:-28px;
    top:50%;
    display:flex;
    align-items:center;
    justify-content:space-between;
    transform:translateY(-50%);
    pointer-events:none
}

.team-carousel-controls[hidden]{
    display:none
}

.team-carousel-controls button{
    width:28px;
    height:40px;
    padding:0;
    border:0;
    background:transparent;
    color:#a95169;
    cursor:pointer;
    font-family:var(--script);
    font-size:46px;
    font-weight:700;
    line-height:1;
    transition:color .2s ease,transform .2s ease;
    pointer-events:auto
}

.team-carousel-controls button:not(:disabled):hover,
.team-carousel-controls button:focus-visible{
    color:#b76878;
    transform:scale(1.08)
}

.team-carousel-controls button:disabled{
    opacity:.55;
    cursor:default
}

.team-art{
    position:absolute;
    z-index:0;
    top:50%;
    right:-135px;
    width:210px;
    aspect-ratio:637 / 949;
    transform:translateY(-50%);
    pointer-events:none
}

.team-art-blob{
    position:absolute;
    z-index:0;
    top:14%;
    right:-12%;
    width:135%;
    height:74%;
    border-radius:57% 43% 61% 39% / 43% 56% 44% 57%;
    background:rgba(237,183,189,.38);
    transform:rotate(9deg)
}

.team-art-svg{
    position:relative;
    z-index:1;
    display:block;
    width:100%;
    height:100%;
    overflow:visible
}

.team-art-source{
    fill:#8f5967;
    opacity:.48
}

.team-art-reveal-path{
    fill:none;
    stroke:#fff;
    stroke-width:102;
    stroke-linecap:round;
    stroke-linejoin:round;
    stroke-dasharray:1;
    stroke-dashoffset:1
}

.team-art-reveal-path--detail{
    stroke-width:72
}

.team-art-reveal-path--base{
    stroke-width:34
}

.team-art.is-drawing .team-art-reveal-path{
    animation:teamArtDraw var(--draw-duration) cubic-bezier(.22,.61,.36,1) var(--draw-delay) forwards
}

@keyframes teamArtDraw{
    to{
        stroke-dashoffset:0
    }
}

.team-intro h2{
    margin:0;
    color:#4d3d42;
    font-family:var(--serif);
    font-size:calc(clamp(42px,3.6vw,58px) - 2px);
    line-height:.98;
    font-weight:500
}

.team-text{
    max-width:310px;
    margin:24px 0 0;
    color:#66555a;
    font-size:16px;
    line-height:1.65
}

.team-cta{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    min-height:46px;
    margin-top:28px;
    padding:0 24px;
    border-radius:999px;
    background:#c86f82;
    color:#fff;
    font-size:11px;
    line-height:1;
    font-weight:700;
    letter-spacing:.04em;
    text-decoration:none;
    text-transform:uppercase;
    transition:background-color .2s ease
}

.team-cta:hover{
    background:#b95f73
}

.team-card{
    min-width:0;
    overflow:hidden;
    border:1px solid rgba(224,202,205,.72);
    border-radius:20px;
    background:#fffaf8;
    cursor:pointer;
    outline:none;
    transition:border-color .2s ease,background-color .2s ease
}

.team-card:hover,
.team-card:focus-visible{
    border-color:rgba(200,111,130,.55);
    background:#fff6f4
}

.team-photo{
    position:relative;
    height:245px;
    overflow:hidden;
    background:#eadbd6
}

.team-photo img{
    display:block;
    width:100%;
    height:100%;
    object-fit:cover;
    object-position:center 20%;
}

.team-photo--maria img{object-position:center calc(20% - 30px);}
.team-photo--vyara img{object-position:center calc(17% - 24px);}
.team-photo--simona img{object-position:center top;}
.team-photo--viki img{transform:scale(1.45);transform-origin:center 35%;}

@media(max-width:767px){
    .team-photo--maria img{object-position:center calc(20% - 40px);}
    .team-photo--vyara img{object-position:center calc(17% - 33px);}
}

.team-photo-placeholder{
    display:block;
    width:100%;
    height:100%;
    background:#eadbd6
}

.team-card-body{
    min-height:150px;
    padding:17px 14px 16px;
    display:flex;
    flex-direction:column;
    align-items:center;
    text-align:center
}

.team-card h3{
    margin:0;
    color:#4e3e43;
    font-family:var(--serif);
    font-size:25px;
    line-height:1.05;
    font-weight:600
}

.team-card p{
    min-height:38px;
    margin:7px 0 0;
    color:#79686d;
    font-size:12px;
    line-height:1.45
}

.team-socials{
    display:flex;
    align-items:center;
    justify-content:center;
    gap:4px;
    margin-top:auto
}

.team-social{
    width:34px;
    height:34px;
    margin-top:auto;
    display:grid;
    place-items:center;
    color:#7d696e;
    text-decoration:none;
    transition:color .2s ease
}

.team-socials .team-social{
    margin-top:0
}

.team-social:hover{
    color:#c86f82
}

.team-social svg{
    width:20px;
    height:20px;
    fill:none;
    stroke:currentColor;
    stroke-width:1.8;
    stroke-linecap:round;
    stroke-linejoin:round
}

.team-modal{
    position:fixed;
    inset:0;
    z-index:9999;
    display:flex;
    align-items:center;
    justify-content:center;
    padding:24px;
    opacity:0;
    visibility:hidden;
    transition:opacity .28s ease,visibility .28s ease
}

.team-modal.is-open{
    opacity:1;
    visibility:visible
}

.team-modal-backdrop{
    position:absolute;
    inset:0;
    background:rgba(61,43,48,.48);
    backdrop-filter:blur(8px);
    -webkit-backdrop-filter:blur(8px)
}

.team-modal-dialog{
    position:relative;
    z-index:2;
    width:min(100%,980px);
    max-height:min(88vh,820px);
    overflow:hidden;
    border:1px solid rgba(226,205,208,.78);
    border-radius:28px;
    background:#fffaf8;
    box-shadow:0 28px 90px rgba(68,42,49,.2);
    transform:translateY(16px) scale(.985);
    transition:transform .28s ease
}

.team-modal.is-open .team-modal-dialog{
    transform:translateY(0) scale(1)
}

.team-modal-close{
    position:absolute;
    top:16px;
    right:18px;
    z-index:4;
    width:40px;
    height:40px;
    display:grid;
    place-items:center;
    padding:0;
    border:0;
    border-radius:50%;
    background:rgba(255,250,248,.88);
    color:#b76878;
    cursor:pointer;
    font-size:30px;
    line-height:1
}

.team-modal-layout{
    display:grid;
    grid-template-columns:minmax(300px,.78fr) minmax(0,1.22fr);
    max-height:min(88vh,820px)
}

.team-modal-photo{
    min-height:620px;
    background:#eadbd6
}

.team-modal-photo img{
    display:block;
    width:100%;
    height:100%;
    object-fit:cover;
}

.team-modal-image-placeholder{
    display:block;
    width:100%;
    height:100%;
    min-height:620px;
    background:#eadbd6
}

.team-modal-content{
    min-height:0;
    max-height:min(88vh,820px);
    overflow-y:auto;
    overscroll-behavior:contain;
    padding:50px 50px 46px
}

.team-modal-kicker{
    margin:0 0 10px;
    color:#c86f82;
    font-size:12px;
    line-height:1;
    font-weight:700;
    letter-spacing:.12em;
    text-transform:uppercase
}

.team-modal-content>h2{
    margin:0;
    color:#4e3e43;
    font-family:var(--serif);
    font-size:48px;
    line-height:.95;
    font-weight:600
}

.team-modal-role{
    margin:10px 0 0;
    color:#c86f82;
    font-size:14px;
    line-height:1.4;
    font-weight:600
}

.team-modal-section{
    margin-top:30px
}

.team-modal-section h3{
    margin:0 0 10px;
    color:#58464b;
    font-family:var(--serif);
    font-size:22px;
    line-height:1.15;
    font-weight:600
}

.team-modal-section p,
.team-modal-story{
    margin:0;
    color:#6d5c61;
    font-size:15px;
    line-height:1.7
}

.team-modal-story p{
    margin:0
}

.team-modal-story p+p{
    margin-top:14px
}

.team-modal-education{
    margin:0;
    padding:0;
    list-style:none
}

.team-modal-education li{
    position:relative;
    margin:9px 0;
    padding-left:20px;
    color:#6d5c61;
    font-size:14px;
    line-height:1.55
}

.team-modal-education li::before{
    content:"";
    position:absolute;
    top:.7em;
    left:0;
    width:7px;
    height:7px;
    border-radius:50%;
    background:#c86f82;
    transform:translateY(-50%)
}

@media(max-width:1100px){
    .team-shell{
        grid-template-columns:1fr;
        gap:36px
    }

    .team-intro{
        max-width:560px;
        margin:0 auto;
        text-align:center
    }

    .team-text{
        max-width:520px
    }

    .team-grid{
        grid-template-columns:repeat(2,minmax(0,1fr))
    }

    .team-grid--carousel{
        grid-template-columns:none;
        grid-auto-columns:calc((100% - 14px) / 2)
    }

    .team-photo{
        height:300px
    }

    .team-art{
        top:60%;
        right:-80px;
        width:175px;
        opacity:.8
    }
}

@media(max-width:760px){
    .team-art{
        top:64%;
        right:-72px;
        width:145px;
        opacity:.5
    }

    .team-modal{
        padding:14px
    }

    .team-modal-dialog{
        overflow:auto;
        max-height:92vh;
        border-radius:22px
    }

    .team-modal-layout{
        display:block;
        max-height:none
    }

    .team-modal-photo{
        min-height:0;
        container-type:inline-size;
        height:310px
    }

    .team-modal-photo img{
        object-position:center top;
    }

    .team-modal-photo[data-portrait="simona"] img{object-position:center calc(8px - 4cqw);}

    .team-modal-photo[data-portrait="maria"] img{object-position:center calc(8px - 30cqw);}
    .team-modal-photo[data-portrait="vyara"] img{object-position:center calc(8px - 22.5cqw);}
    .team-modal-photo[data-portrait="marina"] img{object-position:center calc(8px - 17cqw);}

    .team-modal-image-placeholder{
        min-height:0;
        height:100%
    }

    .team-modal-content{
        max-height:none;
        overflow:visible;
        padding:34px 26px 32px
    }

    .team-modal-content>h2{
        font-size:40px
    }

    .team-modal-close{
        top:12px;
        right:12px
    }
}

@media(max-width:620px){
    .team-section{
        padding:58px 0
    }

    .team-carousel-controls{
        left:-18px;
        right:-18px
    }

    .team-intro h2{
        font-size:calc(clamp(38px,11vw,48px) - 2px)
    }

    .team-text{
        font-size:15px
    }

    .team-grid{
        display:flex;
        gap:14px;
        overflow-x:auto;
        scroll-snap-type:x mandatory;
        scrollbar-width:none
    }

    .team-grid::-webkit-scrollbar{
        display:none
    }

    .team-card{
        flex:0 0 82%;
        scroll-snap-align:start
    }

    .team-photo{
        height:310px
    }

    .team-art{
        top:68%;
        right:-78px;
        width:132px;
        opacity:.4
    }

    .team-modal-photo{
        height:280px
    }


    .team-modal-content{
        padding:32px 22px 28px
    }

    .team-modal-content>h2{
        font-size:36px
    }

    .team-modal-section{
        margin-top:24px
    }

    .team-modal-section p,
    .team-modal-story{
        font-size:14px;
        line-height:1.65
    }
}

@media(prefers-reduced-motion:reduce){
    .team-card,
    .team-modal,
    .team-modal-dialog{
        transition:none!important
    }

    .team-art-reveal-path{
        stroke-dashoffset:0;
        animation:none!important
    }
}
