.team-profile {
    padding: 90px 0 110px;
    background: #ffffff;
    color: #171717;
    font-family: var(--font-family, "Space Grotesk", sans-serif);
}

.team-profile__container {
    width: min(1360px, calc(100% - 40px));
    margin: 0 auto;
}

.team-profile__layout {
    display: grid;
    gap: 90px;
    grid-template-columns: 43% 1fr;
    align-items: start;
}

.team-profile__sidebar,
.team-profile__main {
    min-width: 0;
    padding: 0 10px;
}

.team-profile__portrait {
    position: relative;
    margin: 0;
    overflow: hidden;
    border-top: 3px solid #f45100;
    background: #f1f1f1;
}

.team-profile__portrait-image,
.team-profile__portrait-placeholder {
    display: block;
    width: 100%;
    aspect-ratio: 0.82;
}

.team-profile__portrait-image {
    height: auto;
    object-fit: cover;
    object-position: center top;
}

.team-profile__portrait-placeholder {
    display: grid;
    place-items: center;
    color: #aaa;
    font-size: 90px;
}

.team-profile__contact {
    position: relative;
    overflow: hidden;
    padding: 42px 52px 50px;
    background: #f45100;
    color: #ffffff;
    text-align: center;
}

.team-profile__contact::after {
    content: "";
    position: absolute;
    right: -65px;
    bottom: -65px;
    width: 250px;
    height: 250px;
    border: 26px dotted rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    pointer-events: none;
}

.team-profile__contact > * {
    position: relative;
    z-index: 1;
}

.team-profile__contact h2 {
    margin: 0 0 12px;
    color: #ffffff;
    font-family: inherit;
    font-size: 25px;
    font-weight: 700;
    line-height: 1.25;
}

.team-profile__contact-description {
    max-width: 300px;
    margin: 0 auto 28px;
    color: rgba(255, 255, 255, 0.9);
    font-size: 13px;
    line-height: 1.65;
}

.team-profile__contact-form,
.team-profile__contact-form .wpcf7,
.team-profile__contact-form .wpcf7-form {
    width: 100%;
}

.team-profile__contact-form .wpcf7-form p {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    margin: 0 0 12px;
    line-height: 0;
}

.team-profile__contact-form .wpcf7-form p > br {
    display: none;
}

.team-profile__contact-form .wpcf7-form label {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 7px;
    width: 100%;
    color: #ffffff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 500;
    line-height: 1.4;
    text-align: left;
}

.team-profile__contact-form .wpcf7-form label > br {
    display: none;
}

.team-profile__contact-form .wpcf7-form-control-wrap {
    display: block;
    width: 100%;
    line-height: 0;
}

.team-profile__contact-form .wpcf7-form-control:not(.wpcf7-submit) {
    display: block;
    width: 100%;
    min-height: 46px;
    box-sizing: border-box;
    padding: 12px 15px;
    color: #ffffff;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.7);
    border-radius: 0;
    box-shadow: none;
    outline: none;
    font-family: inherit;
    font-size: 13px;
    line-height: 1.5;
}

.team-profile__contact-form textarea.wpcf7-form-control {
    height: 112px;
    min-height: 112px;
    resize: vertical;
}

.team-profile__contact-form input::placeholder,
.team-profile__contact-form textarea::placeholder {
    color: #ffffff;
    opacity: 1;
}

.team-profile__contact-form .wpcf7-form-control:not(.wpcf7-submit):focus {
    border-color: #ffffff;
    background: rgba(255, 255, 255, 0.12);
}

.team-profile__contact-form .wpcf7-submit {
    width: 100%;
    min-height: 48px;
    margin: 2px 0 0;
    padding: 13px 20px;
    color: #202020;
    background: #ffffff;
    border: 0;
    border-radius: 0;
    font-family: inherit;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.2;
    cursor: pointer;
}

.team-profile__contact-form .wpcf7-submit:hover,
.team-profile__contact-form .wpcf7-submit:focus {
    color: #ffffff;
    background: #202020;
}

.team-profile__contact-form .wpcf7-spinner {
    margin-top: 10px;
}

.team-profile__contact-form .wpcf7-not-valid-tip {
    margin-top: 5px;
    color: #ffffff;
    font-size: 12px;
    line-height: 1.4;
    text-align: left;
}

.team-profile__contact-form .wpcf7-response-output {
    margin: 16px 0 0 !important;
    padding: 10px !important;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.75) !important;
    font-size: 12px;
    line-height: 1.4;
    text-align: left;
}

