/* ============================================================
   Страница компании (/company/ID) и окно онлайн-записи
   ============================================================ */
body.cp {
    --cp-accent: #6d4fd1;
    --cp-accent-2: #9b6bff;
    --cp-ink: #17142a;
    --cp-muted: #6e6a80;
    --cp-line: #ece9f3;
    --cp-bg: #f7f6fb;
    --cp-card: #ffffff;
    --cp-radius: 22px;
    --cp-shadow: 0 1px 2px rgba(23, 20, 42, .04), 0 12px 40px rgba(23, 20, 42, .08);
    font-family: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
    background: var(--cp-bg);
    color: var(--cp-ink);
    -webkit-font-smoothing: antialiased;
}
body.cp h1, body.cp h2, body.cp h3 { font-weight: 700; letter-spacing: -.02em; }
body.cp.cp-lock { overflow: hidden; }
.cp-wrap { max-width: 1180px; margin: 0 auto; padding: 0 20px; }

/* ---------- кнопки ---------- */
.cp-btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    border: 0; border-radius: 14px; padding: 12px 20px; font-weight: 600; font-size: 15px;
    text-decoration: none; cursor: pointer; transition: transform .15s, box-shadow .15s, background .15s; white-space: nowrap;
}
.cp-btn:active { transform: scale(.98); }
.cp-btn-primary { color: #fff; background: linear-gradient(135deg, var(--cp-accent), var(--cp-accent-2)); box-shadow: 0 10px 24px rgba(109, 79, 209, .32); }
.cp-btn-primary:hover { color: #fff; box-shadow: 0 14px 30px rgba(109, 79, 209, .42); transform: translateY(-1px); }
.cp-btn-ghost { color: var(--cp-ink); background: #fff; border: 1px solid var(--cp-line); }
.cp-btn-ghost:hover { color: var(--cp-accent); border-color: #d9d0f5; }
.cp-btn-soft { color: var(--cp-accent); background: #f1ecff; }
.cp-btn-soft:hover { color: #fff; background: var(--cp-accent); }
.cp-btn-sm { padding: 8px 14px; font-size: 13.5px; border-radius: 11px; }
.cp-btn-lg { padding: 15px 26px; font-size: 16px; border-radius: 16px; }

/* ---------- верхняя панель ---------- */
.cp-bar { position: fixed; top: 0; left: 0; right: 0; z-index: 50; transition: background .25s, box-shadow .25s; }
.cp-bar-in { display: flex; align-items: center; gap: 14px; height: 64px; }
.cp-bar-brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: #fff; min-width: 0; margin-right: auto; opacity: 0; transition: opacity .25s; }
.cp-bar-brand img, .cp-bar-brand span { width: 34px; height: 34px; border-radius: 10px; object-fit: cover; flex: none; background: #fff; }
.cp-bar-brand span { display: flex; align-items: center; justify-content: center; color: var(--cp-accent); font-weight: 700; }
.cp-bar-brand b { font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cp-langs { display: flex; gap: 2px; background: rgba(255, 255, 255, .18); backdrop-filter: blur(10px); border-radius: 10px; padding: 3px; margin-left: auto; }
.cp-langs a { color: #fff; text-decoration: none; font-size: 12px; font-weight: 600; padding: 4px 8px; border-radius: 7px; }
.cp-langs a.active { background: #fff; color: var(--cp-ink); }
.cp-bar-book { padding: 9px 16px; font-size: 14px; opacity: 0; pointer-events: none; transition: opacity .25s; }
.cp-bar.solid { background: rgba(255, 255, 255, .98); box-shadow: 0 1px 0 var(--cp-line); }
.cp-bar.solid .cp-bar-brand { opacity: 1; color: var(--cp-ink); }
.cp-bar.solid .cp-langs { background: #f1eff6; }
.cp-bar.solid .cp-langs a { color: var(--cp-muted); }
.cp-bar.solid .cp-langs a.active { color: var(--cp-ink); }
body.cp-scrolled .cp-bar-book { opacity: 1; pointer-events: auto; }
.cp-bar.solid .cp-bar-brand { margin-right: 0; }
.cp-bar.solid .cp-langs { margin-left: auto; }

/* ---------- обложка ---------- */
.cp-hero { position: relative; height: min(58vh, 520px); min-height: 280px; overflow: hidden; background: #221a3f; }
.cp-hero-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: cp-zoom 1.6s cubic-bezier(.2, .8, .2, 1) both; }
@keyframes cp-zoom { from { transform: scale(1.06); opacity: .6; } to { transform: none; opacity: 1; } }
/* страница: прокрутка колёсиком без «плавности» браузера из общего стиля (она даёт рывки на длинной странице) */
html:has(body.cp) { scroll-behavior: auto; }
.cp-sec, .cp-side-card { contain: layout paint; }
.cp-hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(10, 8, 25, .45) 0%, rgba(10, 8, 25, 0) 30%, rgba(10, 8, 25, 0) 55%, rgba(10, 8, 25, .55) 100%); }
.cp-hero.no-cover { height: min(40vh, 360px); background:
    radial-gradient(60% 80% at 15% 20%, rgba(155, 107, 255, .9), transparent 60%),
    radial-gradient(50% 70% at 85% 30%, rgba(255, 138, 190, .75), transparent 60%),
    radial-gradient(60% 80% at 60% 100%, rgba(80, 180, 255, .55), transparent 60%),
    linear-gradient(135deg, #2b1d63, #5b3fc4); }
.cp-hero.no-cover .cp-hero-shade { background: linear-gradient(180deg, rgba(10, 8, 25, .25), rgba(10, 8, 25, .1)); }

/* ---------- карточка компании ---------- */
.cp-profile {
    position: relative; z-index: 2; margin-top: -110px;
    display: grid; grid-template-columns: auto 1fr auto; gap: 24px; align-items: center;
    background: var(--cp-card); border-radius: 28px; padding: 26px 28px; box-shadow: 0 20px 60px rgba(23, 20, 42, .14);
}
.cp-logo { width: 112px; height: 112px; border-radius: 28px; overflow: hidden; background: #fff; box-shadow: 0 0 0 5px #fff, 0 12px 30px rgba(23, 20, 42, .16); flex: none; margin-top: -58px; align-self: start; }
.cp-logo img { width: 100%; height: 100%; object-fit: cover; }
.cp-logo span { display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; font-size: 44px; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--cp-accent), var(--cp-accent-2)); }
.cp-profile h1 { font-size: clamp(26px, 3.4vw, 38px); margin: 4px 0 4px; line-height: 1.1; }
.cp-slogan { color: var(--cp-muted); font-size: 16px; margin: 0 0 8px; }
.cp-cats { display: flex; flex-wrap: wrap; gap: 6px; }
.cp-cats span { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; font-weight: 600; color: var(--cp-accent); background: #f1ecff; border-radius: 999px; padding: 4px 11px; }
.cp-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; font-size: 14px; color: var(--cp-muted); margin-top: 6px; }
.cp-meta > span { display: inline-flex; align-items: center; gap: 6px; }
.cp-status { display: inline-flex; align-items: center; gap: 7px; font-weight: 600; color: #b45309; font-size: 14px; }
.cp-status i { width: 8px; height: 8px; border-radius: 50%; background: #f59e0b; box-shadow: 0 0 0 4px rgba(245, 158, 11, .18); }
.cp-status.open { color: #15803d; }
.cp-status.open i { background: #22c55e; box-shadow: 0 0 0 4px rgba(34, 197, 94, .18); animation: cp-pulse 2s infinite; }
@keyframes cp-pulse { 50% { box-shadow: 0 0 0 7px rgba(34, 197, 94, .05); } }
.cp-actions { display: flex; flex-direction: column; gap: 10px; align-items: stretch; min-width: 250px; }
.cp-actions-row { display: flex; gap: 8px; }
.cp-actions-row .cp-btn { flex: 1; padding: 10px 12px; font-size: 13.5px; }

/* ---------- меню разделов ---------- */
.cp-tabs {
    position: sticky; top: 64px; z-index: 20; display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none;
    margin: 22px 0 18px; padding: 6px; background: #efedf5; border-radius: 16px;
}
.cp-tabs::-webkit-scrollbar { display: none; }
.cp-tabs a { flex: none; text-decoration: none; color: var(--cp-muted); font-weight: 600; font-size: 14.5px; padding: 9px 16px; border-radius: 12px; }
.cp-tabs a:hover { color: var(--cp-ink); }
.cp-tabs a.active { background: #fff; color: var(--cp-ink); box-shadow: 0 2px 10px rgba(23, 20, 42, .08); }

/* ---------- раскладка ---------- */
.cp-layout { display: grid; grid-template-columns: minmax(0, 1fr) 330px; gap: 24px; align-items: start; }
.cp-side { position: sticky; top: 136px; }
.cp-side-card { background: var(--cp-card); border-radius: var(--cp-radius); padding: 22px; box-shadow: var(--cp-shadow); }
.cp-side-title { font-size: 19px; font-weight: 700; margin-bottom: 4px; }
.cp-side-card p { color: var(--cp-muted); font-size: 14px; margin-bottom: 14px; }
.cp-side-phone { display: flex; align-items: center; gap: 8px; margin-top: 12px; font-weight: 600; color: var(--cp-ink); text-decoration: none; }
.cp-side-soc { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--cp-line); }
.cp-side-soc a { width: 38px; height: 38px; border-radius: 12px; background: #f4f2f9; color: var(--cp-ink); display: flex; align-items: center; justify-content: center; font-size: 17px; text-decoration: none; }
.cp-side-soc a:hover { background: #ebe5fb; color: var(--cp-accent); }

.cp-sec { background: var(--cp-card); border-radius: var(--cp-radius); padding: 24px; box-shadow: var(--cp-shadow); margin-bottom: 20px; scroll-margin-top: 140px; }
.cp-sec-head { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin-bottom: 16px; }
.cp-sec-head h2 { font-size: 22px; margin: 0; margin-right: auto; }
.cp-sec-sub { color: var(--cp-muted); font-size: 14px; }

/* ---------- услуги ---------- */
.cp-chips { display: flex; gap: 6px; overflow-x: auto; scrollbar-width: none; max-width: 100%; }
.cp-chips button { flex: none; border: 1px solid var(--cp-line); background: #fff; border-radius: 999px; padding: 6px 13px; font-size: 13px; font-weight: 600; color: var(--cp-muted); }
.cp-chips button.active { background: var(--cp-ink); color: #fff; border-color: var(--cp-ink); }
.cp-svc-group { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--cp-muted); margin: 18px 0 6px; }
.cp-svc-group:first-child { margin-top: 0; }
.cp-svc { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--cp-line); }
.cp-svc:last-child { border-bottom: 0; }
.cp-svc-info { flex: 1 1 auto; min-width: 0; }
.cp-svc-info b { font-size: 15.5px; font-weight: 600; }
.cp-svc-info p { margin: 3px 0 2px; font-size: 13.5px; color: var(--cp-muted); display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cp-svc-info small { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; color: var(--cp-muted); }
.cp-svc-price { font-weight: 700; font-size: 16px; white-space: nowrap; display: flex; flex-direction: column; align-items: flex-end; gap: 2px; }
.cp-price-was { font-weight: 500; font-size: 13px; color: var(--cp-muted, #94a3b8); }
.cp-price-now { font-weight: 700; color: #c2410c; }
.cp-promo-badge {
    display: inline-block; font-size: 11px; font-weight: 600; line-height: 1.2;
    padding: 2px 7px; border-radius: 999px; background: #fff7ed; color: #c2410c;
}
.cp-class-list { display: flex; flex-direction: column; gap: 0; }
.cp-class-day {
    font-size: 13px; font-weight: 600; color: var(--cp-muted, #64748b);
    margin: 16px 0 6px; text-transform: capitalize;
}
.cp-class-day:first-child { margin-top: 0; }
.cp-class {
    display: flex; align-items: center; gap: 12px; padding: 12px 0;
    border-bottom: 1px solid rgba(15, 23, 42, .06);
}
.cp-class-time { min-width: 64px; text-align: center; }
.cp-class-time b { display: block; font-size: 16px; }
.cp-class-time small { color: var(--cp-muted, #94a3b8); }
.cp-class-info { flex: 1; min-width: 0; }
.cp-class-info b { display: block; }
.cp-class-info small { color: var(--cp-muted, #64748b); }
.cp-class-seats { display: inline-block; margin-top: 2px; font-size: 12px; color: #15803d; }
.cp-class-seats.is-low { color: #c2410c; }

/* ---------- ресурсы ---------- */
/* типы: фильтр-чипы, группа с шапкой (значок, название, коротко о типе), сетка карточек 1 / 2 / 3 колонки */
.cp-res-chips { flex-basis: 100%; }
.cp-chips button .bi { margin-right: 6px; color: var(--tc, inherit); }
.cp-chips button em { font-style: normal; margin-left: 6px; opacity: .6; font-weight: 500; }
.cp-chips button.active .bi { color: inherit; }
.cp-res-group + .cp-res-group { margin-top: 26px; }
.cp-res-ghead { display: flex; align-items: center; gap: 12px; margin-bottom: 12px; }
.cp-res-gico { width: 42px; height: 42px; flex: none; border-radius: 13px; display: flex; align-items: center; justify-content: center; font-size: 19px; color: var(--tc); background: color-mix(in srgb, var(--tc) 14%, #fff); }
.cp-res-ghead h3 { font-size: 17px; font-weight: 700; margin: 0 0 4px; }
.cp-res-ghead h3 em { font-style: normal; font-weight: 500; font-size: 14px; color: var(--cp-muted); margin-left: 8px; }
.cp-res-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.cp-res-tags-top { margin: -6px 0 14px; }
.cp-res-tags span { display: inline-flex; align-items: center; gap: 5px; font-size: 12.5px; font-weight: 600; color: #4a4560; background: #f4f2f9; border-radius: 999px; padding: 3px 10px; }
.cp-res-tags .bi { color: var(--tc, var(--cp-accent)); }
.cp-res-grid { display: grid; grid-template-columns: 1fr; gap: 14px; }
@media (min-width: 576px) { .cp-res-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .cp-res-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.cp-res { position: relative; border: 1px solid var(--cp-line); border-radius: 18px; display: flex; flex-direction: column; overflow: hidden; background: #fff; transition: box-shadow .2s, border-color .2s; }
.cp-res:hover { border-color: #ddd6f3; box-shadow: 0 10px 30px rgba(23, 20, 42, .08); }
.cp-res::before { content: ""; position: absolute; left: 0; top: 0; right: 0; height: 3px; background: var(--rc); z-index: 2; }
.cp-res-body { flex: 1 1 auto; display: flex; flex-direction: column; padding: 14px 16px 16px; }
.cp-res-name { font-size: 16px; font-weight: 700; }
.cp-res p { font-size: 13px; color: var(--cp-muted); margin: 4px 0 0; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.cp-res-facts { list-style: none; padding: 0; margin: 8px 0 0; display: flex; flex-direction: column; gap: 4px; font-size: 13px; color: #4a4560; }
.cp-res-facts li { display: flex; gap: 7px; align-items: baseline; }
.cp-res-facts .bi { color: var(--cp-muted); flex: none; }
.cp-res-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; margin-top: auto; padding-top: 12px; }
.cp-res-price { font-weight: 700; font-size: 17px; white-space: nowrap; }
.cp-res-price small { font-weight: 500; color: var(--cp-muted); font-size: 12.5px; }
.cp-res-prices { display: flex; flex-wrap: wrap; gap: 6px; flex: 1 1 auto; min-width: 0; }
.cp-res-prices span {
    display: inline-flex; align-items: baseline; gap: 4px;
    font-size: 12.5px; font-weight: 600; color: #3f3a52;
    background: #f4f2f9; border-radius: 999px; padding: 4px 10px; white-space: nowrap;
}
.cp-res-foot .cp-btn { margin-left: auto; }
/* «Позвонить» (ресурс без онлайн-брони): на компьютере — сам номер, его видно и можно скопировать */
.cp-res-call { color: #15803d; background: #e8f7ee; }
.cp-res-call:hover { color: #fff; background: #16a34a; }
.cp-res-call .cp-call-num { display: none; white-space: nowrap; }
@media (min-width: 992px) and (hover: hover) {
    .cp-res-call:has(.cp-call-num) .cp-call-txt { display: none; }
    .cp-res-call .cp-call-num { display: inline; user-select: all; }
}
/* фото ресурса: обложка 4:3 во всю ширину карточки, листается свайпом; без фото — значок типа на его цвете */
.cp-res-media { position: relative; aspect-ratio: 4 / 3; background: color-mix(in srgb, var(--rc) 10%, #f4f4f7); }
.cp-res-media.is-empty { display: flex; align-items: center; justify-content: center; font-size: 46px; color: var(--tc, var(--rc));
    background: radial-gradient(circle at 30% 20%, color-mix(in srgb, var(--tc, var(--rc)) 16%, #fff), color-mix(in srgb, var(--tc, var(--rc)) 6%, #f7f6fb)); }
.cp-res-media.is-empty .bi { opacity: .75; }
.cp-res-track { display: flex; height: 100%; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain; }
.cp-res-track::-webkit-scrollbar { display: none; }
.cp-res-slide { flex: 0 0 100%; height: 100%; scroll-snap-align: start; border: 0; padding: 0; background: none; cursor: zoom-in; }
.cp-res-slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cp-res-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 32px; height: 32px; border: 0; border-radius: 50%; background: rgba(255, 255, 255, .9); color: #111; display: flex; align-items: center; justify-content: center; font-size: 14px; box-shadow: 0 2px 8px rgba(0, 0, 0, .18); opacity: 0; transition: opacity .2s; }
.cp-res-nav.prev { left: 8px; } .cp-res-nav.next { right: 8px; }
.cp-res-media:hover .cp-res-nav { opacity: 1; }
.cp-res-media.at-start .cp-res-nav.prev, .cp-res-media.at-end .cp-res-nav.next { visibility: hidden; }
.cp-res-dots { position: absolute; left: 0; right: 0; bottom: 8px; display: flex; justify-content: center; gap: 5px; pointer-events: none; }
.cp-res-dots i { width: 6px; height: 6px; border-radius: 50%; background: rgba(255, 255, 255, .6); box-shadow: 0 0 2px rgba(0, 0, 0, .35); transition: width .2s; }
.cp-res-dots i.active { width: 16px; border-radius: 3px; background: #fff; }
@media (hover: none) { .cp-res-nav { display: none; } }

/* ---------- команда ---------- */
.cp-team { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 14px; }
.cp-person { text-align: center; border-radius: 18px; padding: 18px 12px; background: linear-gradient(180deg, #faf9fd, #fff); border: 1px solid var(--cp-line); display: flex; flex-direction: column; align-items: center; gap: 4px; }
.cp-person img, .cp-person-ava { width: 96px; height: 96px; border-radius: 50%; object-fit: cover; margin-bottom: 8px; box-shadow: 0 0 0 4px #fff, 0 8px 22px rgba(23, 20, 42, .14); }
.cp-person-ava { display: flex; align-items: center; justify-content: center; font-size: 30px; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--pc), color-mix(in srgb, var(--pc) 60%, #fff)); }
.cp-person b { font-size: 15px; }
.cp-person small { color: var(--cp-muted); font-size: 12.5px; margin-bottom: 6px; }

/* ---------- галерея ---------- */
.cp-gallery { display: grid; gap: 8px; grid-template-columns: repeat(4, 1fr); grid-auto-rows: 150px; }
.cp-g { position: relative; border: 0; padding: 0; border-radius: 14px; overflow: hidden; background: #eee; cursor: zoom-in; }
.cp-g img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.cp-g:hover img { transform: scale(1.05); }
.cp-gallery .cp-g:first-child { grid-column: span 2; grid-row: span 2; }
.cp-gallery .cp-g:nth-child(n + 6) { display: none; }
.cp-gallery-1 { grid-template-columns: 1fr; grid-auto-rows: 320px; }
.cp-gallery-1 .cp-g:first-child { grid-column: auto; grid-row: auto; }
.cp-gallery-2 { grid-template-columns: 1fr 1fr; grid-auto-rows: 260px; }
.cp-gallery-2 .cp-g:first-child { grid-column: auto; grid-row: auto; }
.cp-gallery-3 { grid-template-columns: 2fr 1fr; }
.cp-gallery-3 .cp-g:first-child { grid-column: auto; }
.cp-g-more { position: absolute; inset: 0; background: rgba(10, 8, 25, .55); color: #fff; display: flex; align-items: center; justify-content: center; font-size: 26px; font-weight: 700; }

/* ---------- о нас ---------- */
.cp-about { font-size: 15.5px; line-height: 1.7; color: #3b3752; }

/* ---------- контакты ---------- */
.cp-branches { display: flex; flex-direction: column; gap: 16px; }
.cp-branch { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; border: 1px solid var(--cp-line); border-radius: 18px; padding: 18px; }
.cp-branch h3 { font-size: 17px; margin: 0 0 6px; }
.cp-contact-list { list-style: none; padding: 0; margin: 12px 0; display: flex; flex-direction: column; gap: 9px; }
.cp-contact-list li { display: flex; gap: 10px; font-size: 14.5px; }
.cp-contact-list .bi { color: var(--cp-accent); font-size: 16px; }
.cp-contact-list a { color: var(--cp-ink); text-decoration: none; font-weight: 500; }
.cp-contact-list a:hover { color: var(--cp-accent); }
.cp-contact-list small { display: block; color: var(--cp-muted); font-size: 12.5px; }
.cp-hours { width: 100%; font-size: 13.5px; border-collapse: collapse; }
.cp-hours th { font-weight: 500; color: var(--cp-muted); padding: 4px 0; width: 44px; }
.cp-hours td { padding: 4px 0; text-align: right; font-variant-numeric: tabular-nums; }
.cp-hours tr.today th, .cp-hours tr.today td { color: var(--cp-accent); font-weight: 700; }
.cp-hours .off { color: #b0acbd; }
.cp-map { border-radius: 14px; overflow: hidden; min-height: 240px; background: #eef0f4; cursor: pointer; }
.cp-map iframe { width: 100%; height: 100%; min-height: 240px; border: 0; display: block; }
.cp-map-ph { height: 100%; min-height: 240px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; color: var(--cp-muted); font-weight: 600;
    background: repeating-linear-gradient(45deg, #eef0f4 0 12px, #e8eaf0 12px 24px); }
.cp-map-ph .bi { font-size: 30px; color: var(--cp-accent); }
.cp-social { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.cp-soc { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; color: var(--cp-ink); font-weight: 600; font-size: 13.5px; border: 1px solid var(--cp-line); border-radius: 12px; padding: 8px 12px; }
.cp-soc:hover { border-color: #d9d0f5; color: var(--cp-accent); }
.cp-soc > .bi { font-size: 16px; }
.cp-soc-instagram > .bi { color: #e1306c; } .cp-soc-telegram > .bi { color: #229ed9; } .cp-soc-whatsapp > .bi { color: #25d366; }
.cp-soc-facebook > .bi { color: #1877f2; } .cp-soc-youtube > .bi { color: #ff0000; }
.soc-mark { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 6px; color: #fff; font-size: 10px; font-weight: 700; line-height: 1; }
.soc-mark svg { width: 12px; height: 12px; fill: currentColor; }
.soc-vk { background: #0077ff; } .soc-rutube { background: #14191f; color: #ff2e5b; } .soc-dzen { background: #000; }

.cp-footer { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; padding: 26px 0 110px; color: var(--cp-muted); font-size: 13px; }
.cp-footer a { color: var(--cp-muted); text-decoration: none; }
.cp-footer a:hover { color: var(--cp-accent); }

/* ---------- телефон: кнопка записи внизу ---------- */
.cp-mobile-bar { display: none; }
@media (max-width: 991.98px) {
    .cp-layout { grid-template-columns: 1fr; }
    .cp-side { display: none; }
    .cp-profile { grid-template-columns: 1fr; gap: 14px; text-align: left; padding: 22px 20px; margin-top: -80px; }
    .cp-logo { width: 92px; height: 92px; border-radius: 24px; margin-top: -68px; }
    .cp-actions { min-width: 0; }
    .cp-actions > .cp-btn-lg { display: none; }
    .cp-mobile-bar { display: flex; gap: 10px; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; padding: 12px 16px calc(12px + env(safe-area-inset-bottom));
        background: #fff; box-shadow: 0 -6px 24px rgba(23, 20, 42, .1); }
    .cp-mobile-bar .cp-btn { padding: 14px 16px; }
    .cp-mb-call { width: 52px; flex: none; padding: 0 !important; font-size: 18px; }
    .cp-branch { grid-template-columns: 1fr; }
    .cp-bar-book { display: none; }
}
@media (max-width: 575.98px) {
    .cp-wrap { padding: 0 12px; }
    .cp-sec { padding: 18px 16px; border-radius: 18px; }
    .cp-hero { height: 300px; min-height: 0; }
    .cp-hero.no-cover { height: 220px; }
    .cp-gallery { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 120px; }
    .cp-gallery .cp-g:first-child { grid-column: span 2; grid-row: span 2; }
    .cp-svc { flex-wrap: wrap; }
    .cp-svc-info { flex-basis: 100%; }
    .cp-svc-price { margin-right: auto; }
    .cp-team { grid-template-columns: repeat(2, 1fr); gap: 10px; }
    .cp-person img, .cp-person-ava { width: 76px; height: 76px; }
    .cp-tabs { top: 64px; margin: 14px 0 12px; }
}

/* ---------- просмотр фото ---------- */
.cp-lb { position: fixed; inset: 0; z-index: 100; background: rgba(8, 6, 18, .94); display: flex; align-items: center; justify-content: center; }
.cp-lb[hidden] { display: none; }
.cp-lb img { max-width: 92vw; max-height: 86vh; border-radius: 12px; box-shadow: 0 20px 60px rgba(0, 0, 0, .5); }
.cp-lb-close, .cp-lb-nav { position: absolute; border: 0; width: 48px; height: 48px; border-radius: 50%; background: rgba(255, 255, 255, .12); color: #fff; font-size: 20px; display: flex; align-items: center; justify-content: center; }
.cp-lb-close:hover, .cp-lb-nav:hover { background: rgba(255, 255, 255, .24); }
.cp-lb-close { top: 18px; right: 18px; }
.cp-lb-nav.prev { left: 18px; } .cp-lb-nav.next { right: 18px; }
.cp-lb-count { position: absolute; bottom: 20px; color: rgba(255, 255, 255, .7); font-weight: 600; font-size: 14px; }
.cp-lb.single .cp-lb-nav, .cp-lb.single .cp-lb-count { display: none; }

/* ============================================================
   Окно записи: справа на компьютере, снизу на весь экран на телефоне
   ============================================================ */
.bk-overlay { position: fixed; inset: 0; z-index: 90; }
.bk-overlay[hidden] { display: none; }
.bk-backdrop { position: absolute; inset: 0; background: rgba(15, 11, 35, .45); backdrop-filter: blur(4px); opacity: 0; transition: opacity .28s; }
.bk-sheet { position: absolute; top: 0; right: 0; bottom: 0; width: min(520px, 100vw); background: var(--cp-bg); display: flex; flex-direction: column;
    box-shadow: -30px 0 80px rgba(15, 11, 35, .25); transform: translateX(100%); transition: transform .32s cubic-bezier(.2, .8, .2, 1); }
.bk-overlay.show .bk-backdrop { opacity: 1; }
.bk-overlay.show .bk-sheet { transform: none; }
.bk-sheet-head { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: #fff; border-bottom: 1px solid var(--cp-line); }
.bk-sheet-head img, .bk-sheet-logo { width: 42px; height: 42px; border-radius: 12px; object-fit: cover; flex: none; }
.bk-sheet-logo { display: flex; align-items: center; justify-content: center; font-weight: 700; color: #fff; background: linear-gradient(135deg, var(--cp-accent), var(--cp-accent-2)); }
.bk-sheet-head b { display: block; font-size: 15.5px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bk-sheet-head small { color: var(--cp-muted); font-size: 12.5px; }
.bk-close { width: 40px; height: 40px; border-radius: 12px; border: 0; background: #f2f0f7; color: var(--cp-ink); font-size: 16px; flex: none; }
.bk-close:hover { background: #e9e5f3; }
.bk-sheet-body { flex: 1 1 auto; overflow-y: auto; padding: 16px; -webkit-overflow-scrolling: touch; }
@media (max-width: 575.98px) {
    .bk-sheet { top: auto; left: 0; width: 100%; height: 94vh; border-radius: 22px 22px 0 0; transform: translateY(100%); }
    .bk-sheet-head { border-radius: 22px 22px 0 0; }
}

/* ---------- сам мастер записи (внутри окна и на /book/ID) ---------- */
body.cp .book-card { border: 0; border-radius: 20px; box-shadow: var(--cp-shadow); padding: 18px; background: #fff; }
body.cp .book-steps { display: flex; gap: 4px; list-style: none; padding: 0; margin: 0 0 16px; counter-reset: none; overflow-x: auto; scrollbar-width: none; }
body.cp .book-steps li { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; align-items: center; gap: 5px; font-size: 11px; font-weight: 600; color: #aaa6b8; text-align: center; position: relative; }
body.cp .book-steps li span { width: 28px; height: 28px; border-radius: 50%; background: #f0eef6; color: #8e8aa0; display: flex; align-items: center; justify-content: center; font-size: 12.5px; font-weight: 700; }
body.cp .book-steps li em { font-style: normal; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
body.cp .book-steps li.active { color: var(--cp-ink); }
body.cp .book-steps li.active span { background: linear-gradient(135deg, var(--cp-accent), var(--cp-accent-2)); color: #fff; box-shadow: 0 6px 16px rgba(109, 79, 209, .35); }
body.cp .book-steps li.done span { background: #e7f8ee; color: #16a34a; }
body.cp .book-step h2 { font-size: 20px; margin: 4px 0 14px; }
body.cp .book-item { border-radius: 16px; border: 1px solid var(--cp-line); padding: 13px 14px; transition: border-color .15s, box-shadow .15s, transform .1s; }
body.cp .book-item:hover { border-color: #cfc3f5; box-shadow: 0 6px 18px rgba(109, 79, 209, .1); }
body.cp .book-item b { font-weight: 600; }
body.cp .book-avatar { width: 44px; height: 44px; border-radius: 50%; object-fit: cover; flex: none; display: flex; align-items: center; justify-content: center; color: #fff; font-weight: 700; }
body.cp .book-price { font-weight: 700; white-space: nowrap; }
body.cp .book-price small { font-weight: 500; color: var(--cp-muted); }
body.cp .bk-desc { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
body.cp .book-day { border-radius: 14px; }
body.cp .book-day.active, body.cp .book-time:hover { background: var(--cp-accent); border-color: var(--cp-accent); color: #fff; }
body.cp .book-time { border-radius: 12px; font-weight: 600; }
body.cp .bk-submit { border: 0; border-radius: 16px; background: linear-gradient(135deg, var(--cp-accent), var(--cp-accent-2)); box-shadow: 0 10px 24px rgba(109, 79, 209, .3); font-weight: 700; }
body.cp .book-done-icon { background: linear-gradient(135deg, #22c55e, #16a34a); box-shadow: 0 12px 30px rgba(34, 197, 94, .35); }
.bk-note { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; background: #f3effd; border-radius: 12px; padding: 8px 12px; margin-bottom: 10px; }
.bk-choose { display: grid; gap: 10px; }
.bk-choose-item { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left; border: 1px solid var(--cp-line); background: #fff; border-radius: 18px; padding: 18px; }
.bk-choose-item:hover { border-color: #cfc3f5; box-shadow: 0 8px 22px rgba(109, 79, 209, .12); }
.bk-choose-item .bi { font-size: 24px; color: var(--cp-accent); margin-bottom: 4px; }
.bk-choose-item b { font-size: 16px; }
.bk-choose-item small { color: var(--cp-muted); font-size: 13px; }
.bk-res .bk-res-ico { width: 44px; height: 44px; flex: none; border-radius: 14px; display: flex; align-items: center; justify-content: center; font-size: 20px; color: var(--rc); background: color-mix(in srgb, var(--rc) 14%, #fff); }
.bk-res .bk-res-img { width: 60px; height: 45px; flex: none; border-radius: 10px; object-fit: cover; background: color-mix(in srgb, var(--rc) 14%, #fff); }
.bk-durs { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 8px; }
.bk-dur { border: 1px solid var(--cp-line); background: #fff; border-radius: 14px; padding: 14px 10px; display: flex; flex-direction: column; align-items: center; gap: 2px; }
.bk-dur b { font-size: 16px; }
.bk-dur small { color: var(--cp-muted); font-weight: 600; }
.bk-dur:hover { border-color: var(--cp-accent); background: #f5f1ff; }

/* ---------- /book/ID: та же запись на отдельной странице ---------- */
body.cp-book .book-page { max-width: 640px; }
body.cp-book .book-head { background: #fff; border-radius: 20px; box-shadow: var(--cp-shadow); padding: 16px; border: 0; }

/* Онлайн-бронь ресурса: из чего сложилась цена на стыке тарифов (день / вечер) */
.bk-calc { margin: 2px 0 6px 28px; font-size: 13px; opacity: .8; }
.bk-calc > div { display: flex; justify-content: space-between; gap: 12px; }
.bk-calc b { font-weight: 500; white-space: nowrap; }

/* Бронь ресурса: тарифы по времени суток — строки цен в длительности и цена на кнопке времени */
.bk-dur .bk-dur-line { display: flex; gap: 6px; justify-content: center; font-size: 12.5px; white-space: nowrap; }
.bk-dur .bk-dur-line span { font-weight: 500; opacity: .8; }
.book-time.has-price { display: flex; flex-direction: column; align-items: center; gap: 1px; padding: 6px 0; line-height: 1.2; }
.book-time.has-price small { font-size: 11px; font-weight: 500; opacity: .7; }
