/* Блок для детских и коррекционных центров на главной. */
.centers {
    --centers-blue: #2563eb;
    --centers-blue-soft: #e8eefe;
    --centers-coral: #f2805f;
    --centers-mint: #4fb7a6;
    --centers-bg: linear-gradient(180deg, #fffaf4 0%, #f4f7ff 58%, #fffaf4 100%);
    --centers-card: #ffffff;
    --centers-line: #e7e6f0;
    --centers-step: 6s;
    background: var(--centers-bg);
    overflow: hidden;
}

html[data-theme="dark"] .centers {
    --centers-blue: #7ea2ff;
    --centers-blue-soft: #1c2748;
    --centers-bg: linear-gradient(180deg, #14181f 0%, #121722 58%, #14181f 100%);
    --centers-card: #1a1f29;
    --centers-line: #2c3340;
}

.centers__head {
    max-width: 780px;
    margin: 0 auto 56px;
    text-align: center;
}

.centers__eyebrow,
.centers__label {
    margin: 0 0 12px;
    color: var(--centers-blue);
    font-size: 0.82rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

.centers__title {
    text-wrap: balance;
}

.centers__sub {
    text-wrap: pretty;
}

.centers__specialties {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
    margin: 24px 0 0;
    padding: 0;
    list-style: none;
}

.centers__specialties li {
    padding: 7px 14px;
    border: 1px solid var(--centers-line);
    border-radius: 999px;
    background: var(--centers-card);
    color: var(--text);
    font-size: 0.88rem;
    font-weight: 600;
}

.centers__subtitle {
    margin: 0 0 24px;
    color: var(--text);
    font-size: clamp(1.45rem, 3vw, 2rem);
    line-height: 1.2;
    text-wrap: balance;
}

/* Приложение: шаги и телефон */
.centers-app {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
    gap: 56px;
    align-items: center;
    margin-bottom: 88px;
}

.centers-steps {
    display: grid;
    gap: 10px;
}

.centers-step {
    position: relative;
    display: flex;
    gap: 14px;
    width: 100%;
    padding: 16px 18px;
    overflow: hidden;
    border: 1px solid transparent;
    border-radius: 18px;
    background: transparent;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
    transition: background-color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.centers-step:hover {
    background: var(--centers-card);
}

.centers-step:focus-visible,
.centers-crm__tab:focus-visible,
.centers-browser__shot:focus-visible {
    outline: 2px solid var(--centers-blue);
    outline-offset: 2px;
}

.centers-step.is-on {
    border-color: var(--centers-line);
    background: var(--centers-card);
    box-shadow: var(--shadow);
}

.centers-step__num {
    display: grid;
    flex: none;
    width: 32px;
    height: 32px;
    place-items: center;
    border-radius: 50%;
    background: var(--centers-blue-soft);
    color: var(--centers-blue);
    font-size: 0.9rem;
    font-weight: 700;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.centers-step.is-on .centers-step__num {
    background: var(--centers-blue);
    color: #fff;
}

html[data-theme="dark"] .centers-step.is-on .centers-step__num {
    color: #10141c;
}

.centers-step__body {
    display: grid;
    gap: 4px;
    min-width: 0;
}

.centers-step__body strong {
    color: var(--text);
    font-size: 1.02rem;
    line-height: 1.3;
}

.centers-step__body span {
    color: var(--text-muted);
    font-size: 0.93rem;
    line-height: 1.45;
}

.centers-step__bar {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 3px;
    background: var(--centers-blue);
    opacity: 0;
    transform: scaleX(0);
    transform-origin: left;
}

.centers-app.is-playing .centers-step.is-on .centers-step__bar {
    opacity: 1;
    animation: centers-progress var(--centers-step) linear forwards;
}

@keyframes centers-progress {
    to {
        transform: scaleX(1);
    }
}

.centers-app__stage {
    position: relative;
    display: grid;
    min-height: 640px;
    place-items: center;
}

.centers-app__blob {
    position: absolute;
    border-radius: 50%;
    opacity: 0.55;
    filter: blur(2px);
}

.centers-app__blob--coral {
    top: 4%;
    right: 2%;
    width: 210px;
    height: 210px;
    background: #f9c9b8;
}

.centers-app__blob--blue {
    bottom: 12%;
    left: 0;
    width: 170px;
    height: 170px;
    background: #c5d6fb;
}

.centers-app__blob--mint {
    right: 8%;
    bottom: 2%;
    width: 120px;
    height: 120px;
    background: #bfe5dc;
}

html[data-theme="dark"] .centers-app__blob {
    opacity: 0.16;
}

.centers-phone {
    position: relative;
    width: 296px;
    aspect-ratio: 390 / 844;
    padding: 9px;
    box-sizing: content-box;
    border-radius: 46px;
    background: #15171c;
    box-shadow: 0 30px 60px rgba(30, 41, 90, 0.26), inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.centers-phone__screen {
    position: absolute;
    top: 9px;
    left: 9px;
    width: 296px;
    height: auto;
    aspect-ratio: 390 / 844;
    border-radius: 37px;
    opacity: 0;
    transform: translateY(10px) scale(0.985);
    transition: opacity 0.42s ease, transform 0.42s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.centers-phone__screen.is-on {
    opacity: 1;
    transform: none;
}

/* CRM в рамке браузера */
.centers-crm {
    margin-bottom: 56px;
}

.centers-crm__head {
    max-width: 760px;
    margin: 0 auto 28px;
    text-align: center;
}

.centers-crm__head .centers__subtitle {
    margin-bottom: 12px;
}

.centers-crm__text {
    margin: 0 0 22px;
    color: var(--text-muted);
    text-wrap: pretty;
}

.centers-crm__tabs {
    display: inline-flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 4px;
    padding: 4px;
    border: 1px solid var(--centers-line);
    border-radius: 999px;
    background: var(--centers-card);
}

.centers-crm__tab {
    padding: 9px 18px;
    border: 0;
    border-radius: 999px;
    background: transparent;
    color: var(--text-muted);
    font: inherit;
    font-size: 0.92rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.22s ease, color 0.22s ease;
}

.centers-crm__tab.is-on {
    background: var(--centers-blue);
    color: #fff;
}

html[data-theme="dark"] .centers-crm__tab.is-on {
    color: #10141c;
}

.centers-browser {
    max-width: 1080px;
    margin: 0 auto;
    overflow: hidden;
    border: 1px solid var(--centers-line);
    border-radius: 18px;
    background: var(--centers-card);
    box-shadow: 0 30px 70px rgba(30, 41, 90, 0.16);
}

.centers-browser__bar {
    display: flex;
    gap: 7px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--centers-line);
}

.centers-browser__bar i {
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: var(--centers-line);
}

.centers-browser__view {
    position: relative;
    aspect-ratio: 16 / 10;
    background: #f4f6fb;
}

.centers-browser__shot {
    position: absolute;
    inset: 0;
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: none;
    cursor: zoom-in;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s;
}

.centers-browser__shot.is-on {
    opacity: 1;
    visibility: visible;
}

.centers-browser__shot img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top left;
}

.centers-crm__caption {
    max-width: 680px;
    min-height: 3em;
    margin: 16px auto 0;
    color: var(--text-muted);
    font-size: 0.93rem;
    text-align: center;
    text-wrap: pretty;
}

/* Что ещё и заявка */
.centers-extras {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 16px;
    margin-bottom: 32px;
}

.centers-extra {
    padding: 22px;
    border: 1px solid var(--centers-line);
    border-radius: 18px;
    background: var(--centers-card);
}

.centers-extra h4 {
    margin: 0 0 8px;
    color: var(--text);
    font-size: 1.02rem;
    line-height: 1.3;
}

.centers-extra p {
    margin: 0;
    color: var(--text-muted);
    font-size: 0.93rem;
    line-height: 1.45;
}

.centers-cta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 28px 32px;
    border-radius: 22px;
    background: var(--centers-blue-soft);
}

.centers-cta h3 {
    margin: 0 0 6px;
    color: var(--text);
    font-size: 1.3rem;
    line-height: 1.25;
}

.centers-cta p {
    margin: 0;
    color: var(--text-muted);
}

.centers-cta .site-btn {
    flex: none;
}

.centers__note {
    margin: 14px 0 0;
    color: var(--text-muted);
    font-size: 0.82rem;
    text-align: center;
}

.hero__centers-link {
    display: inline-block;
    margin-top: 14px;
    color: var(--accent-ink);
    font-size: 0.95rem;
    font-weight: 600;
    text-underline-offset: 3px;
}

@media (max-width: 980px) {
    .centers-extras {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .centers-app {
        grid-template-columns: minmax(0, 1fr);
        gap: 32px;
        margin-bottom: 64px;
    }

    .centers-app__copy {
        text-align: center;
    }

    .centers-step {
        text-align: left;
    }
}

@media (max-width: 640px) {
    .centers__head {
        margin-bottom: 36px;
    }

    .centers-app__stage {
        order: -1;
        min-height: 540px;
    }

    .centers-app__copy {
        display: contents;
    }

    .centers-app__copy > .centers__label,
    .centers-app__copy > .centers__subtitle {
        order: -2;
        margin-bottom: 0;
    }

    .centers-app {
        gap: 16px;
    }

    .centers-phone,
    .centers-phone__screen {
        width: 240px;
    }

    .centers-phone {
        border-radius: 38px;
    }

    .centers-phone__screen {
        border-radius: 30px;
    }

    .centers-browser__view {
        aspect-ratio: 16 / 11;
    }

    .centers-crm__tab {
        padding: 8px 13px;
        font-size: 0.86rem;
    }

    .centers-extras {
        grid-template-columns: minmax(0, 1fr);
    }

    .centers-cta {
        flex-direction: column;
        align-items: stretch;
        padding: 22px;
        text-align: center;
    }
}

@media (prefers-reduced-motion: reduce) {
    .centers-phone__screen,
    .centers-browser__shot,
    .centers-step {
        transition: none;
    }

    .centers-app.is-playing .centers-step.is-on .centers-step__bar {
        animation: none;
        opacity: 0;
    }
}

/* Сроки оплаты подписки в блоке цен */
.plans-terms {
    margin-top: 28px;
}

.plans-terms__title {
    margin: 0 0 14px;
    color: var(--text);
    font-size: 1.15rem;
    text-align: center;
}

.plans-terms__table {
    overflow: hidden;
    border: 1px solid var(--border);
    border-radius: 16px;
    background: var(--surface);
}

.plans-terms__row {
    display: grid;
    grid-template-columns: 1.25fr 1fr 1fr;
    gap: 10px;
    align-items: center;
    padding: 13px 16px;
    border-top: 1px solid var(--border);
    color: var(--text);
    font-weight: 600;
}

.plans-terms__row--head {
    border-top: 0;
    color: var(--text-muted);
    font-size: 0.82rem;
}

.plans-terms__row.is-best {
    background: var(--green-light);
}

.plans-terms__row em {
    display: block;
    color: var(--accent-ink);
    font-size: 0.82rem;
    font-style: normal;
}

.plans-terms__row small {
    display: block;
    color: var(--text-muted);
    font-size: 0.8rem;
    font-weight: 500;
}

.plans-terms__note {
    margin: 10px 8px 0;
    color: var(--text-muted);
    font-size: 0.8rem;
    text-align: center;
    text-wrap: pretty;
}

@media (max-width: 480px) {
    .plans-terms__row {
        padding: 12px;
        font-size: 0.9rem;
    }
}

.plans__quote-row[hidden] {
    display: none;
}
