/* ==========================================================================
   Роман Якимчук — видеограф мероприятий. B2B-портфолио.
   Vanilla CSS. Выключка влево. Один холст на всю страницу.
   ========================================================================== */

/* ---------- Onest (дисплей, 700/800) ---------- */
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('assets/fonts/onest-700.woff2') format('woff2');
}
@font-face {
  font-family: 'Onest';
  font-style: normal;
  font-weight: 800;
  font-display: swap;
  src: url('assets/fonts/onest-800.woff2') format('woff2');
}

/* ---------- Manrope (текст, 400/500/600) ---------- */
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/manrope-400-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('assets/fonts/manrope-400-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('assets/fonts/manrope-500-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url('assets/fonts/manrope-500-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('assets/fonts/manrope-600-cyrillic.woff2') format('woff2');
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url('assets/fonts/manrope-600-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* ---------- Design tokens ---------- */
:root{
  --bg:        #0A0A0A;
  --surface:   #131315;
  --surface-2: #1B1B1E;
  --text:      #F5F1EA;
  --muted:     #8E8A82;
  --dim:       #5C584F;
  --line:      rgba(255,255,255,0.08);
  --line-strong: rgba(255,255,255,0.16);
  --accent:    #E8A33D;
  --accent-2:  #F5BE6C;
  --on-accent: #15100A;

  --font-display: 'Onest', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-text: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;

  --container-max: 1280px;
  --container-pad: clamp(20px, 4vw, 48px);

  --section-py: 38px;

  --ease: cubic-bezier(.22,.61,.36,1);
  --dur-fast: 180ms;
  --dur: 320ms;
  --stagger-unit: 30ms;

  color-scheme: dark;
}

@media (min-width: 900px){
  :root{ --section-py: 120px; --stagger-unit: 60ms; }
}

/* ---------- Reset ---------- */
*, *::before, *::after{ box-sizing: border-box; }
html{
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}
html.has-lenis{ scroll-behavior: auto; }
body{
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-text);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
img, video{ max-width: 100%; display: block; }
a{ color: inherit; text-decoration: none; }
button{ font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul, ol{ margin: 0; padding: 0; list-style: none; }
h1,h2,h3,p{ margin: 0; overflow-wrap: break-word; }
input{ font: inherit; color: inherit; }

a, button, input{
  touch-action: manipulation;
  -webkit-tap-highlight-color: rgba(232,163,61,0.18);
}

.container{
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
}

.skip-link{
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--accent);
  color: var(--on-accent);
  padding: 12px 18px;
  z-index: 999;
  border-radius: 0 0 8px 0;
}
.skip-link:focus{ left: 0; }

:focus-visible{
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

/* ---------- Зерно плёнки ---------- */
.grain{
  position: fixed;
  inset: 0;
  z-index: 200;
  pointer-events: none;
  background-image: url('assets/grain.png');
  background-size: 128px 128px;
  mix-blend-mode: overlay;
  opacity: 0.04;
}

/* ---------- Типографическая шкала (раздел 2 ТЗ) ---------- */
.eyebrow{
  font-family: var(--font-text);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: var(--muted);
  margin-bottom: 18px;
}
@media (min-width: 900px){
  .eyebrow{ font-size: 11px; }
}

.hero__name{
  font-family: var(--font-display);
  font-weight: 800;
  font-size: clamp(44px, 7vw, 104px);
  line-height: 0.92;
  letter-spacing: -0.04em;
  margin-bottom: 20px;
  color: transparent;
  -webkit-text-stroke: 1.5px var(--text);
  text-stroke: 1.5px var(--text);
}
@supports not (-webkit-text-stroke: 1px black){
  .hero__name{ color: var(--text); -webkit-text-stroke: 0; }
}

.section__title{
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(38px, 5.6vw, 84px);
  line-height: 0.95;
  letter-spacing: -0.035em;
  margin-bottom: 32px;
  max-width: 16ch;
}

.section__title--process{ max-width: 20ch; }
.section__title--turnaround{ max-width: 22ch; }
.mask-title__line--accent span{ color: var(--accent); }

.work-card__title, .case__title{
  font-family: var(--font-display);
  font-weight: 700;
  font-size: clamp(19px, 1.6vw, 24px);
  letter-spacing: -0.02em;
}

/* ---------- Reveal (появление карточек) ---------- */
/* --reveal-opacity позволяет элементу иметь приглушённое базовое состояние
   (например .hero__lead: opacity .62) без конфликта специфичности с in-view. */
.reveal{ opacity: var(--reveal-opacity, 1); transform: none; }
html.js-anim .reveal{
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 560ms var(--ease), transform 560ms var(--ease);
  transition-delay: calc(var(--stagger, 0) * var(--stagger-unit));
}
html.js-anim .reveal.in-view{ opacity: var(--reveal-opacity, 1); transform: none; }

/* ---------- Маскированное раскрытие заголовков ---------- */
.mask-title{ overflow: visible; }
.mask-title__line{
  display: block;
  overflow: hidden;
}
.mask-title__line > span{ display: block; }
html.js-anim .mask-title__line > span{
  transform: translateY(100%);
  transition: transform 900ms var(--ease);
  transition-delay: calc(var(--mask-stagger, 0) * 140ms);
}
html.js-anim .mask-title.in-view .mask-title__line > span{ transform: translateY(0); }

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior: auto; }
  html.js-anim .reveal,
  html.js-anim .mask-title__line > span{
    opacity: 1; transform: none; transition: none;
  }
  *, *::before, *::after{
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}

/* ---------- Section rhythm ---------- */
.section{ padding-block: var(--section-py); border-top: 1px solid var(--line); position: relative; }
#hero + .section{ border-top: 0; }

/* Декоративные градиентные подложки - CSS-only, без растров, вес 0 */
.section:not(.logos-block)::before{
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at 10% 0%, rgba(232,163,61,0.07), transparent 42%),
    radial-gradient(circle at 90% 100%, rgba(232,163,61,0.05), transparent 38%);
}
.section:not(.logos-block) > .container{ position: relative; z-index: 1; }

/* ---------- Buttons ---------- */
.btn{
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  font-family: var(--font-text);
  font-weight: 700;
  font-size: 0.98rem;
  white-space: nowrap;
  transition: transform var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease);
}
.btn--primary{ background: var(--accent); color: var(--on-accent); }
.btn--primary:hover{ background: var(--accent-2); }
.btn--primary:active{ transform: scale(0.98); }

.btn--ghost{
  background: rgba(255,255,255,0.06);
  color: var(--text);
  border: 1px solid var(--line);
}
.btn--ghost:hover{ border-color: var(--accent); color: var(--accent); }

.btn--sm{ min-height: 42px; padding: 0 18px; font-size: 0.88rem; }
.btn--block{ width: 100%; }

/* "Показать/смотреть ещё" - контурная кнопка с прыгающей стрелкой вниз */
.btn--more{
  background: rgba(255,255,255,0.06);
  color: var(--text);
  border: 1px solid var(--line);
  gap: 10px;
}
.btn--more .btn-more-icon{ animation: btnMoreBounce 1.6s ease-in-out infinite; }
.btn--more:hover{
  border-color: var(--accent);
  color: var(--accent);
  background: rgba(232,163,61,0.08);
}
@keyframes btnMoreBounce{
  0%, 100%{ transform: translateY(0); }
  50%{ transform: translateY(3px); }
}
@media (prefers-reduced-motion: reduce){
  .btn--more .btn-more-icon{ animation: none; }
}

.btn--magnetic.is-settling{ transition: transform 200ms var(--ease); }

/* ---------- Chips (hero facts) ---------- */
.chips{
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 32px;
}
.chip{
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
}

/* ============================================================
   ШАПКА
   ============================================================ */
.site-header{
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background var(--dur) var(--ease), border-color var(--dur) var(--ease), backdrop-filter var(--dur) var(--ease);
}
.site-header.is-scrolled{
  background: rgba(10,10,10,0.82);
  border-bottom-color: var(--line);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}
.site-header__inner{
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
  height: 72px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.site-header__mark{
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  color: var(--text);
}

/* ---------- Якорное меню ---------- */
.anchor-nav{
  position: fixed;
  top: 72px; left: 0; right: 0;
  z-index: 99;
  background: rgba(10,10,10,0.86);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transform: translateY(-100%);
  transition: transform var(--dur) var(--ease);
}
.anchor-nav.is-visible{ transform: translateY(0); }
.anchor-nav__inner{
  max-width: var(--container-max);
  margin-inline: auto;
  padding-inline: var(--container-pad);
  display: flex;
  gap: 22px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: none;
  height: 44px;
  align-items: center;
}
.anchor-nav__inner::-webkit-scrollbar{ display: none; }
.anchor-nav a{
  flex: 0 0 auto;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--muted);
  white-space: nowrap;
  padding: 6px 2px;
  border-bottom: 2px solid transparent;
  transition: color var(--dur-fast) var(--ease), border-color var(--dur-fast) var(--ease);
}
.anchor-nav a:hover{ color: var(--text); }
.anchor-nav a.is-active{ color: var(--accent); border-color: var(--accent); }

.hero, .section{ scroll-margin-top: 116px; }

/* ---------- Таймкод-индикатор скролла ---------- */
.scroll-tc{
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 90;
  font-family: ui-monospace, 'Cascadia Code', 'SFMono-Regular', Consolas, monospace;
  font-size: 11px;
  letter-spacing: 0.02em;
  color: var(--dim);
  background: rgba(10,10,10,0.55);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 6px 12px;
  pointer-events: none;
  opacity: 0;
  transition: opacity var(--dur) var(--ease);
}
.scroll-tc.is-visible{ opacity: 1; }
@media (max-width: 899px){
  .scroll-tc{ display: none; }
}

/* ============================================================
   1. HERO
   ============================================================ */
.hero{
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: hidden;
  padding-top: 100px;
}
.hero__media{
  position: absolute;
  inset: 0;
  z-index: 0;
  background: linear-gradient(160deg, #17140f 0%, #0A0A0A 55%);
}
.hero__video, .hero__poster-img{
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.hero__video{
  opacity: 0;
  transition: opacity 600ms var(--ease);
}
.hero__video.is-ready{ opacity: 1; }
.hero__poster-img{
  transition: opacity 600ms var(--ease);
}
.hero__media.is-playing .hero__poster-img{ opacity: 0; }

.hero__scrim{
  position: absolute;
  inset: 0;
  background: linear-gradient(0deg, #0A0A0A 6%, rgba(10,10,10,0.78) 32%, rgba(10,10,10,0.32) 58%, rgba(10,10,10,0.5) 100%);
  z-index: 1;
}

.hero__content{
  position: relative;
  z-index: 2;
  padding-bottom: 40px;
}
.hero__subtitle{
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text);
  margin-bottom: 6px;
  text-shadow: 0 1px 12px rgba(0,0,0,0.7), 0 1px 2px rgba(0,0,0,0.9);
}
.hero__lead{
  font-size: 0.92rem;
  color: var(--text);
  --reveal-opacity: 0.62;
  max-width: 42ch;
  margin-bottom: 24px;
  text-shadow: 0 1px 12px rgba(0,0,0,0.7), 0 1px 2px rgba(0,0,0,0.9);
}
.hero__ctas{
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero__fineprint{
  margin-top: 20px;
  font-size: 0.78rem;
  color: var(--dim);
  text-align: center;
}

/* ============================================================
   2. СО МНОЙ РАБОТАЮТ (логотипы)
   ============================================================ */
.logos-block{ position: relative; overflow: hidden; }
.logos-block__media{
  position: absolute;
  inset: -4px;
  background: url('assets/cases/case-mtw.webp') center/cover no-repeat;
  filter: blur(3px);
  transform: scale(1.04);
}
.logos-block__media::after{
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(10,10,10,0.78), rgba(10,10,10,0.86));
}
.logos-block .container{ position: relative; z-index: 1; }

.logo-grid{
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 8px;
}
.logo-cell{
  display: flex;
  align-items: center;
  justify-content: center;
  height: 168px;
  border-radius: 12px;
  filter: grayscale(1);
  opacity: 0.55;
  transition: filter 0.35s ease, opacity 0.35s ease, transform 0.35s var(--ease);
}
.logo-cell img{
  /* width/height (не max-) - иначе маленькие исходники (например 28x28 svg
     у Альфа-Банка) не растягиваются до размера ячейки, а остаются нативно
     крошечными. object-fit:contain сохраняет пропорции без искажения. */
  width: 68%;
  height: 68%;
  object-fit: contain;
}
/* Альфа-Банк визуально мельче остальных (компактный квадратный контур) -
   даём отдельный запас, чтобы совпадала оптическая масса. */
.logo-cell img[alt="Альфа-Банк"]{ width: 88%; height: 88%; }
/* Дзен - иконка без текста, сама по себе неузнаваема - подписываем. */
.logo-cell--labeled{ flex-direction: column; gap: 6px; }
.logo-cell--labeled img{ width: 40%; height: 40%; }
.logo-cell__label{
  font-size: 0.8rem;
  letter-spacing: 0.02em;
  color: var(--dim);
}
button.logo-cell{ cursor: pointer; }
.logo-cell--static{ cursor: default; }
.logo-cell:hover,
button.logo-cell:focus-visible{
  filter: grayscale(0);
  opacity: 1;
  transform: scale(1.08);
}

@media (hover: none){
  .logo-cell{ filter: grayscale(0); opacity: 0.9; }
}

@media (min-width: 700px){
  .logo-grid{ grid-template-columns: repeat(7, 1fr); }
}

/* ============================================================
   КАК СО МНОЙ РАБОТАТЬ (переписка в Telegram)
   ============================================================ */
.chat-block .container{ max-width: 620px; }
.chat{
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 24px;
}
.chat__bubble{
  max-width: 82%;
  padding: 12px 16px;
  border-radius: 18px;
  font-size: 15px;
  line-height: 1.45;
}
html.js-anim .chat__bubble{
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 350ms var(--ease), transform 350ms var(--ease);
}
html.js-anim .chat__bubble.is-visible{ opacity: 1; transform: none; }
.chat__bubble--in{
  align-self: flex-start;
  background: var(--surface);
  border-bottom-left-radius: 4px;
}
.chat__bubble--out{
  align-self: flex-end;
  background: rgba(232,163,61,0.16);
  border: 1px solid rgba(232,163,61,0.3);
  border-bottom-right-radius: 4px;
}
.chat__bubble p{ margin: 0 0 4px; }
.chat__time{ display: block; font-size: 11px; color: var(--dim); text-align: right; }
.chat__check{ color: var(--accent); }
.chat__typing{
  align-self: flex-start;
  display: none;
  gap: 4px;
  padding: 12px 16px;
  border-radius: 18px;
  border-bottom-left-radius: 4px;
  background: var(--surface);
}
html.js-anim .chat__typing{
  display: flex;
  opacity: 0;
  transition: opacity 250ms var(--ease);
}
html.js-anim .chat__typing.is-visible{ opacity: 1; }
.chat__typing span{
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--muted);
  animation: chat-dot 1s ease-in-out infinite;
}
.chat__typing span:nth-child(2){ animation-delay: 0.15s; }
.chat__typing span:nth-child(3){ animation-delay: 0.3s; }
@keyframes chat-dot{
  0%, 60%, 100%{ transform: translateY(0); opacity: 0.5; }
  30%{ transform: translateY(-3px); opacity: 1; }
}
.chat__note{ color: var(--dim); font-size: 0.85rem; margin-top: 14px; }

.chat__flow{
  margin-top: 20px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
@media (max-width: 899px){
  .chat__flow-text{ margin-bottom: 6px; }
}
.chat__flow-lead{
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 1rem + 0.9vw, 1.45rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  margin-bottom: 14px;
}
.chat__flow-text{ color: var(--muted); font-size: 0.95rem; line-height: 1.55; margin-bottom: 8px; }
.chat__flow-text:last-child{ margin-bottom: 0; }

@media (prefers-reduced-motion: reduce){
  .chat__bubble{ opacity: 1; transform: none; transition: none; }
  .chat__typing span{ animation: none; }
}

@media (min-width: 900px){
  .hero{ padding-top: 0; }
  .hero__content{ padding-bottom: 64px; }
}

/* ============================================================
   3. ЧТО СНИМАЮ
   ============================================================ */
.filters{
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  gap: 10px;
  margin-top: 24px;
  margin-bottom: 28px;
  padding-bottom: 4px;
  scrollbar-width: none;
}
.filters[hidden]{ display: none; }
.filters::-webkit-scrollbar{ display: none; }
.pill{
  flex: 0 0 auto;
  padding: 10px 16px;
  border-radius: 999px;
  border: 1px solid var(--line);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.85rem;
  min-height: 42px;
  white-space: nowrap;
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}
.pill:hover{ color: var(--text); }
.pill.is-active{ border-color: var(--accent); color: var(--accent); background: rgba(232,163,61,0.1); }
.pill[hidden]{ display: none; }

.works-grid{
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px 12px;
  transition: opacity 200ms var(--ease);
}
.works-grid[hidden]{ display: none; }
.work-card{
  position: relative;
}
.work-card__media{
  position: relative;
  aspect-ratio: 4/3;
  border-radius: 14px;
  overflow: hidden;
  background: var(--surface);
}
@media (max-width: 899px){
  .work-card__title{ font-size: 0.85rem; margin-top: 8px; }
  .work-card__category{ font-size: 9px; padding: 4px 8px; top: 8px; left: 8px; }
}
.work-card__media img, .work-card__media video{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 500ms var(--ease);
}
.work-card:hover .work-card__media img,
.work-card:hover .work-card__media video{ transform: scale(1.03); }
.work-card__category{
  position: absolute;
  top: 14px; left: 14px;
  z-index: 2;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 700;
  color: var(--bg);
  background: var(--accent);
  padding: 5px 10px;
  border-radius: 999px;
}
.work-card__title{ margin-top: 14px; color: var(--muted); }
.work-card__title span:first-child{ color: var(--text); }

.work-card__play{
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%) scale(0.85);
  z-index: 3;
  width: 52px; height: 52px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  background: rgba(10,10,10,0.55);
  border: 1px solid rgba(255,255,255,0.25);
  color: var(--text);
  opacity: 0;
  transition: opacity 250ms var(--ease), transform 250ms var(--ease);
  cursor: pointer;
}
.work-card__media{ cursor: pointer; }
.work-card:hover .work-card__play{ opacity: 1; transform: translate(-50%,-50%) scale(1); }

.works__empty{
  color: var(--muted);
  padding: 32px 0;
  border-top: 1px dashed var(--line);
}

/* Заглушка "Скоро" - для карточек без материала (см. п.3 в ТЗ) */
.work-card--placeholder .work-card__media{
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--surface), var(--surface-2));
  border: 1px dashed var(--line-strong);
  cursor: default;
}
.work-card__soon{
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

/* Переключение раздела: старые карточки уходят вниз с затуханием,
   новые приходят снизу вверх (см. п.12 ТЗ). Управляется через JS. */
.work-card.is-switch-out{
  transition: opacity 200ms ease, transform 200ms ease;
  opacity: 0;
  transform: translateY(14px);
}
.work-card.is-switch-in{
  opacity: 0;
  transform: translateY(18px);
}
.work-card.is-switch-in.is-switch-shown{
  transition: opacity 300ms ease, transform 300ms ease;
  opacity: 1;
  transform: none;
}

@media (min-width: 900px){
  .works-grid{ grid-template-columns: repeat(3, 1fr); }
}

/* ============================================================
   4. КЕЙСЫ
   ============================================================ */
.cases-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.case{
  transition: transform var(--dur-fast) var(--ease);
}
.case:hover{ transform: translateY(-4px); }
.case__media{
  position: relative;
  aspect-ratio: 16/9;
  border-radius: 16px;
  overflow: hidden;
  margin-bottom: 12px;
  background: var(--surface);
}
@media (max-width: 899px){
  .case__media{ aspect-ratio: 2/1; }
  .case__quote{
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-bottom: 10px;
  }
  .case__title{ margin-bottom: 6px; }
}
.case__media img{
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform 500ms var(--ease);
}
.case:hover .case__media img{ transform: scale(1.03); }
.case__title{ margin-bottom: 10px; display: flex; flex-direction: column; gap: 2px; }
.case__title-sub{ color: var(--dim); font-size: 0.8rem; font-weight: 500; text-transform: uppercase; letter-spacing: 0.06em; }
.case__quote{ color: var(--muted); font-size: 0.92rem; line-height: 1.55; margin-bottom: 14px; }
.case__price{
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--accent);
  margin-bottom: 10px;
}
.case__tags{ display: flex; flex-wrap: wrap; gap: 8px; }
.case__tags span{
  font-size: 0.78rem;
  color: var(--accent);
  border: 1px solid rgba(232,163,61,0.35);
  border-radius: 999px;
  padding: 4px 10px;
}

