/* Витрина 3.0 — 19.10.2026: плитки работ в первом экране, группы кейсов по задаче
   заказчика, метки карточек, три телефона веером, призыв после группы.
   Основания — bagnin-studio/docs/2026-10-19_vitrina-3-issledovanie.md. PO 19.10:
   «баннер йога… а ниже Работы — нелогично», «чтобы цепляюще было, витрина структурирована». */

/* Первый экран: плитки работ вместо снимка одного кейса. У каждой плитки свой экран —
   не тот, что в карточке ниже. На телефоне — лента: видно две с половиной плитки,
   край следующей подсказывает, что дальше есть еще. */
.hero-works { min-width: 0; }
.tiles-label { margin: 28px 0 10px; font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); }
.tiles { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; overscroll-behavior-x: contain;
  margin: 0 -20px; padding: 2px 20px 12px; scroll-padding-inline: 20px; scrollbar-width: none; }
/* scroll-padding = отступ: привязка прокрутки не сдвигает первую плитку к краю экрана после загрузки картинок (10.11) */
.tiles::-webkit-scrollbar { display: none; }
.tile { flex: 0 0 38%; max-width: 170px; scroll-snap-align: start; display: block; color: inherit; text-decoration: none; }
.tile picture, .tile img { display: block; width: 100%; }
.tile img { aspect-ratio: 4 / 5; object-fit: cover; object-position: top; border-radius: 16px; border: 1px solid var(--line);
  background: var(--surface-2); box-shadow: 0 16px 30px -24px rgba(0,0,0,.6); transition: transform .2s, border-color .2s; }
.tile:hover img { transform: translateY(-2px); border-color: var(--accent-line); }
.tile-cap { display: block; margin-top: 8px; line-height: 1.3; }
.tile-cap b { display: block; color: var(--ink); font-size: 14.5px; font-weight: 650; }
.tile-cap span { display: block; color: var(--muted); font-size: 13px; }
@media (min-width: 768px) { .tiles { margin: 0 -32px; padding: 2px 32px 12px; } .tile { flex-basis: 22%; } }
@media (min-width: 960px) {
  .tiles-label { margin-top: 0; }
  .tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 16px; overflow: visible; margin: 0; padding: 0; }
  .tile { max-width: none; }
}

/* Группы кейсов: заголовок — задача заказчика, справа — услуга, цена и срок */
.group + .group { margin-top: 64px; }
.group-head { display: grid; gap: 6px; margin: 0 0 20px; padding-top: 20px; border-top: 2px solid var(--line); }
@media (min-width: 900px) { .group-head { grid-template-columns: 1fr auto; align-items: baseline; gap: 24px; } }
.group-head h3 { font-size: clamp(1.35rem, 3vw, 1.75rem); line-height: 1.15; font-weight: 800; }
.group-head p { margin: 0; color: var(--muted); font-size: 15px; }
.group-head p span { color: var(--ink); font-weight: 650; white-space: nowrap; }
.cases + .cases { margin-top: 28px; }

/* Карточка: метки, заголовок-результат */
.case h4 { font-size: clamp(1.3rem, 2.5vw, 1.6rem); line-height: 1.2; margin: 0 0 10px; color: var(--ink); letter-spacing: -.02em; }
.case h4 a { color: inherit; text-decoration: none; }
.case h4 a:hover { color: var(--accent-text); }
.tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 0 0 12px; }
.tags .chip { margin: 0; }
.status { font-size: 13px; color: var(--muted); }
.new { display: inline-block; font-size: 12px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: #fff;
  background: var(--accent); border-radius: 999px; padding: 3px 10px; }
.case.featured { border: 2px solid var(--accent-line); }
@media (min-width: 960px) { .case.featured h4 { font-size: 1.85rem; } }

/* Две компактные карточки в ряд: снимок сверху, текст под ним */
@media (min-width: 960px) {
  .cases.duo { grid-template-columns: 1fr 1fr; gap: 24px; }
  .cases.duo .case { grid-template-columns: 1fr; align-items: start; gap: 22px; padding: 24px; }
  .cases.duo .case .stage { order: 0; }
  .cases.duo .case h4 { font-size: 1.35rem; }
}

