/*
 * Новая главная collageberry.ru (home-v2.php), ВЕРСИЯ 2 — блоки главной ПОВЕРХ css_internal/article.css.
 * Переменные цвета (--cb-*) — из article.css: тёмная шапка #16181f, акцент #C02942, тёплый фон.
 * Мобильная версия первична (>50 % трафика): проверяется на 390 px, без горизонтального скролла
 * страницы (прокрутка только внутри лент и вкладок).
 */

.cb-home { overflow-x: hidden; }
/* 07.10.2026: .cb-home — это <body>; его hidden уходит на окно, а окно с hidden палец (и DevTools) всё равно
   сдвигает вбок, если что-то торчит за край, — «сайт обрезан слева». clip на body режет без прокрутки,
   html берёт hidden на себя, чтобы body не отдавал своё значение окну. sticky-шапку clip не ломает. */
@supports (overflow-x: clip) {
    html { overflow-x: hidden; }
    .cb-home { overflow-x: clip; }
}
.cb-home .cb-draft { margin: 0; }
html.hm-lb-open, html.hm-lb-open body { overflow: hidden; }

.hm-wrap { max-width: 1180px; margin: 0 auto; padding: 0 16px; }
@media (min-width: 760px) { .hm-wrap { padding: 0 28px; } }
.hm-narrow { max-width: 860px; }

