/* Services and Programs */
.am-services-page__container,
.am-programs-page__container {
    padding-top: 28px;
    padding-bottom: 64px;
}

.am-services-page__header,
.am-programs-page__header {
    margin: 0 auto 34px;
}

.am-services-page__header h1,
.am-programs-page__header h1 {
    margin: 0 0 18px;
    color: #3E5338;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
}

.am-services-page__intro,
.am-programs-page__header p {
    color: #282828;
    font-size: 16px;
    line-height: 1.45;
}

.am-services-page__intro p:last-child {
    margin-bottom: 0;
}

.am-services-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
}

.am-service-card {
    min-width: 0;
    display: flex;
    flex-direction: column;
    border: 1px solid #C9CCC5;
    border-radius: 4px;
    padding: 14px;
    background: #F3F3F2;
}

.am-service-card__image {
    height: 310px;
    display: block;
    overflow: hidden;
    border-radius: 2px;
    background: #E7E8E5;
}

.am-service-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.am-service-card:hover .am-service-card__image img {
    transform: scale(1.035);
}

.am-service-card__body {
    flex: 1;
    display: flex;
    flex-direction: column;
    padding-top: 18px;
}

.am-service-card h2 {
    margin: 0 0 10px;
    color: #3E5338;
    font-size: 24px;
    font-weight: 600;
    line-height: 1.2;
}

.am-service-card h2 a {
    color: inherit;
}

.am-service-card__content {
    color: #282828;
    font-size: 16px;
    line-height: 1.35;
}

.am-service-card__content p {
    margin: 0 0 14px;
}

.am-service-card__content ul,
.am-service-card__content ol {
    margin: 0 0 16px;
    padding-left: 21px;
}

.am-service-card__content strong {
    font-weight: 600;
}

.am-service-card__button {
    width: 100%;
    min-height: 52px;
    margin-top: auto;
    padding: 14px 18px;
    border-radius: 4px;
    font-size: 16px;
}

.am-service-article__hero {
    max-width: 720px;
    margin: 0 0 28px;
}

.am-service-article__hero img {
    width: 100%;
    height: auto;
    display: block;
}

.am-service-article__cta {
    display: flex;
    align-items: center;
    gap: 24px;
    margin-top: 34px;
}

/* Programs archive */
.am-programs-page__header {
    text-align: center;
}

.am-programs-page__header p {
    max-width: 760px;
    margin: 0 auto;
}

.am-programs-list {
    display: grid;
    gap: 28px;
}

.am-program-card {
    min-height: 390px;
    display: grid;
    grid-template-columns: 390px minmax(0, 1fr);
    gap: 28px;
}

.am-program-card__image {
    height: 390px;
    display: block;
    overflow: hidden;
    background: #F2F2F2;
}

.am-program-card__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform .4s ease;
}

.am-program-card:hover .am-program-card__image img {
    transform: scale(1.025);
}

.am-program-card__body {
    min-width: 0;
    display: flex;
    flex-direction: column;
    padding: 4px 0 0;
}

.am-program-stars {
    display: inline-flex;
    color: #F5A623;
    font-size: 20px;
    line-height: 1;
    letter-spacing: 1px;
}

.am-program-card h2 {
    margin: 14px 0 18px;
    color: #3E5338;
    font-size: 24px;
    font-weight: 600;
    line-height: 1.22;
}

.am-program-card h2 a {
    color: inherit;
}

.am-program-card__excerpt {
    color: #282828;
    font-size: 16px;
    line-height: 1.45;
}

.am-program-card__more {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    align-self: flex-end;
    margin-top: auto;
    color: #282828;
    font-size: 16px;
    font-weight: 500;
}

.am-program-card__more svg {
    width: 21px;
    height: 16px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.7;
    transition: transform .2s ease;
}

.am-program-card__more:hover svg {
    transform: translateX(4px);
}

/* Program single */
.am-program-single .am-blog-single__container {
    padding-top: 28px;
    padding-bottom: 64px;
}

.am-program-article__title {
    margin: 0 0 24px;
    color: #3E5338;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.2;
}

.am-program-article__hero {
    display: grid;
    grid-template-columns: 440px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
    margin-bottom: 20px;
}

.am-program-article__image {
    position: relative;
    width: 100%;
    height: 300px;
    display: block;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    padding: 0;
    background: #F2F2F2;
    cursor: default;
}

button.am-program-article__image {
    cursor: pointer;
}