.team-profile__header {
    padding-top: 2px;
}

.team-profile__greeting {
    margin: 0 0 8px;
    color: #333333;
    font-size: 16px;
    line-height: 1.4;
}

.team-profile__name {
    margin: 0 0 7px;
    color: #111111;
    font-family: inherit;
    font-size: clamp(34px, 4vw, 48px);
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: -0.025em;
}

.team-profile__position {
    margin: 0;
    color: #666666;
    font-size: 14px;
    line-height: 1.5;
}

.team-profile__facts {
    display: grid;
    gap: 13px;
    margin: 25px 0 0;
    padding: 23px 0;
    border-top: 1px solid #dedede;
    border-bottom: 1px solid #dedede;
}

.team-profile__fact {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 14px;
    align-items: baseline;
}

.team-profile__fact dt,
.team-profile__fact dd {
    margin: 0;
    font-size: 14px;
    line-height: 1.45;
}

.team-profile__fact dt {
    color: #151515;
    font-weight: 600;
}

.team-profile__fact dd,
.team-profile__fact a {
    color: #666666;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.team-profile__fact a:hover {
    color: #f45100;
}

.team-profile__socials {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
}

.team-profile__socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    color: #666666;
    background: #ececef;
    font-size: 14px;
    font-weight: 700;
    text-decoration: none;
}

.team-profile__socials a:hover,
.team-profile__socials a:focus {
    color: #ffffff;
    background: #f45100;
}

.team-profile__section {
    margin-top: 48px;
}

.team-profile__section h2 {
    margin: 0 0 17px;
    color: #171717;
    font-family: inherit;
    font-size: 27px;
    font-weight: 700;
    line-height: 1.25;
}

.team-profile__rich-text,
.team-profile__skills-description {
    color: #666666;
    font-size: 14px;
    line-height: 1.8;
}

.team-profile__rich-text > :first-child {
    margin-top: 0;
}

.team-profile__rich-text > :last-child {
    margin-bottom: 0;
}

.team-profile__education-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 36px;
}

.team-profile__education-item {
    display: grid;
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
}

.team-profile__education-logo {
    display: grid;
    place-items: center;
    width: 46px;
    height: 46px;
    overflow: hidden;
    color: #f45100;
    background: #f4f4f4;
    border-radius: 50%;
    font-size: 22px;
}

.team-profile__education-logo img {
    width: 28px;
    height: 28px;
    object-fit: contain;
}

.team-profile__education-item h3 {
    margin: 0 0 5px;
    color: #171717;
    font-family: inherit;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.35;
}

.team-profile__education-item p {
    margin: 0;
    color: #777777;
    font-size: 12px;
    line-height: 1.5;
}

.team-profile__skills-description {
    margin: 0 0 25px;
}

.team-profile__skill-list {
    display: grid;
    gap: 20px;
}

.team-profile__skill-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 8px;
    color: #242424;
    font-size: 12px;
    line-height: 1.4;
}

.team-profile__skill-heading strong {
    font-weight: 600;
}

.team-profile__skill-track {
    position: relative;
    height: 3px;
    overflow: hidden;
    background: #dedede;
}

.team-profile__skill-track span {
    position: absolute;
    inset: 0 auto 0 0;
    display: block;
    max-width: 100%;
    background: #f45100;
}

@media (max-width: 1024px) {
    .team-profile {
        padding: 65px 0 85px;
    }

    .team-profile__layout {
        grid-template-columns: minmax(290px, 0.9fr) minmax(0, 1.1fr);
        gap: 42px;
    }

    .team-profile__contact {
        padding: 36px 30px 42px;
    }
}

@media (max-width: 767px) {
    .team-profile {
        padding: 45px 0 65px;
    }

    .team-profile__container {
        width: min(100% - 30px, 580px);
    }

    .team-profile__layout {
        grid-template-columns: 1fr;
        gap: 45px;
    }

    .team-profile__name {
        font-size: 36px;
    }

    .team-profile__section {
        margin-top: 38px;
    }

    .team-profile__education-grid {
        grid-template-columns: 1fr;
        gap: 22px;
    }
}

@media (max-width: 420px) {
    .team-profile__contact {
        padding: 32px 20px 36px;
    }

    .team-profile__fact {
        grid-template-columns: 100px minmax(0, 1fr);
        gap: 10px;
    }
}