.hm-section { padding: 52px 0; }
@media (min-width: 900px) { .hm-section { padding: 88px 0; } }
.hm-section--warm { background: var(--cb-tint-warm); }
.hm-section--slim { padding: 40px 0; }
.hm-section--cta { padding-top: 16px; }
.hm-section--dark { background: var(--cb-dark); color: #ece9e3; }

.hm-h2 {
    margin: 0 0 12px;
    font-size: 28px;
    line-height: 1.15;
    letter-spacing: -.02em;
    font-weight: 800;
}
@media (min-width: 760px) { .hm-h2 { font-size: 40px; } }
.hm-h2--small { font-size: 24px; }
@media (min-width: 760px) { .hm-h2--small { font-size: 28px; } }
.hm-intro { margin: 0 0 28px; max-width: 46rem; color: var(--cb-ink-soft); font-size: 17px; }
.hm-lead { font-size: 18px; color: var(--cb-ink-soft); margin: 0 0 18px; }
.hm-muted { color: var(--cb-muted); font-size: 15px; line-height: 1.6; }
.hm-more { margin: 26px 0 0; font-weight: 600; }
.hm-draft-tag {
    display: inline-block;
    margin-left: 8px;
    padding: 1px 8px;
    font-size: 12px;
    font-weight: 600;
    color: #8a5a00;
    background: #fff2cc;
    border-radius: 999px;
    vertical-align: middle;
}

/* какой текст показать: мышь или палец */
.hm-only-touch { display: none; }
@media (hover: none), (pointer: coarse) {
    .hm-only-mouse { display: none; }
    .hm-only-touch { display: inline; }
}

/* --- кнопки ------------------------------------------------------------- */

.cb-page .hm-btn {
    display: inline-block;
    padding: 13px 26px;
    background: var(--cb-accent);
    color: #fff;
    font: inherit;
    font-weight: 700;
    line-height: 1.3;
    border: 0;
    border-radius: 999px;
    text-decoration: none;
    cursor: pointer;
    box-shadow: 0 8px 22px rgba(192, 41, 66, .32);
    transition: background .15s ease, transform .15s ease;
}
.cb-page .hm-btn:hover { background: var(--cb-accent-ink); color: #fff; transform: translateY(-1px); }
.cb-page .hm-btn--big { padding: 16px 34px; font-size: 18px; }
.cb-page .hm-btn--ghost {
    background: transparent;
    color: var(--cb-accent-ink);
    box-shadow: inset 0 0 0 2px var(--cb-accent);
}
.cb-page .hm-btn--ghost:hover { background: var(--cb-accent); color: #fff; }
.cb-page .hm-btn--light { background: #fff; color: var(--cb-ink); box-shadow: none; }
.cb-page .hm-btn--light:hover { background: #f1ece4; color: var(--cb-ink); }
.cb-page .hm-btn:focus-visible,
.hm-slider__track:focus-visible,
.hm-slider__btn:focus-visible { outline: 3px solid #f2b705; outline-offset: 2px; }

/* --- 1. шапка на весь экран --------------------------------------------- */

.hm-hero {
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    background: var(--cb-dark);
    color: #fff;
    overflow: hidden;
}
.hm-hero__pic { display: block; }
.hm-hero__pic img {
    display: block;
    width: 100%;
    height: auto;
    aspect-ratio: 1020 / 1080;
    object-fit: cover;
    object-position: 50% 40%;
    max-height: 62svh;
}
.hm-hero__shade {
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(to top, var(--cb-dark) 0, rgba(22, 24, 31, .92) 34%, rgba(22, 24, 31, 0) 52%);
}
.hm-hero__text {
    position: relative;
    width: 100%;
    margin-top: -92px;
    padding-bottom: 26px;
}
.hm-hero__title {
    margin: 0 0 10px;
    font-size: 31px;
    line-height: 1.08;
    font-weight: 800;
    letter-spacing: -.02em;
    color: #fff;
    text-shadow: 0 2px 18px rgba(0, 0, 0, .45);
}
/* 07.10.2026: на телефоне справа висит закладка «Обратный звонок» (~32 px) — заголовок под неё не заходит */
@media (max-width: 699px) { .hm-hero__title, .hm-hero__sub { padding-right: 34px; } }
.hm-hero__sub { margin: 0 0 18px; font-size: 16px; line-height: 1.5; color: #e9e6e0; max-width: 34rem; }
.hm-hero__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 10px 18px; }
.hm-hero__price { font-size: 15px; color: #d7d3cc; white-space: nowrap; }

@media (min-width: 700px) {
    .hm-hero { min-height: min(calc(100svh - 64px), 820px); }
    .hm-hero__pic { position: absolute; inset: 0; }
    .hm-hero__pic img { height: 100%; max-height: none; aspect-ratio: auto; object-position: 50% 30%; }
    .hm-hero__shade {
        background:
            linear-gradient(to top, rgba(16, 17, 22, .92) 0, rgba(16, 17, 22, .55) 32%, rgba(16, 17, 22, 0) 62%),
            linear-gradient(to right, rgba(16, 17, 22, .55) 0, rgba(16, 17, 22, 0) 55%);
    }
    .hm-hero__text { margin-top: 0; padding-bottom: 64px; }
    .hm-hero__title { font-size: 52px; max-width: 14em; }
    .hm-hero__sub { font-size: 20px; }
}
@media (min-width: 1100px) { .hm-hero__title { font-size: 62px; } }

/* --- 2. полоса цифр ----------------------------------------------------- */

.hm-facts { background: var(--cb-dark); color: #e6e2db; border-top: 1px solid rgba(255, 255, 255, .08); }
.hm-facts__list {
    list-style: none;
    margin: 0 auto;
    padding-top: 18px;
    padding-bottom: 22px;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px 14px;
}
.hm-facts__list li { display: flex; flex-direction: column; line-height: 1.3; }
.hm-facts__list strong { font-size: 22px; font-weight: 800; color: #fff; letter-spacing: -.01em; }
.hm-facts__list span { font-size: 14px; color: #b9b4ab; }
@media (min-width: 760px) {
    .hm-facts__list { grid-template-columns: repeat(4, 1fr); padding-top: 26px; padding-bottom: 30px; }
    .hm-facts__list li { border-left: 2px solid var(--cb-accent); padding-left: 14px; }
    .hm-facts__list strong { font-size: 28px; }
    .hm-facts__list span { font-size: 15px; }
}

/* --- 3. подойдите ближе: лупа ------------------------------------------- */

.hm-closer__grid { display: grid; gap: 22px; }
@media (min-width: 900px) {
    .hm-closer__grid { grid-template-columns: minmax(0, 5fr) minmax(0, 8fr); align-items: center; gap: 48px; }
}
.hm-closer__hint { margin: 0 0 18px; font-size: 15px; color: var(--cb-muted); }
@media (max-width: 899px) {
    .hm-closer__text .hm-btn { display: none; }   /* на телефоне крупно открывается касанием по картине */
    .hm-closer__hint { margin: 0; }
}

.hm-mag {
    position: relative;
    margin: 0;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 18px 50px rgba(22, 24, 31, .22);
    cursor: zoom-in;
    touch-action: pan-x pan-y pinch-zoom;
    -webkit-user-select: none;
    user-select: none;
    -webkit-touch-callout: none;
    background: #222;
}
.hm-mag.is-live { touch-action: none; box-shadow: 0 0 0 3px var(--cb-accent), 0 18px 50px rgba(22, 24, 31, .22); }
.hm-mag img { display: block; width: 100%; height: auto; pointer-events: none; }
.hm-mag__lens {
    position: absolute;
    left: 0;
    top: 0;
    width: 260px;
    height: 260px;
    border-radius: 50%;
    background-repeat: no-repeat;
    background-color: #333;
    box-shadow: 0 0 0 5px rgba(255, 255, 255, .92), 0 10px 30px rgba(0, 0, 0, .45);
    pointer-events: none;
    opacity: 0;
    transition: opacity .12s ease;
    will-change: transform;
}
@media (max-width: 599px) { .hm-mag__lens { width: 170px; height: 170px; } }
.hm-mag.is-on .hm-mag__lens { opacity: 1; }
.hm-mag__badge {
    position: absolute;
    left: 12px;
    bottom: 12px;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 600;
    color: #fff;
    background: rgba(22, 24, 31, .72);
    border-radius: 999px;
    pointer-events: none;
}
.hm-mag.is-on .hm-mag__badge, .hm-mag.is-live .hm-mag__badge { opacity: 0; }
.hm-mag.is-loading .hm-mag__lens::after {
    content: "";
    position: absolute;
    inset: 42%;
    border: 3px solid rgba(255, 255, 255, .8);
    border-top-color: transparent;
    border-radius: 50%;
    animation: hm-spin .8s linear infinite;
}
@keyframes hm-spin { to { transform: rotate(360deg); } }
.hm-mag__off {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 3;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 44px;
    padding: 0 16px 0 12px;
    font: 700 15px/1 -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    color: var(--cb-ink);
    background: #fff;
    border: 0;
    border-radius: 999px;
    box-shadow: 0 0 0 2px rgba(22, 24, 31, .85), 0 6px 18px rgba(0, 0, 0, .4);
    cursor: pointer;
}
.hm-mag__off span { font-size: 26px; line-height: 1; margin-top: -2px; }
.hm-mag__off[hidden] { display: none; }

/* --- 4. для кого и по какому поводу: витрина ------------------------- */

.hm-occb__grid { list-style: none; margin: 0 0 18px; padding: 0; display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
@media (min-width: 760px) { .hm-occb__grid { grid-template-columns: repeat(4, 1fr); gap: 14px; } }
.hm-occb__grid li:first-child { grid-column: span 2; }
@media (min-width: 760px) { .hm-occb__grid li:first-child { grid-column: auto; grid-row: span 2; } }   /* 7 плиток = ровно 2 ряда по 4 */
.hm-occb__tile {
    position: relative;
    display: block;
    width: 100%;
    height: 100%;
    min-height: 150px;
    padding: 0;
    border: 0;
    border-radius: 14px;
    overflow: hidden;
    background: #ddd6ca;
    cursor: pointer;
    text-align: left;
    font: inherit;
}
.hm-occb__tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.hm-occb__tile:hover img { transform: scale(1.05); }
.hm-occb__tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(16, 17, 22, .85) 0, rgba(16, 17, 22, 0) 60%); }
.hm-occb__label { position: absolute; left: 12px; right: 12px; bottom: 10px; z-index: 1; color: #fff; font-weight: 800; font-size: 17px; line-height: 1.2; }
.hm-occb__count { display: block; margin-top: 3px; font-size: 13px; font-weight: 600; color: #e7e2da; }
.hm-occb__count::after { content: "  ·  открыть ↓"; }
@media (min-width: 760px) { .hm-occb__tile { min-height: 190px; } .hm-occb__label { font-size: 19px; } }
.hm-occb__tile[aria-expanded="true"] { box-shadow: 0 0 0 4px var(--cb-accent); }
.hm-occb__tile[aria-expanded="true"] .hm-occb__count::after { content: "  ·  открыто"; }
.hm-occb__tile:focus-visible { outline: 3px solid #f2b705; outline-offset: 3px; }
.hm-occb__panel { position: relative; padding: 18px; background: #fff; border-radius: 16px; box-shadow: var(--cb-shadow); scroll-margin-top: 12px; }
.hm-occb__panel:focus { outline: none; }
.hm-occb__close { justify-self: start; padding: 10px 16px; font: inherit; font-weight: 700; color: var(--cb-ink); background: #fff; border: 1px solid var(--cb-line); border-radius: 999px; cursor: pointer; }

.hm-panel { display: grid; gap: 22px; }
.hm-panel[hidden] { display: none; }
@media (min-width: 900px) {
    .hm-panel { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); align-items: center; gap: 44px; }
}
.hm-panel__text h3 { margin: 0 0 10px; font-size: 24px; line-height: 1.2; }
@media (min-width: 900px) { .hm-panel__text h3 { font-size: 30px; } }
.hm-panel__text p { margin: 0 0 14px; color: var(--cb-ink-soft); }
.hm-panel__text .hm-btn { margin-top: 8px; }
.hm-panel__link { font-weight: 600; }

/* --- ленты (поводы, скриншоты отзывов) ----------------------------------- */

.hm-slider { position: relative; min-width: 0; }
.hm-slider__track {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding: 0 16px;
    padding: 0 16px 4px;
    margin: 0 -16px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior-x: contain;
}
.hm-slider__track::-webkit-scrollbar { display: none; }
@media (min-width: 900px) {
    .hm-slider__track { margin: 0; padding: 0; scroll-padding: 0; }
}
.hm-slide {
    flex: 0 0 auto;
    scroll-snap-align: start;
    height: 270px;
    border-radius: 12px;
    overflow: hidden;
    background: #ddd6ca;
    cursor: zoom-in;
}
.hm-slide img { display: block; height: 100%; width: auto; max-width: none; object-fit: cover; }
@media (min-width: 900px) { .hm-slide { height: 430px; } }
.hm-slider__btn {
    display: none;
    position: absolute;
    top: 50%;
    width: 46px;
    height: 46px;
    margin-top: -23px;
    font: 400 32px/40px Georgia, serif;
    color: var(--cb-ink);
    background: rgba(255, 255, 255, .95);
    border: 0;
    border-radius: 50%;
    box-shadow: 0 6px 18px rgba(22, 24, 31, .25);
    cursor: pointer;
    z-index: 2;
}
.hm-slider__btn--prev { left: 10px; }
.hm-slider__btn--next { right: 10px; }
.hm-slider__btn:disabled { opacity: 0; pointer-events: none; }
/* 07.10.2026, владелец: стрелки и на телефоне — иначе не понятно, что ленту можно листать (видна лишь полоска
   следующей карточки). На касании — парой ПОД лентой слева: справа посередине экрана висит плашка
   «Обратный звонок» и закрывала бы стрелку «вперёд»; поверх фото стрелки не ставим. */
.hm-slider__btn { display: block; }
/* одноразовый сдвиг карточек — подсказка «ленту листают» (home.js, 08.10.2026) */
@keyframes hm-nudge { 0% { transform: none; } 35% { transform: translateX(-56px); } 70% { transform: translateX(6px); } 100% { transform: none; } }
.hm-nudge > * { animation: hm-nudge 1.2s cubic-bezier(.3, .7, .3, 1) 1; }
@media (hover: none), (pointer: coarse) {
    .hm-slider__btn,
    .hm-slider--styles .hm-slider__btn {
        display: inline-block; position: static; transform: none;
        width: 40px; height: 40px; margin: 12px 10px 0 0;
        font-size: 28px; line-height: 34px; box-shadow: 0 3px 10px rgba(22, 24, 31, .18);
    }
    .hm-slider__btn:disabled { opacity: .35; pointer-events: none; }
    /* лента целиком на экране (планшет, сетка) — листать нечего, пару стрелок прячем */
    .hm-slider:has(.hm-slider__btn--prev:disabled):has(.hm-slider__btn--next:disabled) .hm-slider__btn { display: none; }
}

.hm-wrap--bleed { margin-bottom: 30px; }
.hm-slider--shots .hm-slide { height: 300px; }
@media (min-width: 900px) { .hm-slider--shots .hm-slide { height: 360px; } }

/* --- 5. какой может быть картина ---------------------------------------- */

.hm-styles {
    list-style: none;
    margin: 0 -16px;
    padding: 0 16px 6px;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 74%;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding: 0 16px;
    scrollbar-width: none;
}
.hm-styles::-webkit-scrollbar { display: none; }
@media (min-width: 760px) { .hm-styles { grid-auto-columns: 40%; } }
@media (min-width: 1000px) {
    .hm-styles { margin: 0; padding: 0; grid-auto-flow: row; grid-template-columns: repeat(5, 1fr); overflow: visible; }
}
.hm-style { scroll-snap-align: start; }
/* стрелки ленты — по центру картинки, а не всей карточки с подписью (07.10.2026: мышью ленту не сдвинуть) */
/* середина картинки 3:2 = ширина карточки / 3; карточка — 74 % (телефон) или 40 % ширины ленты */
.hm-slider--styles { --hm-styles-pic: calc((100vw - 32px) * .74 / 3); }
@media (hover: hover) and (pointer: fine) {
    .hm-slider--styles .hm-slider__btn { top: 0; margin-top: 0; transform: translateY(calc(var(--hm-styles-pic) - 23px)); }
}
@media (min-width: 760px) { .hm-slider--styles { --hm-styles-pic: calc((100vw - 56px) * .4 / 3); } }
.hm-style__pic {
    display: block;
    aspect-ratio: 3 / 2;
    border-radius: 12px;
    overflow: hidden;
    background: #eee7dc;
    cursor: zoom-in;
}
.hm-style__pic img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
a.hm-style__pic:hover img { transform: scale(1.04); }
/* сердце на белом холсте: показываем фигуру целиком, а не обрезаем под 3:2 */
.hm-style__pic img[src*="heart-collage"] { object-fit: contain; background: #fff; }
.hm-style h3 { margin: 12px 0 4px; font-size: 18px; line-height: 1.25; }
.hm-style p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--cb-ink-soft); }

/* --- 6. работы клиентов ------------------------------------------------- */

.hm-works {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-auto-rows: 150px;
    grid-auto-flow: dense;
    gap: 8px;
}
.hm-works__item {
    display: block;
    border-radius: 10px;
    overflow: hidden;
    background: #ddd6ca;
    cursor: zoom-in;
}
.hm-works__item:nth-child(5n + 1) { grid-row: span 2; }
.hm-works__item img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.hm-works__item:hover img { transform: scale(1.04); }
.hm-works__item.is-more { display: none; }
.hm-works.is-all .hm-works__item.is-more { display: block; }
.hm-works__more { margin-top: 18px; }
@media (min-width: 760px) {
    .hm-works { grid-template-columns: repeat(4, 1fr); grid-auto-rows: 190px; gap: 12px; }
    .hm-works__item.is-more { display: block; }
    /* 16 работ ровно в 6 рядов по 4: две большие 2×2 и две высокие 1×2, без дыр */
    .hm-works__item:nth-child(n) { grid-row: auto; grid-column: auto; }
    .hm-works__item:nth-child(1), .hm-works__item:nth-child(10) { grid-column: span 2; grid-row: span 2; }
    .hm-works__item:nth-child(6), .hm-works__item:nth-child(13) { grid-row: span 2; }
    .cb-page .hm-works__more { display: none; }
}
@media (min-width: 1100px) { .hm-works { grid-auto-rows: 220px; } }

/* --- 7. отзывы ---------------------------------------------------------- */

.hm-revs {
    list-style: none;
    margin: 0 -16px;
    padding: 0 16px 8px;
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 86%;
    gap: 14px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-padding: 0 16px;
    scrollbar-width: none;
    align-items: start;
}
.hm-revs::-webkit-scrollbar { display: none; }
.hm-rev {
    scroll-snap-align: start;
    padding: 20px 20px 18px;
    background: #fff;
    border: 1px solid var(--cb-line);
    border-radius: 16px;
    box-shadow: var(--cb-shadow);
}
.hm-rev__who { display: flex; align-items: center; gap: 14px; margin-bottom: 12px; }
.hm-rev__ava {
    flex: 0 0 auto;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 0 0 0 3px #fff, 0 0 0 5px var(--cb-accent);
}
.hm-rev__who strong { display: block; font-size: 17px; line-height: 1.2; }
.hm-rev__who span { display: block; font-size: 14px; color: var(--cb-muted); line-height: 1.3; }
.hm-rev__text { margin: 0; font-size: 16px; line-height: 1.6; color: var(--cb-ink-soft); }
.hm-rev__text p { margin: 0 0 10px; }
.hm-rev__text p:last-child { margin-bottom: 0; }
.hm-rev__text.is-clamped {
    display: -webkit-box;
    -webkit-line-clamp: 7;
    -webkit-box-orient: vertical;
    overflow: hidden;
}
.hm-rev__more {
    margin-top: 8px;
    padding: 0;
    font: inherit;
    font-size: 15px;
    font-weight: 600;
    color: var(--cb-accent-ink);
    background: none;
    border: 0;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 2px;
}
@media (min-width: 900px) {
    .hm-revs {
        margin: 0;
        padding: 0;
        display: block;
        columns: 3;
        column-gap: 18px;
        overflow: visible;
    }
    .hm-rev { break-inside: avoid; margin-bottom: 18px; }
    .hm-rev__text.is-clamped { -webkit-line-clamp: 9; }
}

.hm-quote {
    margin: 36px auto 0;
    max-width: 780px;
    padding: 0 0 0 24px;
    border-left: 4px solid var(--cb-accent);
}
.hm-quote blockquote { margin: 0; }
.hm-quote p { margin: 0; font-size: 21px; line-height: 1.5; font-style: italic; color: var(--cb-ink); }
@media (min-width: 760px) { .hm-quote p { font-size: 25px; } }
.hm-quote figcaption { margin-top: 10px; font-size: 15px; color: var(--cb-muted); }

/* --- 8. как это работает ------------------------------------------------ */

.hm-steps {
    list-style: none;
    counter-reset: hm-step;
    margin: 0;
    padding: 0;
    display: grid;
    gap: 14px;
}
@media (min-width: 760px) { .hm-steps { grid-template-columns: repeat(2, 1fr); gap: 18px; } }
@media (min-width: 1100px) { .hm-steps { grid-template-columns: repeat(4, 1fr); } }
.hm-step {
    counter-increment: hm-step;
    position: relative;
    padding: 22px 20px 20px;
    background: #fff;
    border-radius: 16px;
    border: 1px solid var(--cb-line);
}
.hm-step::before {
    content: counter(hm-step);
    display: block;
    margin-bottom: 10px;
    font-size: 44px;
    font-weight: 800;
    line-height: 1;
    color: var(--cb-accent);
    letter-spacing: -.03em;
}
.hm-step h3 { margin: 0 0 8px; font-size: 19px; line-height: 1.25; }
.hm-step p { margin: 0; font-size: 15px; line-height: 1.6; color: var(--cb-ink-soft); }
.hm-how__shot { margin: 26px 0 0; max-width: 680px; }
.hm-how__shot img { display: block; width: 100%; height: auto; border-radius: 12px; border: 1px solid var(--cb-line); background: #fff; }
.hm-how__shot figcaption { margin-top: 8px; font-size: 14px; color: var(--cb-muted); }

/* --- 9. на что можно рассчитывать --------------------------------------- */

.hm-why { list-style: none; margin: 24px 0 0; padding: 0; display: grid; gap: 22px 36px; }
@media (min-width: 760px) { .hm-why { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .hm-why { grid-template-columns: repeat(3, 1fr); } }
.hm-why li { position: relative; padding-left: 40px; }
.hm-why li::before {
    content: "";
    position: absolute;
    left: 0;
    top: 3px;
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: var(--cb-accent) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%23fff' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 16px no-repeat;
}
/* 07.10.2026: вместо галочки — своя иконка пункта в тёплом круге */
.hm-why li { padding-left: 70px; min-height: 54px; }
.hm-why li::before { content: none; }
.hm-why__ic {
    position: absolute; left: 0; top: 0;
    display: flex; align-items: center; justify-content: center;
    width: 54px; height: 54px; border-radius: 50%;
    background: #f6e3dc; color: var(--cb-accent);
}
.hm-why h3 { margin: 0 0 6px; font-size: 19px; line-height: 1.3; }
.hm-why p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--cb-ink-soft); }

/* --- 10. цены и сроки --------------------------------------------------- */

.hm-prices { display: grid; gap: 24px; }
@media (min-width: 900px) { .hm-prices { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 40px; align-items: start; } }
.hm-prices__from { margin: 0 0 16px; font-size: 20px; }
.hm-prices__from strong { font-size: 30px; color: var(--cb-accent-ink); white-space: nowrap; }
.hm-sizes { list-style: none; margin: 0 0 8px; padding: 0; }
.hm-sizes li {
    display: grid;
    grid-template-columns: 72px 1fr auto;
    align-items: center;
    gap: 12px;
    padding: 10px 0;
    border-bottom: 1px solid var(--cb-line);
    font-size: 17px;
}
.hm-sizes__box {
    justify-self: center;
    display: block;
    background: linear-gradient(135deg, #e9c9a1, #c58f63);
    border: 2px solid #8a5d3b;
    border-radius: 2px;
    box-shadow: 1px 2px 0 rgba(0, 0, 0, .12);
}
.hm-sizes strong { white-space: nowrap; }
.hm-sizes__label { margin: 18px 0 2px; font-size: 14px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--cb-muted); }
.hm-sizes--large li { font-size: 16px; color: var(--cb-ink-soft); }
.hm-card-plain {
    padding: 22px 22px 18px;
    background: #fff;
    border: 1px solid var(--cb-line);
    border-radius: 16px;
}
.hm-card-plain + .hm-card-plain { margin-top: 16px; }
.hm-card-plain h3 { margin: 0 0 10px; font-size: 20px; }
.hm-checks { list-style: none; margin: 0 0 10px; padding: 0; }
.hm-checks li { position: relative; padding: 4px 0 4px 28px; font-size: 16px; line-height: 1.5; }
.hm-checks li::before { content: "✓"; position: absolute; left: 2px; top: 3px; font-weight: 800; color: var(--cb-accent); }
.hm-terms { margin: 0; }
.hm-terms dt { font-weight: 700; margin-top: 10px; }
.hm-terms dt:first-child { margin-top: 0; }
.hm-terms dd { margin: 2px 0 0; font-size: 15px; line-height: 1.55; color: var(--cb-ink-soft); }
.hm-terms__urgent { margin: 16px 0 0; padding: 12px 14px; font-size: 15px; background: #fff2cc; border-radius: 10px; }

/* --- 11. ролик ---------------------------------------------------------- */

.hm-video { display: grid; gap: 24px; align-items: center; }
@media (min-width: 900px) { .hm-video { grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: 44px; } }
.hm-video__media { margin: 0; }
.hm-video__media video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; border-radius: 14px; background: #000; box-shadow: 0 18px 50px rgba(0, 0, 0, .45); }
.hm-section--dark .hm-h2 { color: #fff; }
.hm-video__text p { color: #cfcac2; }
.hm-video__price { font-size: 18px; }
.hm-video__price strong { color: #fff; font-size: 22px; }

/* --- 12. для компаний --------------------------------------------------- */

.hm-clients { display: grid; gap: 22px; }
@media (min-width: 900px) { .hm-clients { grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 44px; align-items: center; } }
.hm-clients__text p { margin: 0; color: var(--cb-ink-soft); }
.hm-clients__pics { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.hm-clients__pic { display: block; border-radius: 12px; overflow: hidden; aspect-ratio: 4 / 3; cursor: zoom-in; background: #ddd6ca; }
.hm-clients__pic:first-child { grid-column: span 2; aspect-ratio: 16 / 9; }
.hm-clients__pic img { display: block; width: 100%; height: 100%; object-fit: cover; }

/* --- 13. вопросы -------------------------------------------------------- */

#faq .cb-faq { margin: 0; }
#faq details { background: #fff; border: 1px solid var(--cb-line); border-radius: 12px; padding: 0 18px; margin-bottom: 10px; }
#faq summary { font-size: 17px; }

/* --- 14. почитать ------------------------------------------------------- */

.hm-reads { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px 36px; }
@media (min-width: 760px) { .hm-reads { grid-template-columns: repeat(2, 1fr); } }
.hm-reads li { padding: 0 0 12px; border-bottom: 1px solid var(--cb-line); }
.hm-reads a { font-weight: 700; font-size: 17px; }
.hm-reads span:not(.hm-draft-tag) { display: block; margin-top: 3px; font-size: 14px; line-height: 1.5; color: var(--cb-muted); }

/* --- 15. связь + автор -------------------------------------------------- */

.hm-section--cta .cb-cta { margin-top: 40px; }
.hm-author { display: flex; align-items: center; gap: 16px; margin: 6px 0 0; }
.hm-author__img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; flex: 0 0 auto; }
.hm-author p { margin: 0; color: var(--cb-ink-soft); }

/* --- 16. закреплённая кнопка на телефоне --------------------------------- */

.cb-page .hm-sticky {
    position: fixed;
    left: 16px;
    right: 16px;
    bottom: 14px;
    z-index: 900;
    display: block;
    padding: 14px 20px;
    text-align: center;
    font-weight: 700;
    font-size: 17px;
    color: #fff;
    background: var(--cb-accent);
    border-radius: 999px;
    text-decoration: none;
    box-shadow: 0 10px 28px rgba(22, 24, 31, .35);
    transform: translateY(140%);
    transition: transform .25s ease;
}
.cb-page .hm-sticky:hover { color: #fff; }
.hm-sticky.is-on { transform: translateY(0); }
@media (min-width: 760px) { .cb-page .hm-sticky { display: none; } }
@media (max-width: 759px) { .cb-home .cb-footer, .cb-home footer { padding-bottom: 80px; } }

/* --- лайтбокс ----------------------------------------------------------- */

.hm-lb {
    position: fixed;
    inset: 0;
    z-index: 100005;   /* выше плашки cookies (99999), ниже окна обратного звонка (100010) */
    background: #0c0d11;   /* сплошной: на 0.96 в снимках просвечивали страница и плашка cookies (06.10) */
    color: #fff;
}
.hm-lb[hidden] { display: none; }
.hm-lb__stage {
    position: absolute;
    inset: 0 0 64px;
    overflow: auto;
    display: flex;
    align-items: center;
    justify-content: center;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
}
.hm-lb.is-zoom .hm-lb__stage { display: block; }
.hm-lb__img {
    display: block;
    max-width: calc(100% - 24px);
    max-height: calc(100% - 24px);
    width: auto;
    height: auto;
    margin: auto;
    cursor: zoom-in;
    -webkit-user-select: none;
    user-select: none;
}
.hm-lb.is-zoom .hm-lb__img { cursor: zoom-out; margin: 0; }
.hm-lb__bar {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 64px;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 12px 0 16px;
    background: rgba(0, 0, 0, .5);
}
.hm-lb__count { font-size: 14px; color: #bbb; white-space: nowrap; }
.hm-lb__cap { flex: 1 1 auto; margin: 0; font-size: 14px; line-height: 1.35; color: #ddd; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.hm-lb__btn, .hm-lb__nav {
    flex: 0 0 auto;
    width: 44px;
    height: 44px;
    font: 400 28px/1 sans-serif;
    color: #fff;
    background: rgba(255, 255, 255, .14);
    border: 0;
    border-radius: 50%;
    cursor: pointer;
}
.hm-lb__btn:hover, .hm-lb__nav:hover { background: rgba(255, 255, 255, .26); }
.hm-lb__nav { position: absolute; top: 50%; margin-top: -54px; width: 52px; height: 52px; font-size: 36px; }
.hm-lb__nav[hidden] { display: none; }
.hm-lb__nav--prev { left: 10px; }
.hm-lb__nav--next { right: 10px; }
@media (hover: none) { .hm-lb__nav { display: none; } }
.hm-lb.is-zoom .hm-lb__nav { display: none; }
.hm-lb__loading { display: none; position: absolute; left: 0; right: 0; top: 45%; margin: 0; text-align: center; color: #aaa; }
.hm-lb.is-loading .hm-lb__loading { display: block; }

/* крестик крупного просмотра: правый верхний угол, всегда поверх, контрастный на любом фоне, с учётом выреза экрана */
.hm-lb__close {
    position: absolute;
    top: max(12px, calc(env(safe-area-inset-top, 0px) + 8px));
    right: max(12px, calc(env(safe-area-inset-right, 0px) + 8px));
    z-index: 5;
    width: 52px;
    height: 52px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font: 400 38px/1 -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    color: #16181f;
    background: #fff;
    border: 0;
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(0, 0, 0, .55), 0 6px 20px rgba(0, 0, 0, .55);
    cursor: pointer;
}
.hm-lb__close span { margin-top: -4px; }
.hm-lb__close:hover { background: #f1ece4; }
.hm-lb__close:focus-visible { outline: 3px solid #f2b705; outline-offset: 3px; }
.hm-lb__bar { padding-bottom: env(safe-area-inset-bottom, 0px); }

/* ===== Примерка размера на стене (блок «Цены и сроки», 07.10.2026, прототип proto/size-preview) ===== */
.sp-intro { margin: 0 0 22px; color: var(--cb-ink-soft); font-size: 16px; line-height: 1.5; max-width: 40rem; }

.sp-grid { display: grid; gap: 18px; }
@media (min-width: 960px) {
  .sp-grid { grid-template-columns: minmax(0, 1fr) 390px; gap: 32px; align-items: start; }
}

/* --- сцена ----------------------------------------------------------------- */
.sp-scene {
  position: relative;
  margin: 0;
  aspect-ratio: 360 / 250;
  border-radius: 14px;
  overflow: hidden;
  background: #efe4d3;
  box-shadow: var(--cb-shadow);
}
.sp-room { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }

.sp-ruler__text {
  position: absolute;
  left: 47.22%; bottom: 2.6%;    /* центр дивана — 170 из 360 см */
  transform: translate(-50%, 0);
  padding: 0 6px;
  font-size: 12px; line-height: 1.3; font-weight: 600;
  color: #4b3a2d;
  background: #c9a27c;
  border-radius: 4px;
  white-space: nowrap;
}

.sp-canvas { position: absolute; }
.sp-grid.is-ready .sp-canvas {
  transition: left .45s cubic-bezier(.3,.7,.2,1), top .45s cubic-bezier(.3,.7,.2,1),
              width .45s cubic-bezier(.3,.7,.2,1), height .45s cubic-bezier(.3,.7,.2,1);
}
.sp-canvas__img {
  position: absolute; inset: 0;
  background: #ddd center / cover no-repeat;
  border-radius: 1px;
  box-shadow: 1px 2px 0 rgba(40, 28, 18, .25), 4px 10px 18px rgba(60, 40, 20, .28);
}
.sp-dim {
  position: absolute;
  font-size: 11px; line-height: 1; font-weight: 700;
  color: #5b4636;
  white-space: nowrap;
}
.sp-dim--w { left: 0; right: 0; bottom: 100%; padding-bottom: 5px; text-align: center; border-bottom: 1px solid rgba(91,70,54,.45); margin-bottom: 4px; }
.sp-dim--h {
  left: 100%; top: 0; bottom: 0; margin-left: 6px;
  border-left: 1px solid rgba(91,70,54,.45); padding-left: 4px;
  display: flex; align-items: center;
}

/* --- панель ---------------------------------------------------------------- */
.sp-tabs {
  display: inline-flex;
  padding: 4px;
  margin-bottom: 14px;
  background: #efe6d8;
  border-radius: 999px;
}
.sp-tab {
  border: 0; background: none; cursor: pointer;
  padding: 9px 18px;
  border-radius: 999px;
  font: inherit; font-size: 15px; font-weight: 600;
  color: var(--cb-ink-soft);
}
.sp-tab.is-on { background: #fff; color: var(--cb-ink); box-shadow: 0 1px 4px rgba(22,24,31,.12); }

.sp-sizes { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.sp-sizes.is-hidden { display: none; }
.sp-size {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 9px 10px;
  border: 1.5px solid var(--cb-line);
  border-radius: 10px;
  background: #fff;
  cursor: pointer;
  font: inherit; text-align: left;
  transition: border-color .15s, box-shadow .15s;
}
.sp-size:hover { border-color: #cdbfa9; }
.sp-size__s { font-size: 15px; font-weight: 700; color: var(--cb-ink); line-height: 1.2; }
.sp-size__p { font-size: 13px; color: var(--cb-muted); line-height: 1.2; white-space: nowrap; }
.sp-size.is-on { border-color: var(--cb-accent); box-shadow: 0 0 0 1px var(--cb-accent) inset; }
.sp-size.is-on .sp-size__p { color: var(--cb-accent-ink); font-weight: 600; }
.sp-size--extra { display: none; }
.sp-sizes.is-open .sp-size--extra { display: flex; }
.sp-sizes.is-open .sp-more { display: none; }
.sp-more {
  grid-column: 1 / -1;
  justify-self: start;
  border: 0; background: none; padding: 4px 0; cursor: pointer;
  font: inherit; font-size: 15px; font-weight: 600;
  color: var(--cb-accent-ink);
  text-decoration: underline; text-underline-offset: 3px;
}
.sp-size:focus-visible, .sp-tab:focus-visible, .sp-more:focus-visible, .sp-btn:focus-visible {
  outline: 2px solid var(--cb-accent); outline-offset: 2px;
}

.sp-result {
  margin-top: 16px;
  padding: 16px 18px;
  background: #fff;
  border-radius: var(--cb-radius);
  box-shadow: var(--cb-shadow);
}
.sp-result__row { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; }
.sp-result__size { font-size: 26px; font-weight: 800; letter-spacing: -.01em; line-height: 1.1; }
.sp-result__price { font-size: 20px; font-weight: 700; color: var(--cb-accent-ink); margin-top: 2px; }
.hm-section .sp-btn {
  display: inline-block;
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--cb-accent);
  color: #fff; text-decoration: none; font-weight: 700; font-size: 16px;
}
.hm-section .sp-btn:hover { background: var(--cb-accent-ink); color: #fff; }
.sp-hint { margin: 12px 0 0; font-size: 15px; line-height: 1.5; color: var(--cb-ink); }
.sp-note { margin: 8px 0 0; font-size: 13px; line-height: 1.5; color: var(--cb-muted); }


/* --- телефон --------------------------------------------------------------- */
@media (max-width: 599px) {
  .sp-scene { border-radius: 10px; margin: 0 -4px; }
  .sp-dim { font-size: 10px; }
  .sp-ruler__text { font-size: 10px; }
  .sp-tabs { display: flex; }
  .sp-tab { flex: 1; padding: 9px 8px; }
  .sp-size { padding: 8px; }
  .sp-size__s { font-size: 14px; }
  .sp-result__size { font-size: 22px; }
  .sp-result__price { font-size: 18px; }
}
@media (prefers-reduced-motion: reduce) {
  .sp-grid.is-ready .sp-canvas { transition: none; }
}

/* под сценой — две карточки «В цену входит» и «Сроки» */
.hm-prices--under { margin-top: 28px; }
@media (min-width: 760px) { .hm-prices--under { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; align-items: start; } .hm-prices--under .hm-card-plain { margin: 0; } }
.sp-from { margin: 0 0 6px; font-size: 18px; }
.sp-from strong { color: var(--cb-accent-ink); }
