/*
 * Obuchenie landing — local tweaks only.
 * Базовая визуальная система берётся из assets/new/css/app.min.css
 * (gg--home__hero, gg--scenarios, gg--scenario-card, gg--process,
 *  gg--comparison, gg--cluster-links, gg--blog-card, gg--lead__form, и т.д.).
 *
 * Здесь — только то, чего нет в общей системе: блок отзывов-фото,
 * карточки видео-выступлений, карточки школ, пометка про цены.
 */

/* ====== HERO — по образцу ai-consulting ====== */
.gg--home__hero--obuchenie .gg--home__hero__subtitle {
    font-size: clamp(1rem, 1.8vw, 1.15rem);
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.92);
    margin-bottom: 1.5rem;
}

/* Фото спикера (PNG с прозрачным фоном) встаёт на нижний обрез hero-блока.
 * Ширина — флюид: clamp(22rem, 42vw, 48rem). Высота свободная — высокий
 * вертикальный кроп растягивается во весь рост спикера. */
.gg--home__hero__section__image--obuchenie {
    align-self: flex-end;
    padding-top: 0;
    margin-right: 0;
    width: clamp(22rem, 42vw, 48rem);
    max-width: none;
    flex-shrink: 0;
}

/* >=1001px — фото справа от текста.
 * Перебиваем @media (max-width: 1024px) из app.min.css, где
 * .gg--home__hero__section переключается в column-вёрстку. */
@media (min-width: 1001px) {
    .gg--home__hero--obuchenie .gg--home__hero__section {
        flex-direction: row;
        flex-wrap: nowrap;
        max-width: none;
        margin: 0;
        gap: 2rem;
        justify-content: space-between;
        align-items: flex-start;
    }

    .gg--home__hero--obuchenie .gg--home__hero__info {
        min-width: 0;
        flex: 1 1 auto;
    }

    /* Высота hero — не выше viewport. Картинка масштабируется по height,
     * ширина следует за aspect-ratio.
     * 16rem = padding-top hero, поэтому из 100vh вычитаем именно столько. */
    .gg--home__hero--obuchenie {
        max-height: 100vh;
    }

    .gg--home__hero--obuchenie .gg--home__hero__section__image--obuchenie {
        width: auto;
        max-width: clamp(22rem, 42vw, 48rem);
    }

    .gg--home__hero--obuchenie .gg--home__hero__section__image--obuchenie .gg--home__hero__section__image__x img {
        width: auto;
        height: auto;
        max-width: 100%;
        max-height: calc(100vh - 16rem);
    }
}

.gg--home__hero__section__image--obuchenie .gg--home__hero__section__image__x {
    display: flex;
    align-items: flex-end;
    line-height: 0;
}

.gg--home__hero__section__image--obuchenie .gg--home__hero__section__image__x img {
    border-radius: 0;
    box-shadow: none;
    display: block;
    margin: 0;
    width: 100%;
    height: auto;
    max-width: none;
}

/* Скрываем «пузырь» декорации фона: он мешает чистому cutout-фото. */
.gg--home__hero--obuchenie .gg--home__hero__section__image__x:before {
    display: none;
}

/* ====== ОБЩИЙ "leads" подзаголовок секций ====== */
.gg--obuchenie__lead {
    font-size: 1.05rem;
    color: #475569;
    max-width: 820px;
    margin: -0.5rem 0 1.75rem;
    line-height: 1.55;
}

.gg--obuchenie__topics-note {
    margin-top: 1.25rem;
    color: #64748b;
    font-style: italic;
    font-size: 0.95rem;
}

.gg--obuchenie__lead-form-intro {
    color: #475569;
    margin: 0 0 1.5rem;
    line-height: 1.55;
}

/* ====== ФОРМАТЫ — заметка о ценах ====== */
.gg--obuchenie__price-note {
    margin-top: 2rem;
    background: #fff;
    border-left: 4px solid #c495ff;
    padding: 1rem 1.25rem;
    border-radius: 0 12px 12px 0;
    color: #475569;
    font-size: 0.95rem;
    box-shadow: 0 2px 12px rgba(196, 149, 255, 0.06);
}

/* ====== ГДЕ ПРЕПОДАЮ — карточки школ ====== */
.gg--obuchenie-schools__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.gg--obuchenie-school-card {
    display: block;
    background: #fff;
    border: 1px solid #e9d5ff;
    border-radius: 12px;
    padding: 1.25rem 1.5rem;
    text-decoration: none;
    color: inherit;
    transition: all 0.2s ease;
}