/* На телефоне снимок компьютера сжимается в четыре раза — телефон поверх крупнее,
   почти в половину карточки: момент пользы читается, от компьютера остается фрагмент */
@media (max-width: 959.98px) {
  .stage:not(.trio) { padding-top: 40px; }   /* телефон выше снимка — без отступа он заходил на рамку карточки */
  .stage:not(.trio) .phone { width: 44%; max-width: 190px; }
}

/* Три телефона веером: у мини-приложения нет версии для компьютера, поэтому — три разных
   экрана, светлый и темные (PO 19.10: «все три экрана одинаковые… хотя бы одну мобильную
   сделать темной»). */
.stage.trio { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: end; padding: 18px 6px 24px; }
.stage.trio .phone { position: relative; right: auto; bottom: auto; width: auto; max-width: 210px; justify-self: center; }
.stage.trio .phone:nth-child(1) { transform: translateX(14%) rotate(-5deg); z-index: 1; }
.stage.trio .phone:nth-child(2) { transform: translateY(-14px) scale(1.08); z-index: 2; }
.stage.trio .phone:nth-child(3) { transform: translateX(-14%) rotate(5deg); z-index: 1; }

/* Призыв после группы: готовый текст про этот вид работы */
.group-cta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 12px; margin: 22px 0 0; padding: 16px 18px;
  background: var(--surface); border: 1px solid var(--accent-line); border-radius: 18px; }
.group-cta p { flex: 1 1 100%; margin: 0 0 2px; color: var(--ink); font-weight: 650; }
.group-cta .btn { min-height: 46px; padding: 0 18px; font-size: 15px; flex: 1 1 140px; }
@media (min-width: 640px) {
  .group-cta p { flex: 1 1 auto; margin: 0; }
  .group-cta .btn { flex: 0 0 auto; }
}

/* Живая ссылка — строкой рядом с «Разбором»: два действия в один ряд на телефоне */
.live-link { font-weight: 600; font-size: 15.5px; text-decoration: none; padding: 10px 4px; }
.live-link:hover { text-decoration: underline; }
.note.quote { color: var(--text); }

/* Услуги одним прайсом: три главные строки — крупнее и с акцентом цены */
.svc-row.main b { font-size: 1.08rem; }
.svc-row.main .p { color: var(--accent-text); font-size: 1.08rem; }
.svc-row.main small { color: var(--text); }

/* Проверка свежими глазами 19.10: на телефоне лента плиток читалась повтором карточек ниже —
   ровно то, на что жаловался PO. Плитки — только на широком экране, справа от текста;
   на телефоне после кнопок — одна строка о свежей работе. */
.hero-works { display: none; }
@media (min-width: 960px) { .hero-works { display: block; } }
.news { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin: 16px 0 0; font-size: 15px; }
.news a { font-weight: 600; }

/* Прайс на телефоне — в столбик: «цена после разговора» сжимала название в узкую колонку */
@media (max-width: 559.98px) {
  .svc-more .svc-row { grid-template-columns: 1fr; }
  .svc-more .svc-row .p { text-align: left; }
}

/* Шапка на 320 px: имя упиралось в значок темы */
@media (max-width: 349.98px) {
  .brand { font-size: 15px; gap: 8px; }
  .brand img { width: 30px; height: 30px; }
  .head-actions { gap: 0; }
}

/* «Работы и опыт» — страницу собирает bagnin-studio/tools/works.py из реестра работ data/works.yml
   (22.10.2026). PO: «людям текст неинтересно читать… информативно, красиво, вместе с картинками,
   структурировано». 4.1 (своя приемка после выкладки 4.0): работы — карточками главной со снимками,
   плитки — справа в первом экране на компьютере, опыт и практики — заголовками, текст под «+». */