.am-program-article__image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.am-program-article__details {
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.am-program-meta-list {
    width: 100%;
    display: grid;
    gap: 14px;
}

.am-program-meta-row {
    min-height: 22px;
    display: flex;
    align-items: center;
    gap: 10px;
    color: #282828;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.35;
}

.am-program-meta-row__icon {
    width: 20px;
    height: 20px;
    flex: 0 0 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #3E5338;
}

.am-program-meta-row__icon svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.6;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.am-program-language-flag {
    width: 20px;
    height: 20px;
    display: block;
    overflow: hidden;
    border-radius: 50%;
    background: linear-gradient(to bottom, #2787e9 0 50%, #f7d62c 50% 100%);
}

.am-program-meta-row__content {
    min-width: 0;
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
}

.am-program-meta-row__content strong {
    color: #282828;
    font-size: 16px;
    font-weight: 600;
}

.am-program-meta-row__muted {
    color: #909090;
    font-size: 12px;
    font-weight: 400;
}

.am-program-stars {
    color: #F5A623;
    font-size: 18px;
    line-height: 1;
    letter-spacing: 1px;
}

.am-program-consultation-button {
    width: 274px;
    min-height: 52px;
    margin-top: 20px;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
}

.am-program-article__lead {
    margin: 0 0 22px;
    color: #282828;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.45;
}

.am-program-article__lead p:last-child {
    margin-bottom: 0;
}

.am-program-content {
    margin-bottom: 0;
}

.am-program-content h2,
.am-program-content h3 {
    color: #3E5338;
}

.am-program-single .am-product-reviews {
    margin-top: 36px;
    padding-top: 20px;
    border-top: 1px solid #AEB2AA;
}

.am-program-single .am-product-reviews > h2 {
    margin-bottom: 18px;
    color: #3E5338;
    font-size: 24px;
    font-weight: 600;
}

.am-program-single .am-product-review-pagination {
    margin-top: 16px;
}

.am-program-review-form {
    margin-top: 24px;
    border: 1px solid #D7DAD4;
    border-radius: 4px;
    padding: 22px;
    background: #F7F7F6;
}

.am-program-review-form[hidden] {
    display: none !important;
}

.am-program-review-form label {
    display: grid;
    gap: 7px;
    color: #3E5338;
    font-size: 14px;
    font-weight: 500;
}

.am-program-review-form__row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
    margin-bottom: 14px;
}

.am-program-review-form input,
.am-program-review-form select,
.am-program-review-form textarea {
    width: 100%;
    border: 1px solid #8A8D87;
    border-radius: 4px;
    padding: 13px 14px;
    background: #fff;
    color: #282828;
    font: inherit;
}

.am-program-review-form textarea {
    resize: vertical;
    margin-bottom: 14px;
}

.am-program-form-status {
    margin-top: 10px;
    color: #B90101;
    font-size: 13px;
}

@media (max-width: 991px) {
    .am-services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .am-program-card {
        grid-template-columns: 330px minmax(0, 1fr);
    }

    .am-program-card__image {
        height: 350px;
    }

    .am-program-meta {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .am-services-page__container,
    .am-programs-page__container {
        padding-top: 20px;
        padding-bottom: 40px;
    }

    .am-services-page__header h1,
    .am-programs-page__header h1 {
        font-size: 24px;
    }

    .am-services-page__intro,
    .am-programs-page__header p {
        font-size: 16px;
        line-height: 1.45;
    }

    .am-services-grid {
        grid-template-columns: 1fr;
    }

    .am-service-card {
        padding: 10px;
    }

    .am-service-card__image {
        height: auto;
        aspect-ratio: 1 / .82;
    }

    .am-service-card h2 {
        font-size: 20px;
    }

    .am-service-card__content {
        font-size: 16px;
    }

    .am-service-article__cta {
        align-items: stretch;
        flex-direction: column;
    }

    .am-program-card {
        min-height: 0;
        grid-template-columns: 1fr;
        gap: 14px;
    }

    .am-program-card__image {
        height: auto;
        aspect-ratio: 1 / 1;
    }

    .am-program-card__body {
        padding: 0 2px 10px;
    }

    .am-program-card h2 {
        margin: 10px 0 12px;
        font-size: 20px;
    }

    .am-program-card__excerpt,
    .am-program-card__more {
        font-size: 16px;
    }

    .am-program-card__more {
        margin-top: 18px;
    }

    .am-program-article__hero {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .am-program-article__image {
        min-height: 0;
        aspect-ratio: 1 / .82;
    }

    .am-program-article__intro h1 {
        font-size: 24px;
    }

    .am-program-article__intro p {
        font-size: 16px;
    }

    .am-program-meta {
        grid-template-columns: 1fr 1fr;
    }

    .am-program-meta > div {
        min-height: 86px;
        padding: 14px;
    }

    .am-program-meta dd {
        font-size: 15px;
    }

    .am-program-review-form__row {
        grid-template-columns: 1fr;
    }

    .am-program-modal {
        align-items: flex-start;
        padding: 10px;
    }

    .am-program-modal__dialog {
        max-height: calc(100vh - 20px);
        padding: 46px 14px 22px;
    }

    .am-program-modal h2 {
        font-size: 24px;
    }

    .am-program-modal__success {
        min-height: 360px;
        display: flex;
        flex-direction: column;
        justify-content: center;
        text-align: center;
    }

    .am-program-success-icon {
        width: 130px;
        height: 130px;
    }

    .am-program-success-icon::after {
        left: 30px;
        top: 34px;
        width: 58px;
        height: 28px;
        border-width: 0 0 14px 14px;
    }
}

/* Program single responsive refinement */
@media (max-width: 991px) {
    .am-program-article__hero {
        grid-template-columns: 390px minmax(0, 1fr);
    }

    .am-program-article__image {
        height: 285px;
    }
}

@media (max-width: 767px) {
    .am-program-single .am-blog-single__container {
        padding-top: 20px;
        padding-bottom: 40px;
    }

    .am-program-article__title {
        margin-bottom: 18px;
        font-size: 24px;
        line-height: 1.25;
    }

    .am-program-article__hero {
        grid-template-columns: 1fr;
        gap: 18px;
        margin-bottom: 18px;
    }

    .am-program-article__image {
        height: auto;
        aspect-ratio: 1.28 / 1;
    }

    .am-program-meta-list {
        gap: 12px;
    }

    .am-program-meta-row,
    .am-program-meta-row__content strong {
        font-size: 16px;
    }

    .am-program-consultation-button {
        width: 100%;
        margin-top: 18px;
    }

    .am-program-article__lead,
    .am-program-content {
        font-size: 16px;
    }

    .am-program-single .am-product-reviews {
        margin-top: 28px;
        padding-top: 18px;
    }

    .am-program-review-form__row {
        grid-template-columns: 1fr;
    }
}

.am-program-language-flag--ru {
    background: linear-gradient(to bottom, #fff 0 33.333%, #1f57a4 33.333% 66.666%, #d52b1e 66.666% 100%);
    box-shadow: inset 0 0 0 1px rgba(40, 40, 40, .12);
}

/* AM 6.62 — approved services page composition. */
.am-services-page .am-sp-breadcrumbs {
    margin-bottom: 24px;
}

.am-services-page__header {
    margin-bottom: 38px;
}

.am-services-page__intro p {
    margin: 0 0 18px;
}

.am-services-page__intro p:last-child {
    margin-bottom: 0;
}

.am-service-card__button {
    text-transform: uppercase;
}

@media (max-width: 767px) {
    .am-services-page__header {
        margin-bottom: 24px;
    }

    .am-services-page__header h1 {
        text-align: left;
    }

    .am-services-page__intro p {
        margin-bottom: 16px;
    }
}


/* AM 6.65 — exact Services page visual restore from approved reference. */
.am-services-page {
    background: #fff;
}

.am-services-page .am-services-page__container {
    width: min(calc(100% - 30px), 1200px);
    margin-inline: auto;
    padding-top: 28px;
    padding-bottom: 64px;
}

.am-services-page .am-services-page__header {
    width: 100%;
    max-width: none;
    margin: 0 0 36px;
}

.am-services-page .am-services-page__header h1 {
    margin: 0 0 18px;
    font-family: Montserrat, sans-serif;
    font-size: 32px;
    font-weight: 600;
    line-height: 1.15;
    letter-spacing: 0;
    text-align: center;
    color: #3E5338;
}

.am-services-page .am-services-page__intro {
    width: 100%;
    max-width: none;
    margin: 0;
    font-family: Montserrat, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.35;
    color: #282828;
}

.am-services-page .am-services-page__intro p {
    margin: 0 0 18px;
}

.am-services-page .am-services-grid {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
    align-items: stretch;
}

.am-services-page .am-service-card {
    min-width: 0;
    height: 100%;
    display: flex;
    flex-direction: column;
    box-sizing: border-box;
    margin: 0;
    border: 1px solid #C9CCC5;
    border-radius: 4px;
    padding: 14px;
    background: #F3F3F2;
    box-shadow: none;
    overflow: hidden;
}

.am-services-page .am-service-card__image {
    width: 100%;
    height: auto;
    aspect-ratio: 10 / 9;
    display: block;
    flex: 0 0 auto;
    overflow: hidden;
    border: 0;
    border-radius: 0;
    background: #E7E8E5;
}

.am-services-page .am-service-card__image img {
    width: 100%;
    height: 100%;
    display: block;
    margin: 0;
    object-fit: cover;
    object-position: center;
    transform: none;
}

.am-services-page .am-service-card:hover .am-service-card__image img {
    transform: none;
}

.am-services-page .am-service-card__body {
    min-width: 0;
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    padding: 16px 0 0;
}

.am-services-page .am-service-card h2 {
    margin: 0 0 10px;
    font-family: Montserrat, sans-serif;
    font-size: 20px;
    font-weight: 600;
    line-height: 1.18;
    letter-spacing: 0;
    color: #3E5338;
}

.am-services-page .am-service-card h2 a,
.am-services-page .am-service-card h2 a:hover,
.am-services-page .am-service-card h2 a:focus {
    color: #3E5338;
    text-decoration: none;
}

.am-services-page .am-service-card__content {
    min-width: 0;
    flex: 0 1 auto;
    margin: 0;
    font-family: Montserrat, sans-serif;
    font-size: 16px;
    font-weight: 400;
    line-height: 1.28;
    color: #282828;
}

.am-services-page .am-service-card__content p {
    margin: 0 0 14px;
}

.am-services-page .am-service-card__content ul,
.am-services-page .am-service-card__content ol {
    margin: 0 0 16px;
    padding-left: 21px;
}

.am-services-page .am-service-card__content li {
    margin: 0;
}

.am-services-page .am-service-card__button,
.am-services-page .am-service-card__button:hover,
.am-services-page .am-service-card__button:focus-visible {
    width: 100%;
    min-height: 52px;
    height: 52px;
    margin: auto 0 0;
    padding: 0 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid #3E5338;
    border-radius: 4px;
    background: #3E5338;
    color: #fff;
    font-family: Montserrat, sans-serif;
    font-size: 14px;
    font-weight: 600;
    line-height: 1;
    letter-spacing: 0;
    text-align: center;
    text-decoration: none;
    text-transform: uppercase;
    box-shadow: none;
}

@media (max-width: 991px) {
    .am-services-page .am-services-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 767px) {
    .am-services-page .am-services-page__container {
        width: min(calc(100% - 20px), 1200px);
        padding-top: 20px;
        padding-bottom: 40px;
    }

    .am-services-page .am-sp-breadcrumbs {
        margin-bottom: 20px;
    }

    .am-services-page .am-services-page__header {
        margin-bottom: 22px;
    }

    .am-services-page .am-services-page__header h1 {
        margin-bottom: 14px;
        font-size: 24px;
        line-height: 1.15;
        text-align: left;
    }

    .am-services-page .am-services-page__intro {
        font-size: 16px;
        line-height: 1.35;
    }

    .am-services-page .am-services-page__intro p {
        margin-bottom: 14px;
    }

    .am-services-page .am-services-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: 12px;
    }

    .am-services-page .am-service-card {
        width: 100%;
        padding: 10px;
    }

    .am-services-page .am-service-card__image {
        width: 100%;
        aspect-ratio: 10 / 9;
    }

    .am-services-page .am-service-card__body {
        padding-top: 12px;
    }

    .am-services-page .am-service-card h2 {
        margin-bottom: 8px;
        font-size: 18px;
        line-height: 1.2;
    }

    .am-services-page .am-service-card__content {
        font-size: 15px;
        line-height: 1.28;
    }

    .am-services-page .am-service-card__content p {
        margin-bottom: 12px;
    }

    .am-services-page .am-service-card__content ul,
    .am-services-page .am-service-card__content ol {
        margin-bottom: 14px;
        padding-left: 19px;
    }

    .am-services-page .am-service-card__button,
    .am-services-page .am-service-card__button:hover,
    .am-services-page .am-service-card__button:focus-visible {
        min-height: 48px;
        height: 48px;
        font-size: 13px;
    }
}