a.gg--obuchenie-school-card:hover {
    border-color: #c495ff;
    box-shadow: 0 4px 24px rgba(196, 149, 255, 0.16);
    transform: translateY(-2px);
}

.gg--obuchenie-school-card--static {
    background: #faf5ff;
    cursor: default;
}

.gg--obuchenie-school-card--past {
    opacity: 0.7;
}

.gg--obuchenie-school-card__name {
    font-weight: 700;
    color: #1e293b;
    font-size: 1.05rem;
    margin-bottom: 0.35rem;
    line-height: 1.3;
}

.gg--obuchenie-school-card__course {
    color: #475569;
    font-size: 0.95rem;
    margin-bottom: 0.35rem;
    line-height: 1.4;
}

.gg--obuchenie-school-card__url {
    color: #c495ff;
    font-size: 0.85rem;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* ====== ОТЗЫВЫ — галерея фото (фикс. соотношение для выравнивания) ====== */
.gg--obuchenie-reviews-section {
    padding: 3.5rem 0;
}

.gg--obuchenie-reviews__grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.gg--obuchenie-review {
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #e9d5ff;
    border-radius: 12px;
    overflow: hidden;
    padding: 0.5rem;
    aspect-ratio: 3 / 4;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    cursor: zoom-in;
}

.gg--obuchenie-review:hover {
    box-shadow: 0 8px 32px rgba(196, 149, 255, 0.2);
    transform: translateY(-2px);
}

.gg--obuchenie-review img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* ====== ВЫСТУПЛЕНИЯ И ВИДЕО — поверх blog-card--cluster ======
 * Базовая разметка приходит из ai-consulting.css.
 */
.gg--blog-card--video {
    background: #fff;
    border: 1px solid #e2e8f0;
    display: flex;
    flex-direction: column;
}

.gg--blog-card--video .gg--blog-card__title {
    margin-bottom: 0.5rem;
}

.gg--blog-card--video .gg--blog-card__text {
    margin-top: 0;
}

/* Картинка cluster-thumbnail — фикс пропорций 16:9 уже задан в ai-consulting.css */
.gg--cluster-cards__grid .gg--blog-card__thumbnail--cluster {
    margin: -1.5rem -1.5rem 1.25rem;
}

/* Play-overlay поверх видео-превью */
.gg--video-thumb {
    position: relative;
    cursor: pointer;
}

.gg--video-thumb__play {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    pointer-events: none;
    transition: transform 0.2s ease;
    line-height: 0;
}

.gg--video-thumb:hover .gg--video-thumb__play {
    transform: translate(-50%, -50%) scale(1.08);
}

.gg--video-thumb:hover .gg--blog-card__image {
    transform: scale(1.03);
}

/* ====== НАУЧНАЯ ДЕЯТЕЛЬНОСТЬ — 2 колонки внутри good-card ====== */
.gg--obuchenie-science .gg--obuchenie-science__inner {
    display: grid;
    grid-template-columns: 1.3fr 1fr;
    gap: 1.75rem;
    align-items: start;
}

.gg--obuchenie-science__text p {
    margin: 0 0 0.85rem;
    color: #475569;
    line-height: 1.6;
}

.gg--obuchenie-science__link {
    font-size: 0.95rem;
}

.gg--obuchenie-science__link a {
    color: #c495ff;
    font-weight: 600;
    text-decoration: none;
}

.gg--obuchenie-science__link a:hover {
    color: #a766ff;
}

.gg--obuchenie-science__image {
    margin: 0;
}

.gg--obuchenie-science__image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    display: block;
}

/* ====== ФОРМА — UTM honeypot ====== */
.gg--form-field-url {
    position: absolute;
    left: -9999px;
    opacity: 0;
    pointer-events: none;
}

/* ====== УСПЕХ ====== */
.success-message {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: #f0fdf4;
    border: 2px solid #22c55e;
    border-radius: 12px;
    padding: 2rem;
    margin: 2rem auto;
    max-width: 540px;
}

.success-message svg {
    margin-bottom: 0.75rem;
}

.success-message h3 {
    margin: 0 0 0.5rem;
    color: #15803d;
}

.success-message p {
    margin: 0;
    color: #166534;
}

/* ====== MOBILE ====== */
@media (max-width: 768px) {
    .gg--obuchenie-reviews-section {
        padding: 2.5rem 0;
    }
    .gg--obuchenie-science .gg--obuchenie-science__inner {
        grid-template-columns: 1fr;
    }
    .gg--obuchenie__price-note {
        margin-top: 1.5rem;
    }
}