.pf-stats { list-style: none; display: flex; flex-wrap: wrap; gap: 10px 30px; padding: 0; margin: 6px 0 26px; }
.pf-stats li { display: grid; }
.pf-stats b { font-size: clamp(1.6rem, 4vw, 2.2rem); line-height: 1.1; font-weight: 800; color: var(--accent-text); }
.pf-stats span { color: var(--muted); font-size: 14px; }
/* На телефоне цифры — одной строкой: столбиком они занимали полэкрана, и снимки работ уходили на второй */
@media (max-width: 559.98px) {
  .pf-stats { display: grid; grid-template-columns: repeat(3, minmax(0, auto)); justify-content: start; gap: 4px 20px; margin-bottom: 20px; }
  .pf-stats b { font-size: 1.55rem; }
  .pf-stats span { font-size: 13px; line-height: 1.3; }
  /* кнопки — одной строкой: «Написать» со значком Телеграма, как в нижней панели; раздел работ — ближе */
  .pf-hero .cta-row { flex-wrap: nowrap; gap: 10px; }
  .pf-hero .cta-row .btn { flex: 1 1 0; min-width: 0; padding: 0 12px; }
  .pf-hero .cta-row .long { display: none; }
  .pf-hero + .section { padding-top: 40px; }
}
.pf-list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
@media (min-width: 760px) { .pf-list { grid-template-columns: 1fr 1fr; } }
.pf-list li { background: var(--surface); border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; display: grid; gap: 4px; }
.pf-list b { color: var(--ink); }
.pf-list span { font-size: 15px; }
.pf-list .pf-where { color: var(--muted); font-size: 14px; }
.pf-list details summary { list-style: none; cursor: pointer; display: grid; gap: 4px; padding-right: 30px; position: relative; }
.pf-list details summary::-webkit-details-marker { display: none; }
.pf-list details summary::after { content: "+"; position: absolute; right: 0; top: -3px; font-size: 24px; line-height: 1;
  font-weight: 500; color: var(--accent-text); }
.pf-list details[open] summary::after { content: "−"; }
.pf-list details p { margin: 10px 0 0; font-size: 15px; color: var(--text); }
.pf-timeline li { border-left: 3px solid var(--accent-line); }
.pf-terms { margin: 16px 0 0; padding-left: 1.1em; display: grid; gap: 6px; }
.pf-skills { display: grid; gap: 16px; }
@media (min-width: 760px) { .pf-skills { grid-template-columns: 1fr 1fr; } }
.pf-skill h3 { font-size: 1rem; margin: 0 0 8px; }
.pf-skill p { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; }
.pf-skill .chip { margin: 0; }
/* Работа без снимка — строкой под карточками группы, без буквы-заглушки */
.pf-more { list-style: none; padding: 0; margin: 14px 0 0; display: grid; gap: 8px; }
.pf-more li { display: grid; gap: 3px; padding: 12px 16px; border: 1px dashed var(--line); border-radius: 14px; }
.pf-more b { color: var(--ink); }
.pf-more span { font-size: 14.5px; }
.pf-more .pf-note { color: var(--muted); }

/* «Монтаж и контент» (10.11.2026): на главной — полоска свежих примеров и ссылка на детали (PO: «не слишком
   нагромождая»), страница /kontent/ — результаты в первом экране, кейсы новые первыми, цены с рыночными. */
.kt-strip-main .tile, .kt-strip .kt-tile { position: relative; }
.kt-strip-main .tile img { aspect-ratio: 9 / 16; object-position: center; }   /* кадр 1:2 с полями — поля срезаются поровну */
@media (min-width: 960px) { .kt-strip-main { grid-template-columns: repeat(6, minmax(0, 1fr)); } }
/* значок ролика — в углу, как у Reels: надпись-крючок обложки остается открытой (10.11, плитка Jeeptour) */
.kt-play { position: absolute; right: 10px; top: 10px; width: 34px; height: 34px; border-radius: 50%;
  background: rgba(12, 10, 9, .58); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  box-shadow: 0 4px 12px -4px rgba(0, 0, 0, .55); pointer-events: none; }