@media (max-width: 899px){
  .cases-grid{ gap: 10px; }
  .case__title{ font-size: 17px; }
  .case__tags{ gap: 6px; }
  .case__tags span{ padding: 3px 8px; font-size: 0.74rem; }
}

@media (min-width: 900px){
  .cases-grid{ grid-template-columns: repeat(3, 1fr); gap: 24px; }
}

/* ============================================================
   5. СРОКИ
   ============================================================ */
.turnaround__note{
  color: var(--dim);
  font-size: 0.85rem;
  margin-bottom: 28px;
  margin-top: -12px;
}
.turnaround__body{ max-width: 640px; }
.turnaround__lead{
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 1.1rem + 1.8vw, 2.2rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 20px;
}
.turnaround__text{
  font-size: 1.05rem;
  line-height: 1.6;
  color: var(--muted);
  margin-bottom: 14px;
}
.turnaround__text--accent{
  color: var(--accent);
  font-weight: 700;
  margin-bottom: 0;
}
@media (max-width: 899px){
  .turnaround__lead{ margin-bottom: 14px; }
  .turnaround__text{ margin-bottom: 10px; }
}

/* ============================================================
   6. ПРОЦЕСС
   ============================================================ */
.process__grid{ display: grid; gap: 40px; }
.steps{ display: grid; gap: 20px; }
.step{
  display: flex;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
}
.step:first-child{ border-top: 0; padding-top: 0; }
.step__num{
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 0.95rem;
  color: var(--accent);
  flex: 0 0 auto;
}
.step__body{ display: flex; flex-direction: column; gap: 4px; }
.step__title{ font-weight: 700; font-size: 1.05rem; }
.step__desc{ color: var(--muted); font-size: 0.92rem; }

