/* Страница кейса. Цвета бренда приходят из --a1, --a2, --a3 (заливки) и --t1..--t3 (тот же цвет, затемнённый для текста). */
.mak-case { --text: var(--ink); --text-dim: var(--ink-2); --text-faint: var(--ink-3); padding-bottom: 40px; }
.mak-case .wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 var(--gutter); }
.mak-case h1, .mak-case h2, .mak-case h3 { font-family: var(--display); letter-spacing: -0.02em; font-weight: 600; margin: 0; }
.mak-case a { text-decoration: none; }
.mak-case .glass { background: #fff; border: 1px solid var(--line); }
.mak-case .nav-outer, .mak-case .nav { display: none; }

.mak-case .hero { padding: 128px 0 40px !important; height: auto; min-height: 0; max-height: none; overflow: visible; background: none; }
.mak-case .hero-grid { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.mak-case .eyebrow { font-size: 15px; color: var(--ink-2); margin-bottom: 18px; }
.mak-case .hero h1 { font-size: clamp(32px, 4.4vw, 58px); line-height: 1.06; letter-spacing: -0.035em; max-width: none; }
.mak-case .hero h1 em { font-style: normal; color: var(--t1); }
.mak-case .hero h1 a { text-decoration: underline; text-decoration-thickness: 2px; text-underline-offset: 8px; text-decoration-color: var(--a1); }
.mak-case .hero h1 a:hover { text-decoration-color: var(--ink); }
.mak-case .lead { margin-top: 22px; font-size: 19px; color: var(--ink-2); max-width: 32em; }
.mak-case .meta-row { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); margin-top: 32px; border-radius: var(--r-mid); overflow: hidden; gap: 1px; background: var(--line) !important; padding: 0; }
.mak-case .meta-item { background: #fff; padding: 16px 18px; }
.mak-case .meta-item .k { font-size: 13px; color: var(--ink-3); margin-bottom: 6px; }
.mak-case .meta-item .v { font-weight: 600; font-size: 15px; line-height: 1.35; }

.case-cover { border-radius: var(--r-big); background: var(--silver); aspect-ratio: 1 / 1; display: grid; place-items: center; position: relative; overflow: hidden; }
.case-cover::before { content: ''; position: absolute; width: 58%; aspect-ratio: 1; border-radius: 50%; background: var(--a1); opacity: .22; filter: blur(30px); }
.case-cover img { position: relative; width: 72%; height: 72%; object-fit: contain; filter: drop-shadow(0 30px 40px rgba(23,23,28,.18)); }

.mak-case .section { padding: clamp(48px, 7vw, 88px) 0 0; }
.mak-case .sec-head { margin-bottom: 26px; }
.mak-case .sec-num { display: none; }
.mak-case .sec-head h2 { font-size: clamp(26px, 3vw, 38px); }
.mak-case .sec-head p { color: var(--ink-2); margin: 10px 0 0; max-width: 40em; }
.mak-case .about-grid, .mak-case .brand-grid, .mak-case .cols-3 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.mak-case .cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.mak-case .about-card { border-radius: var(--r-big); padding: clamp(22px, 3vw, 34px); background: var(--silver) !important; border: 0 !important; min-width: 0; }
.mak-case .about-card p { color: #3a3b42; margin: 0 0 14px; }
.mak-case .about-card p:last-child { margin-bottom: 0; }
.mak-case .about-card h3 { color: var(--ink) !important; font-family: var(--display) !important; }
.mak-case .tag-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 18px; }
.mak-case .tag { font-size: 14px; padding: 6px 12px; border-radius: 99px; background: #fff; border: 0; }
.mak-case .tag:nth-child(3n+1) { box-shadow: inset 3px 0 0 var(--a1); }
.mak-case .tag:nth-child(3n+2) { box-shadow: inset 3px 0 0 var(--a2); }
.mak-case .tag:nth-child(3n+3) { box-shadow: inset 3px 0 0 var(--a3); }
.mak-case .stat-strip { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 10px; margin-top: 20px; }
.mak-case .stat { border-radius: var(--r-mid); padding: 18px 14px; text-align: left; background: #fff !important; border: 0 !important; }
.mak-case .stat .num { font: 700 28px/1 var(--display); color: var(--ink); }
.mak-case .stat .lbl { font-size: 13px; color: var(--ink-2); margin-top: 8px; line-height: 1.4; }
.mak-case .palette-row { display: flex; flex-wrap: wrap; gap: 10px; }
.mak-case .palette-item { flex: 1 1 110px; min-width: 90px; }
.mak-case .palette-item > div { border: 1px solid rgba(23,23,28,.08) !important; }
.mak-case .brand-card { border-radius: var(--r-big); padding: 14px; background: var(--silver) !important; border: 0 !important; overflow: hidden; }
.mak-case .brand-img, .mak-case .site-img, .mak-case .photo-frame img { width: 100%; display: block; border-radius: var(--r-mid); }
.mak-case .brand-caption { padding: 16px 8px 8px; }
.mak-case .brand-caption h3 { font-size: 18px; margin-bottom: 8px; color: var(--ink) !important; }
.mak-case .brand-caption p { color: var(--ink-2); margin: 0; font-size: 15px; }

.mak-case .devices-card { border-radius: var(--r-big); padding: clamp(22px, 4vw, 44px); background: var(--silver) !important; border: 0 !important; }
.mak-case .devices-card .sec-head p { color: var(--ink-2) !important; }
.browser { margin-top: 10px; border-radius: 16px; background: #fff; box-shadow: 0 1px 0 var(--line), 0 30px 60px -30px rgba(23,23,28,.25); overflow: hidden; }
.browser__bar { display: flex; align-items: center; gap: 7px; padding: 12px 14px; border-bottom: 1px solid var(--line); }
.browser__bar i { width: 11px; height: 11px; border-radius: 50%; background: var(--silver-2); }
.browser__bar span { margin-left: 10px; font-size: 13px; color: var(--ink-3); background: var(--silver); padding: 4px 12px; border-radius: 99px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.browser__screen { height: min(68vh, 600px); overflow-y: auto; }
.browser__screen img { width: 100%; display: block; }
.browser-hint { font-size: 14px; color: var(--ink-2); margin: 12px 0 0; }

.mak-case .footer { padding: clamp(48px, 7vw, 88px) 0 20px; }
.mak-case .footer-inner { border-radius: var(--r-big); padding: clamp(28px, 5vw, 56px); display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; background: var(--ink) !important; color: #fff; border: 0 !important; }
.mak-case .footer-inner h2 { font-size: clamp(22px, 2.6vw, 32px); max-width: 18em; color: #fff; }
.mak-case .footer-cta { display: flex; gap: 10px; flex-wrap: wrap; }
.mak-case .footer-cta .small { display: none; }
.mak-case .btn { background: #fff; color: var(--ink); font-weight: 600; font-size: 16px; padding: 14px 22px; border-radius: 99px; white-space: nowrap; }
.mak-case .btn:hover { background: var(--lime); }
.mak-case .btn--ghost { background: transparent; color: #fff; box-shadow: inset 0 0 0 1px rgba(255,255,255,.4); }
.mak-case .btn--ghost:hover { background: rgba(255,255,255,.1); }

.case-next { display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap; padding: 28px 0 0; }
.case-next a { text-decoration: none; font-weight: 600; padding: 12px 18px; border-radius: 99px; border: 1px solid var(--line); }
.case-next a:hover { border-color: var(--ink); }

@media (max-width: 900px) {
  .mak-case .hero-grid, .mak-case .about-grid, .mak-case .brand-grid, .mak-case .cols-3 { grid-template-columns: 1fr; }
  .case-cover { max-width: 460px; aspect-ratio: 4 / 3; }
  .mak-case .hero-visual { order: -1; }
}

/* ---- Версия 2: новые блоки кейсов ---- */
.case-cover--photo::before { display: none; }
.case-cover--photo { aspect-ratio: 4 / 3; }
.case-cover--photo img { width: 100%; height: 100%; object-fit: cover; object-position: top; filter: none; }
.mak-case .card-h { font-size: 19px; margin-bottom: 10px; }
.mak-case .stat-strip--big { grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); margin-top: 0; }
.mak-case .stat-strip--big .stat { background: var(--silver) !important; padding: 26px 22px; }
.mak-case .stat-strip--big .num { font-size: clamp(34px, 4vw, 52px); color: var(--t2); }
.mak-case .stat-strip--big .lbl { font-size: 15px; }
.shots { display: grid; gap: 18px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.shots--1 { grid-template-columns: 1fr; }
.shots--3 .shot:first-child { grid-column: 1 / -1; }
.shot { margin: 0; }
.shot a { display: block; border-radius: var(--r-mid); overflow: hidden; background: var(--silver); box-shadow: 0 1px 0 var(--line), 0 24px 50px -30px rgba(23,23,28,.35); }
.shot img { width: 100%; transition: transform .6s cubic-bezier(.2,.7,.2,1); }
.shot a:hover img { transform: scale(1.02); }
.shot figcaption { padding: 10px 4px 0; font-size: 15px; color: var(--ink-2); }
.phones { display: flex; gap: clamp(16px, 4vw, 48px); justify-content: center; flex-wrap: wrap; background: var(--silver); border-radius: var(--r-big); padding: clamp(28px, 5vw, 56px) 20px; }
.phone { margin: 0; width: min(240px, 42vw); }
.phone__frame { border-radius: 34px; padding: 9px; background: #17171c; box-shadow: 0 30px 60px -28px rgba(23,23,28,.45); }
.phone__frame img { border-radius: 26px; width: 100%; aspect-ratio: 9 / 19.5; object-fit: cover; object-position: top; }
.phone figcaption { text-align: center; padding-top: 12px; font-size: 14px; color: var(--ink-2); }
.case-links { display: flex; gap: 10px; flex-wrap: wrap; }
.case-next a { display: flex; flex-direction: column; gap: 2px; }
.case-next small { font-weight: 400; font-size: 12px; color: var(--ink-3); }
.mak-case .palette-item p { font-size: 13px; color: var(--ink-2); margin: 8px 0 0; }
@media (max-width: 760px) { .shots { grid-template-columns: 1fr; } }
/* ---- Телефоны и планшеты (кейсы) ---- */
@media (max-width: 700px) {
  .mak-case .hero { padding-top: 104px !important; }
  .mak-case .hero h1 { font-size: clamp(26px, 7.6vw, 36px); }
  .mak-case .lead { font-size: 16px; }
  .mak-case .meta-row { grid-template-columns: 1fr 1fr; }
  .mak-case .meta-item { padding: 12px 12px; }
  .mak-case .meta-item .v { font-size: 14px; }
  .mak-case .section { padding-top: 44px; }
  .mak-case .stat-strip--big { grid-template-columns: 1fr 1fr; }
  .mak-case .stat-strip--big .stat { padding: 18px 14px; }
  .mak-case .stat-strip--big .num { font-size: 30px; }
  .mak-case .stat-strip--big .lbl { font-size: 13px; }
  .phones { padding: 22px 12px; gap: 14px; }
  .phone { width: calc(50% - 10px); }
  .browser__screen { height: 70vh; }
  .mak-case .footer-inner { padding: 26px 20px; }
  .mak-case .btn { font-size: 15px; padding: 12px 18px; }
  .case-next a { font-size: 14px; }
  .mak-case .palette-item { flex: 1 1 40%; }
}
/* ---- Компьютер, планшет и телефон рядом ---- */
.devs { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 26px; align-items: end; margin-top: 10px; }
.dev { margin: 0; }
.dev figcaption { margin-top: 10px; font-size: 13px; color: var(--ink-2, #5b5b66); text-align: center; }
.dev--desk .browser { margin-top: 0; }
.dev--desk .browser__screen { height: 560px; }
.devs__side { display: flex; gap: 18px; align-items: flex-end; }
.dev__frame { background: #17171c; padding: 9px; box-shadow: 0 30px 60px -28px rgba(23,23,28,.45); }
.dev__screen { overflow-y: auto; background: #fff; scrollbar-width: none; }
.dev__screen::-webkit-scrollbar { display: none; }
.dev__screen img { width: 100%; display: block; }
.dev--tab .dev__frame { border-radius: 24px; width: 300px; }
.dev--tab .dev__screen { border-radius: 16px; height: 400px; }
.dev--mob .dev__frame { border-radius: 30px; width: 176px; }
.dev--mob .dev__screen { border-radius: 22px; height: 360px; }
@media (max-width: 1100px) {
  .devs { grid-template-columns: 1fr; }
  .devs__side { justify-content: center; }
}
@media (max-width: 700px) {
  .dev--desk .browser__screen { height: 60vh; }
  .devs__side { gap: 12px; }
  .dev--tab .dev__frame { width: 56vw; }
  .dev--tab .dev__screen { height: 74vw; }
  .dev--mob .dev__frame { width: 34vw; }
  .dev--mob .dev__screen { height: 70vw; }
}
/* картинки не растягиваем больше родного размера — плохое качество не бросается в глаза */
.mak-case .shot img, .mak-case .section img:not(.dev__screen img):not(.browser__screen img) { max-width: 100%; }