.kt-play::after { content: ""; position: absolute; left: 13px; top: 10px; border-style: solid; border-width: 7px 0 7px 11px;
  border-color: transparent transparent transparent #fff; }
@media (max-width: 959px) { .kt-strip .kt-play { right: 6px; top: 6px; width: 22px; height: 22px; }
  .kt-strip .kt-play::after { left: 8px; top: 6px; border-width: 5px 0 5px 8px; } }
.kt-more { margin: 14px 0 0; font-weight: 600; }
.kt-acc { color: var(--accent-text); }
.kt-nw { white-space: nowrap; }   /* «а за минуты» не рвется переносом */
.kt-strip { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; margin-top: 8px; }
@media (min-width: 960px) { .kt-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; max-width: 420px; justify-self: end; } }
.kt-tile { display: block; color: inherit; text-decoration: none; }
.kt-tile img { display: block; width: 100%; height: auto; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 14px;
  border: 1px solid var(--line); background: var(--surface-2); box-shadow: 0 16px 30px -24px rgba(0, 0, 0, .6); }
.kt-cap { position: absolute; left: 6px; bottom: 6px; padding: 3px 8px; border-radius: 999px; font-size: 12px; font-weight: 650;
  background: rgba(12, 10, 9, .72); color: #fafaf9; white-space: nowrap; max-width: calc(100% - 12px); overflow: hidden;
  text-overflow: ellipsis; }
@media (max-width: 559.98px) { .kt-cap { font-size: 11px; padding: 2px 6px; } }
.kt-cases { display: grid; gap: 18px; }
@media (min-width: 760px) { .kt-cases { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1100px) { .kt-cases { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
.kt-case { display: grid; align-content: start; gap: 14px; padding: 14px; background: var(--surface); border: 1px solid var(--line);
  border-radius: 20px; scroll-margin-top: 84px; }
.kt-media { border-radius: 14px; overflow: hidden; background: #0c0a09; }
/* рамка ролика всегда 9:16: обложка 1:2 теряет только размытые поля, сам ролик не режется (10.11) */
.kt-video { display: block; width: 100%; max-width: 360px; margin: 0 auto; aspect-ratio: 9 / 16; object-fit: cover; background: #0c0a09; }
.kt-gal { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding: 8px; }
.kt-gal::-webkit-scrollbar { display: none; }
.kt-gal a { flex: 0 0 72%; scroll-snap-align: center; }
.kt-gal img, .kt-wide img { display: block; width: 100%; height: auto; border-radius: 10px; }
.kt-gal img { aspect-ratio: var(--r, 9 / 16); object-fit: cover; }   /* --r у кейса: карусель 4 / 5 */
.kt-body h3 { font-size: 1.12rem; line-height: 1.25; margin: 0; }
.kt-meta { margin: 0; font-size: 15px; color: var(--muted); }
.kt-meta strong { color: var(--ink); }
.kt-meta s, .kt-prices s { color: var(--muted); margin-left: 4px; font-weight: 400; }
.kt-meta s, .kt-meta strong, .kt-prices s, .kt-prices strong { white-space: nowrap; }
.kt-body .done { margin: 0; }
.kt-prices { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.kt-prices li { display: grid; gap: 4px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.kt-prices b { color: var(--ink); }
.kt-prices .kt-t, .kt-prices .kt-p { font-size: 15px; color: var(--muted); }
.kt-prices strong { color: var(--ink); }
@media (min-width: 760px) { .kt-prices li { grid-template-columns: minmax(0, 1fr) 210px 230px; align-items: baseline; } }
.kt-src { margin: 14px 0 0; font-size: 14px; color: var(--muted); }
.kt-steps { list-style: none; counter-reset: s; padding: 0; margin: 0; display: grid; gap: 10px; }
@media (min-width: 760px) { .kt-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.kt-steps li { counter-increment: s; position: relative; display: grid; gap: 4px; padding: 14px 16px 14px 56px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 14px; }
.kt-steps li::before { content: counter(s); position: absolute; left: 16px; top: 14px; width: 28px; height: 28px; border-radius: 50%;
  background: var(--accent); color: #fff; display: grid; place-items: center; font-weight: 700; font-size: 14px; }
.kt-steps b { color: var(--ink); }
.kt-steps span { font-size: 15px; }
.kt-why { margin: 18px 0 0; max-width: 46em; }