.deliverables{
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
}
.deliverables__title{ font-weight: 700; margin-bottom: 16px; font-family: var(--font-display); }
.deliverables__list li{
  position: relative;
  padding-left: 20px;
  margin-bottom: 12px;
  color: var(--muted);
}
.deliverables__list li::before{
  content: "";
  position: absolute; left: 0; top: 10px;
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--accent);
}
.deliverables__list li:last-child{ margin-bottom: 0; }
.deliverables__list-accent{ color: var(--accent) !important; font-weight: 600; }

@media (min-width: 900px){
  .process__grid{ grid-template-columns: 1.2fr 1fr; }
}
@media (max-width: 899px){
  .process__grid{ gap: 24px; }
  .steps{ gap: 14px; }
  .step{ padding-top: 14px; }
  .deliverables{ padding: 18px; }
  .deliverables__list li{ margin-bottom: 8px; }
}

/* ============================================================
   7. ОБО МНЕ
   ============================================================ */
.about__grid{ display: grid; gap: 32px; }
.about__media{
  border-radius: 20px;
  overflow: hidden;
  aspect-ratio: 3/2;
}
.about__media img{ width: 100%; height: 100%; object-fit: cover; }

.stat-row{
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 24px;
}
.stat-counter{ display: flex; flex-direction: column; }
.stat-counter__num, .stat-counter__plus{
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 4vw, 3.2rem);
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  display: inline;
}
.stat-counter__label{ color: var(--muted); font-size: 0.85rem; margin-top: 6px; max-width: 16ch; }

.about__text{ color: var(--muted); margin-bottom: 14px; max-width: 52ch; line-height: 1.55; }
.about__text--lead{ color: var(--text); font-weight: 600; font-size: 1.08rem; }

.risks{
  margin-top: 24px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.risks__item{
  padding-top: 14px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 3px;
}
.risks__title{ font-weight: 700; }
.risks__desc{ color: var(--muted); font-size: 0.88rem; }

@media (min-width: 900px){
  .about__grid{ grid-template-columns: 0.9fr 1.1fr; align-items: start; }
  .risks{ grid-template-columns: 1fr 1fr; }
}
@media (max-width: 899px){
  .about__media{ aspect-ratio: 16/10; }
  .stat-row{ gap: 20px; margin-bottom: 14px; }
  .about__text{ margin-bottom: 8px; }
  .about__text--lead{ font-size: 1rem; }
  .risks{ margin-top: 14px; gap: 8px; }
  .risks__item{ padding-top: 8px; }
}

/* ============================================================
   8. ДЛЯ АГЕНТСТВ
   ============================================================ */
.agencies__list{
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}
.agencies__list li{
  padding-top: 14px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.agencies__list li:first-child{ border-top: 0; padding-top: 0; }
.agencies__title{ font-weight: 700; font-family: var(--font-display); font-size: 1.05rem; }
.agencies__desc{ color: var(--muted); font-size: 0.92rem; }

@media (min-width: 900px){
  .agencies__list{ grid-template-columns: repeat(2, 1fr); gap: 28px 40px; }
  .agencies__list li{ border-top: 0; padding-top: 0; }
  .agencies__list li::before{
    content: "";
    display: block;
    width: 28px; height: 2px;
    background: var(--accent);
    margin-bottom: 4px;
  }
}

/* ============================================================
   FAQ
   ============================================================ */
.faq-list{ display: flex; flex-direction: column; }
.faq-item{
  border-top: 1px solid var(--line);
  padding: 16px 0;
}
.faq-list .faq-item:last-child{ border-bottom: 1px solid var(--line); }
.faq-item summary{
  cursor: pointer;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.02rem;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.faq-item summary::-webkit-details-marker{ display: none; }
.faq-item summary::after{
  content: "+";
  flex: 0 0 auto;
  font-size: 1.3rem;
  color: var(--accent);
  transition: transform var(--dur-fast) var(--ease);
}
.faq-item[open] summary::after{ transform: rotate(45deg); }
.faq-item p{ color: var(--muted); font-size: 0.95rem; line-height: 1.55; margin-top: 12px; max-width: 62ch; }

/* ============================================================
   КОНТАКТЫ - компактная строка цен
   ============================================================ */
.contact__pricing{
  display: flex;
  flex-wrap: wrap;
  gap: 10px 20px;
  margin-bottom: 10px;
  scroll-margin-top: 116px;
}
.contact__pricing span{
  font-size: 0.92rem;
  color: var(--muted);
}
.contact__pricing span b{ color: var(--text); font-weight: 700; }
.contact__pricing-note{ color: var(--dim); font-size: 0.82rem; margin-bottom: 32px; }

/* ============================================================
   "Смотреть ещё" (Работы / Кейсы)
   ============================================================ */
.grid-more-wrap{
  display: flex;
  justify-content: center;
  margin-top: 28px;
}
.grid-more-wrap[hidden]{ display: none; }

/* ============================================================
   9. ОТЗЫВЫ
   ============================================================ */
.reviews-grid{
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}
.review{
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
}
.review[hidden]{ display: none; }
.review__top{ display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.stars{ color: var(--accent); letter-spacing: 2px; font-size: 0.9rem; }
.review__sum{ font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; }
.review__text{ color: var(--muted); font-size: 0.92rem; line-height: 1.5; flex: 1; margin-bottom: 12px; }
@media (max-width: 899px){
  .review__text{
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .review{ padding: 14px; }
  .review__top{ margin-bottom: 8px; }
  .review__text{ margin-bottom: 8px; }
}
.review__meta{ display: flex; flex-direction: column; gap: 2px; }
.review__name{ font-weight: 700; }
.review__cat{ color: var(--dim); font-size: 0.8rem; }
.review__source{
  margin-top: 12px;
  font-size: 0.78rem;
  color: var(--dim);
  text-decoration: underline;
  text-underline-offset: 3px;
  align-self: flex-start;
}
.review__source:hover{ color: var(--accent); }
.reviews__footnote{ margin-top: 24px; color: var(--dim); font-size: 0.8rem; }

@media (min-width: 700px){
  .reviews-grid{ grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1100px){
  .reviews-grid{ grid-template-columns: repeat(3, 1fr); }
}

/* ============================================================
   10. КОНТАКТЫ
   ============================================================ */
.contact__lead{ color: var(--muted); max-width: 56ch; margin-bottom: 24px; }
.contact__grid{ display: grid; gap: 24px; }
@media (max-width: 899px){
  .contact-row{ padding: 14px 4px; }
  .contact-form{ padding: 16px; gap: 10px; }
  .field{ gap: 5px; }
  .field input{ height: 46px; }
  .contact__pricing-note{ margin-bottom: 20px; }
}
.contact__links{ display: flex; flex-direction: column; }
.contact-row{
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 4px;
  border-top: 1px solid var(--line);
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 2.4vw, 1.8rem);
  font-weight: 700;
  transition: color var(--dur-fast) var(--ease), padding-left var(--dur-fast) var(--ease);
}
.contact__links a:last-child{ border-bottom: 1px solid var(--line); }
.contact-row:hover{ color: var(--accent); padding-left: 10px; }
.contact-row--accent{ color: var(--accent); }
.contact-row__arrow{ transition: transform var(--dur-fast) var(--ease); }
.contact-row:hover .contact-row__arrow{ transform: translateX(4px); }

.contact-form{
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--surface);
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.field{ display: flex; flex-direction: column; gap: 7px; }
.field label{ font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.field input{
  height: 50px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--line-strong);
  background: var(--surface-2);
  color: var(--text);
}
.field input::placeholder{ color: var(--dim); }
.field input:focus{ border-color: var(--accent); outline: none; }
.contact-form__note{ font-size: 0.78rem; color: var(--dim); text-align: center; }

@media (min-width: 900px){
  .contact__grid{ grid-template-columns: 1fr 1.1fr; gap: 48px; }
}

/* ============================================================
   FOOTER
   ============================================================ */
.footer{ padding-block: 40px; border-top: 1px solid var(--line); }
.footer__inner{ display: flex; flex-direction: column; gap: 6px; }
.footer p{ color: var(--dim); font-size: 0.82rem; }

/* ============================================================
   ЛИПКАЯ МОБИЛЬНАЯ КНОПКА
   ============================================================ */
.sticky-cta{
  position: fixed;
  left: 12px; right: 12px;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  z-index: 90;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--on-accent);
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  transform: translateY(140%);
  transition: transform 320ms var(--ease);
}
.sticky-cta.is-visible{ transform: translateY(0); }
.sticky-cta.is-hidden-by-popup{ transform: translateY(140%); }

@media (min-width: 900px){
  .sticky-cta{ display: none; }
}

/* ============================================================
   ВСПЛЫВАЮЩАЯ ПАНЕЛЬ (не модалка)
   ============================================================ */
.popup{
  position: fixed;
  left: 12px; right: 12px;
  bottom: calc(12px + env(safe-area-inset-bottom, 0px));
  z-index: 95;
  padding: 14px 44px 14px 16px;
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  border-radius: 16px;
  box-shadow: 0 10px 30px rgba(0,0,0,0.45);
  transform: translateY(140%);
  transition: transform 500ms var(--ease);
}
.popup.is-visible{ transform: translateY(0); }
.popup__close{
  position: absolute;
  top: 50%; right: 8px;
  transform: translateY(-50%);
  width: 28px; height: 28px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 50%;
  color: var(--dim);
}
.popup__close:hover{ color: var(--text); background: rgba(255,255,255,0.06); }
.popup__cta{ min-height: 46px; }

@media (min-width: 700px){
  .popup{
    left: auto; right: 24px; bottom: 24px;
    max-width: 320px;
    padding: 16px 44px 16px 16px;
    border-radius: 999px;
  }
}

/* ============================================================
   VK ВИДЕО МОДАЛКА
   ============================================================ */
.video-modal{
  position: fixed;
  inset: 0;
  z-index: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.video-modal[hidden]{
  display: none;
}
.video-modal__backdrop{
  position: absolute; inset: 0;
  background: rgba(6,6,7,0.92);
}
.video-modal__frame{
  position: relative;
  width: 100%;
  max-width: 1100px;
  aspect-ratio: 16/9;
  z-index: 1;
}
.video-modal__body{ width: 100%; height: 100%; display: flex; flex-direction: column; }
.video-modal__body iframe{ width: 100%; height: 100%; border: 0; border-radius: 12px; }
.video-modal__body video{ display: block; }

/* Переключатель роликов (несколько видео на один логотип, например Альфа-Банк) */
.video-modal__switcher{
  flex: 0 0 auto;
  display: flex;
  gap: 8px;
  margin-bottom: 10px;
}
.video-modal__switch-btn{
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  color: var(--muted);
  font-weight: 600;
  font-size: 0.85rem;
  background: rgba(255,255,255,0.04);
  transition: border-color var(--dur-fast) var(--ease), color var(--dur-fast) var(--ease), background var(--dur-fast) var(--ease);
}
.video-modal__switch-btn:hover{ color: var(--text); }
.video-modal__switch-btn.is-active{ border-color: var(--accent); color: var(--accent); background: rgba(232,163,61,0.12); }
.video-modal__video-wrap{ flex: 1 1 auto; min-height: 0; }
.video-modal__video-wrap video{ width: 100%; height: 100%; }
.video-modal__close{
  position: absolute;
  top: -44px; right: 0;
  width: 36px; height: 36px;
  display: flex; align-items: center; justify-content: center;
  color: var(--text);
  border-radius: 50%;
}
.video-modal__close:hover{ background: rgba(255,255,255,0.08); }
.video-modal__fallback{
  position: absolute;
  left: 50%; bottom: -64px;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: 12px;
  white-space: nowrap;
  color: var(--muted);
  font-size: 0.85rem;
}
