/* ==========================================================================
   Adapt Design — вёрстка по макету Figma «Website Design»
   Файл: KBu78b82OLvm4m3MYH7eWU, рамки 1728×1117 (десктоп) и 440×956 (телефон)
   ========================================================================== */

@font-face {
  font-family: Manrope;
  src: url(../fonts/manrope-cyr.woff2) format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0301, U+0400-045F, U+0490-0491, U+04B0-04B1, U+2116;
}
@font-face {
  font-family: Manrope;
  src: url(../fonts/manrope-latin.woff2) format("woff2");
  font-weight: 200 800;
  font-display: swap;
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
    U+02DC, U+2000-206F, U+2074, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215,
    U+FEFF, U+FFFD;
}

:root {
  /* отступы макета: 66 px по краям, 100 px в сетке проектов (при 1728 px) */
  --pad: clamp(12px, 3.82vw, 66px);
  --pad-wide: clamp(12px, 5.79vw, 100px);
  --header-h: clamp(52px, 4.86vw, 84px);

  --margin-step: clamp(12px, 1.74vw, 30px); /* 30 px между блоками героя */
  --col-gap: clamp(8px, 2.31vw, 40px);      /* 40 px между колонками */

  --ink: #000;
  --paper: #fff;
  --on-dark: #f1f1f1;
  --radius: 7px;

  --font-ui: Manrope, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-label: "SF Pro Text", "SF Pro Display", -apple-system, BlinkMacSystemFont,
    "Segoe UI", Roboto, system-ui, sans-serif;

  --blur: blur(30px) saturate(1.6);
  --ease: cubic-bezier(0.22, 0.61, 0.36, 1);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

img {
  max-width: 100%;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid #000;
  outline-offset: 3px;
  border-radius: 4px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ==========================================================================
   Хедер
   ========================================================================== */

.header {
  position: fixed;
  inset: 0 0 auto;
  z-index: 60;
  display: flex;
  align-items: center;
  height: var(--header-h);
  padding: 0 var(--pad);
}

.header::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.2);
  -webkit-backdrop-filter: var(--blur);
  backdrop-filter: var(--blur);
  pointer-events: none;
}

/* на странице контактов подложка плотнее — 0.6 в макете */
.header--solid::before {
  background: rgba(255, 255, 255, 0.6);
}

.header > * {
  position: relative;
  z-index: 1;
}

.header__left,
.header__right {
  display: flex;
  align-items: center;
}

.header__right {
  margin-left: auto;
  gap: clamp(14px, 2.31vw, 40px);
}

.logo {
  font-size: clamp(20px, 1.85vw, 32px);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
}

.nav {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: center;
  gap: clamp(14px, 1.85vw, 32px);
  margin: 0;
  padding: 0;
  list-style: none;
}

.nav li {
  display: flex;
  align-items: center;
  gap: clamp(14px, 1.85vw, 32px);
}

.nav li + li::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--ink);
  flex: none;
}

.nav a {
  font-size: clamp(15px, 1.16vw, 20px);
  line-height: 1.36;
  font-weight: 400;
  text-decoration: none;
  white-space: nowrap;
  transition: opacity 0.2s var(--ease);
}

.nav a[aria-current="page"] {
  font-weight: 500;
}

.nav a:hover {
  opacity: 0.55;
}

.header__right {
  font-size: clamp(15px, 1.16vw, 20px);
}

.lang {
  display: inline-flex;
  align-items: center;
  gap: 2px;
  padding: 0;
  border: 0;
  background: none;
  font: inherit;
  color: inherit;
  cursor: pointer;
  transition: opacity 0.2s var(--ease);
}

.lang:hover {
  opacity: 0.55;
}

.lang svg {
  width: 16px;
  height: 16px;
  flex: none;
  transition: transform 0.3s var(--ease);
}

.header__cta {
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
  white-space: nowrap;
  transition: opacity 0.2s var(--ease);
}

.header__cta:hover {
  opacity: 0.55;
}

/* ==========================================================================
   Кнопки
   ========================================================================== */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  border: 0;
  border-radius: var(--radius);
  background: var(--ink);
  color: var(--on-dark);
  font-family: var(--font-label);
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.02em;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.25s var(--ease), transform 0.25s var(--ease);
}

.btn:hover {
  background: #1b1b1b;
}

.btn:active {
  transform: scale(0.99);
}

.btn--hero {
  width: 248px;
  height: 58px;
}

/* ==========================================================================
   Главная
   ========================================================================== */

.hero {
  position: relative;
  display: flex;
  align-items: center;
  min-height: 100svh;
  overflow: hidden;
  background: #9dc4e8;
}

.hero__media,
.hero__media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero__media img {
  object-fit: cover;
  object-position: 50% 50%;
}

.hero__content {
  position: relative;
  z-index: 2;
  width: 100%;
  padding: 0 var(--pad);
}

.hero__title {
  margin: 0;
  font-size: clamp(38px, 5.44vw, 94px);
  font-weight: 400;
  line-height: 0.98;
  letter-spacing: 0.02em;
}

.hero__title b {
  display: block;
  font-weight: 700;
}

.hero__sub {
  margin: var(--margin-step) 0 0;
  max-width: 46ch;
  font-size: clamp(15px, 1.27vw, 22px);
  line-height: 1.36;
}

.hero__cta {
  margin-top: var(--margin-step);
}

/* ==========================================================================
   Проекты
   ========================================================================== */

.page-projects {
  padding: calc(var(--header-h) + clamp(40px, 6.37vw, 110px)) 0
    clamp(32px, 5.79vw, 100px);
}

.page-title {
  margin: 0;
  padding: 0 var(--pad-wide);
  font-size: clamp(26px, 2.31vw, 40px);
  font-weight: 500;
  letter-spacing: -0.01em;
  line-height: 1.2;
}

.masonry {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--col-gap);
  margin-top: clamp(16px, 2.31vw, 40px);
  padding: 0 var(--pad-wide);
}

.masonry__col {
  display: flex;
  flex-direction: column;
  gap: var(--col-gap);
  min-width: 0;
}

.card {
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  overflow: hidden;
  cursor: zoom-in;
  -webkit-tap-highlight-color: transparent;
}

.card img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
  transition: transform 0.7s var(--ease), opacity 0.4s var(--ease);
}

.card:hover img {
  transform: scale(1.02);
}

.wide {
  margin: clamp(16px, 2.31vw, 40px) 0 0;
  padding: 0 var(--pad-wide);
}

/* ==========================================================================
   Контакты
   ========================================================================== */

.map-page {
  position: relative;
  height: 100svh;
  min-height: 600px;
  overflow: hidden;
}

#map {
  position: absolute;
  inset: 0;
  z-index: 0; /* свой контекст наложения: иначе панели Leaflet лезут поверх хедера */
  background: #e8e6e1
    url(../img/screenshot_2025-05-09_at_2.02.00_pm_1.webp) center / cover
    no-repeat;
}

.leaflet-container {
  font-family: var(--font-ui);
  background: transparent;
}

.leaflet-control-zoom {
  border: 0 !important;
  box-shadow: none !important;
}

@media (min-width: 769px) {
  .leaflet-right .leaflet-control-zoom {
    margin-top: calc(44vh - 60px) !important;
    margin-right: clamp(12px, 2.31vw, 40px) !important;
  }
}

.leaflet-control-zoom a {
  width: clamp(38px, 3.24vw, 56px) !important;
  height: clamp(40px, 3.36vw, 58px) !important;
  line-height: clamp(40px, 3.36vw, 58px) !important;
  border: 0 !important;
  border-radius: 14px !important;
  background: var(--ink) !important;
  color: #fff !important;
  font-size: 24px !important;
  margin-bottom: clamp(4px, 0.46vw, 8px) !important;
  transition: background 0.2s var(--ease);
}

.leaflet-control-zoom a:hover {
  background: #222 !important;
}

.leaflet-control-zoom-in {
  border-bottom-left-radius: 14px !important;
  border-top-left-radius: 14px !important;
}

.pin {
  background: none;
  border: 0;
}

.contact-card {
  position: absolute;
  z-index: 20;
  top: calc(var(--header-h) + clamp(20px, 2.31vw, 40px));
  left: var(--pad);
  width: min(485px, calc(100vw - var(--pad) * 2));
  padding: clamp(20px, 1.74vw, 30px) 28px;
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.6);
  -webkit-backdrop-filter: blur(40px) saturate(1.4);
  backdrop-filter: blur(40px) saturate(1.4);
  box-shadow: 0 2px 24px rgba(0, 0, 0, 0.06);
}

.contact-card p {
  margin: 0;
  font-family: var(--font-label);
  font-size: clamp(14px, 0.93vw, 16px);
  font-weight: 600;
  line-height: 1.19;
}

.contact-card p + p {
  margin-top: clamp(12px, 1.1vw, 19px);
}

.contact-card a {
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}

.contact-card a:hover {
  opacity: 0.6;
}

.map-actions {
  position: absolute;
  z-index: 20;
  left: var(--pad);
  bottom: clamp(80px, 5.4vw, 60px);
  display: flex;
  gap: clamp(12px, 2.31vw, 40px);
}

.btn--map {
  width: 260px;
  height: 70px;
  gap: 14px;
}

.btn--map svg {
  flex: none;
}

/* ==========================================================================
   Просмотр фото (лайтбокс)
   ========================================================================== */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 120;
  display: none;
  place-items: center;
  width: 100vw;
  max-width: none;
  height: 100svh;
  max-height: none;
  margin: 0;
  padding: 20px 0;
  border: 0;
  color: #fff;
  background: rgba(0, 0, 0, 0.94);
}

.lightbox[open] {
  display: grid;
}

.lightbox::backdrop {
  background: rgba(0, 0, 0, 0.94);
}

.lightbox__img {
  width: auto;
  height: auto;
  max-width: min(1436px, calc(100vw - 260px));
  max-height: calc(100svh - 40px);
  border-radius: var(--radius);
  object-fit: contain;
  background: #0d0d0d;
}

.lb-btn {
  position: absolute;
  display: grid;
  place-items: center;
  width: 50px;
  height: 50px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 14px;
  background: #111;
  color: #fff;
  cursor: pointer;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}

.lb-btn:hover {
  background: #232323;
}

.lb-btn svg {
  width: 22px;
  height: 22px;
}

.lb-close {
  top: 20px;
  right: 20px;
}

.lb-prev {
  left: clamp(12px, 2.31vw, 40px);
  top: 50%;
  transform: translateY(-50%);
}

.lb-next {
  right: clamp(12px, 2.31vw, 40px);
  top: 50%;
  transform: translateY(-50%);
}

.lb-prev:hover,
.lb-next:hover {
  transform: translateY(-50%) scale(1.04);
}


/* ==========================================================================
   Сетка проектов: плитка со названием при наведении
   ========================================================================== */

.tile {
  position: relative;
  display: block;
  overflow: hidden;
  /* пропорции плитки — как в макете (--ar: ширина/высота кадра) */
  aspect-ratio: var(--ar, 4 / 3);
  text-decoration: none;
  color: var(--paper);
  background: #e9e9e9;
}

.tile img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s var(--ease), filter 0.4s var(--ease);
}

.tile:hover img {
  transform: scale(1.03);
}

.tile__label {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: flex-end;
  gap: 14px;
  padding: clamp(14px, 1.4vw, 26px);
  background: linear-gradient(
    180deg,
    rgba(0, 0, 0, 0) 45%,
    rgba(0, 0, 0, 0.55) 100%
  );
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.3s var(--ease), transform 0.3s var(--ease);
}

.tile:hover .tile__label,
.tile:focus-visible .tile__label {
  opacity: 1;
  transform: none;
}

.tile__num {
  font-family: var(--font-label);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
  opacity: 0.8;
  flex: none;
  padding-bottom: 2px;
}

.tile__name {
  font-size: clamp(14px, 1.05vw, 19px);
  font-weight: 500;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* на тач-устройствах подпись видна всегда */
@media (hover: none) {
  .tile__label {
    opacity: 1;
    transform: none;
  }
}

/* ==========================================================================
   Страница проекта
   ========================================================================== */

.project {
  padding: calc(var(--header-h) + clamp(20px, 2.9vw, 50px)) var(--pad-wide)
    clamp(40px, 5vw, 96px);
}

.project__back {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-bottom: clamp(20px, 3vw, 46px);
  font-size: 15px;
  text-decoration: none;
  opacity: 0.6;
  transition: opacity 0.2s var(--ease);
}

.project__back:hover {
  opacity: 1;
}

.project__back svg {
  width: 18px;
  height: 18px;
}

.project__head {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: clamp(16px, 3.4vw, 64px);
  align-items: start;
  margin-bottom: clamp(24px, 3.6vw, 64px);
}

.project__num {
  font-size: clamp(26px, 2.55vw, 44px);
  font-weight: 500;
  line-height: 0.95;
  letter-spacing: -0.02em;
}

.project__title {
  margin: 0;
  max-width: 34ch;
  font-size: clamp(19px, 1.74vw, 30px);
  font-weight: 500;
  line-height: 1.14;
  letter-spacing: -0.01em;
  text-transform: uppercase;
}

.project__place {
  margin: 10px 0 0;
  font-size: clamp(14px, 1.16vw, 20px);
  opacity: 0.7;
}

.project__meta {
  display: grid;
  gap: 4px;
  max-width: 62ch;
  margin-top: clamp(12px, 1.5vw, 22px);
  font-family: var(--font-label);
  font-size: clamp(13px, 0.93vw, 15px);
  line-height: 1.45;
}

.project__meta p {
  margin: 0;
}

.project__grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  grid-auto-flow: row dense;
  gap: clamp(16px, 2.31vw, 40px);
  align-items: start;
}

.shot {
  margin: 0;
  min-width: 0;
}

.shot--wide {
  grid-column: 1 / -1;
}

.shot__btn {
  display: block;
  width: 100%;
  padding: 0;
  border: 0;
  background: none;
  cursor: zoom-in;
  overflow: hidden;
}

.shot__btn img {
  display: block;
  width: 100%;
  height: auto;
  transition: transform 0.6s var(--ease);
}

.shot__btn:hover img {
  transform: scale(1.015);
}

.shot figcaption {
  margin-top: 8px;
  font-family: var(--font-label);
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.65;
}

.project__pager {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  margin-top: clamp(40px, 5.4vw, 96px);
  padding-top: clamp(16px, 2vw, 28px);
  border-top: 1px solid rgba(0, 0, 0, 0.12);
}

.pager__link {
  display: grid;
  gap: 6px;
  max-width: 46%;
  text-decoration: none;
}

.pager__link--next {
  margin-left: auto;
  text-align: right;
}

.pager__label {
  font-family: var(--font-label);
  font-size: 12px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.5;
}

.pager__name {
  font-size: clamp(13px, 1.05vw, 18px);
  font-weight: 500;
  line-height: 1.3;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.pager__link:hover .pager__name {
  opacity: 0.6;
}

@media (max-width: 768px) {
  .project {
    padding-left: var(--pad);
    padding-right: var(--pad);
  }

  .project__head {
    grid-template-columns: 1fr;
    gap: 12px;
  }

  .project__num {
    font-size: 30px;
  }

  .project__title {
    font-size: 22px;
    max-width: none;
  }

  .project__grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .shot--wide {
    grid-column: auto;
  }

  .project__pager {
    flex-direction: column;
  }

  .pager__link,
  .pager__link--next {
    max-width: none;
    margin: 0;
    text-align: left;
  }
}

/* ==========================================================================
   Планшет и телефон: хедер-пилюли, нижняя навигация, герой снизу
   ========================================================================== */

.tabbar {
  display: none;
}

@media (max-width: 1100px) {
  .header {
    height: auto;
    padding: 8px;
    justify-content: space-between;
    align-items: flex-start;
  }

  .header::before {
    display: none;
  }

  .header__left,
  .header__right {
    height: 50px;
    padding: 0 18px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.3);
    -webkit-backdrop-filter: var(--blur);
    backdrop-filter: var(--blur);
  }

  .header__right {
    gap: 14px;
    font-size: 16px;
  }

  .header--solid .header__left,
  .header--solid .header__right {
    background: rgba(255, 255, 255, 0.55);
  }

  .logo {
    font-size: 20px;
  }

  .nav {
    display: none;
  }

  /* герой: текст прижат к низу, как в макете */
  .hero {
    align-items: flex-end;
  }

  .hero__media img {
    object-position: 41% 50%;
  }

  .hero::after {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    background: linear-gradient(
      180deg,
      rgba(255, 255, 255, 0) 58%,
      rgba(255, 255, 255, 0.3) 78%,
      rgba(255, 255, 255, 0.52) 100%
    );
  }

  .hero__title {
    display: flex;
    flex-direction: column;
    letter-spacing: 0;
    line-height: 1;
  }

  .hero__title span {
    display: block;
    font-weight: 400;
    font-size: 58px;
    line-height: 0.92;
  }

  .hero__title b {
    font-size: 46px;
    font-weight: 800;
    line-height: 1;
  }

  .hero__sub {
    max-width: none;
    font-size: 16px;
    margin-top: 12px;
  }

  .hero__cta {
    margin-top: 18px;
  }

  .hero__content {
    padding: 0 var(--pad) calc(58px + 16px);
  }

  .btn--hero {
    width: 100%;
    height: 50px;
  }

  .card:hover img {
    transform: none;
  }

  /* нижняя навигация */
  .tabbar {
    position: fixed;
    left: 8px;
    right: 8px;
    bottom: 8px;
    z-index: 70;
    display: flex;
    height: 50px;
    padding: 6px;
    border-radius: 11px;
    background: rgba(255, 255, 255, 0.3);
    -webkit-backdrop-filter: blur(19px) saturate(1.5);
    backdrop-filter: blur(19px) saturate(1.5);
  }

  .tabbar a {
    flex: 1;
    display: grid;
    place-items: center;
    border-radius: 6px;
    color: var(--ink);
    font-size: 13px;
    text-decoration: none;
  }

  .tabbar a[aria-current="page"] {
    background: rgba(255, 255, 255, 0.35);
    box-shadow: 0 1px 6px rgba(0, 0, 0, 0.08);
  }

  .leaflet-control-zoom {
    display: none !important;
  }

  .leaflet-bottom.leaflet-right {
    bottom: 66px;
  }
}

/* --------------------------------------------------------------------------
   Планшет 769–1100 px — размеры с планшетной рамки 1024×1366
   -------------------------------------------------------------------------- */

@media (min-width: 769px) and (max-width: 1100px) {
  :root {
    --pad: 30px;
    --pad-wide: 30px;
    --col-gap: 30px;
  }

  .header__left,
  .header__right {
    height: 60px;
    padding: 0 20px;
    border-radius: 18px;
    font-size: 20px;
  }

  .header__right {
    gap: 22px;
  }

  .logo {
    font-size: 28px;
  }

  .hero__content {
    padding: 0 30px calc(80px + 16px);
  }

  .hero__title span {
    font-size: 84px;
  }

  .hero__title b {
    font-size: 80px;
  }

  .hero__sub {
    font-size: 22px;
    margin-top: 24px;
  }

  .btn--hero {
    width: 243px;
    height: 58px;
  }

  .tabbar {
    left: 0;
    right: 0;
    max-width: 669px;
    height: 80px;
    margin: 0 auto;
    padding: 10px;
    border-radius: 18px;
  }

  .tabbar a {
    border-radius: 10px;
    font-size: 20px;
  }

  .page-projects {
    padding-top: 120px;
    padding-bottom: 140px;
  }

  .page-title {
    font-size: 40px;
  }

  .masonry {
    margin-top: 24px;
  }

  .wide {
    margin-top: 30px;
  }

  .contact-card {
    top: 125px;
    left: 30px;
    right: auto;
    width: 485px;
    padding: 30px 28px;
  }

  .map-actions {
    left: 30px;
    right: auto;
    bottom: 100px;
    gap: 20px;
  }

  .btn--map {
    width: 260px;
    height: 70px;
  }
}

/* --------------------------------------------------------------------------
   Телефон до 768 px — одна колонка, как в рамке 440×956
   -------------------------------------------------------------------------- */

@media (max-width: 768px) {
  .logo {
    font-size: 20px;
  }

  .page-projects {
    padding-top: calc(52px + 64px);
    padding-bottom: 76px;
  }

  .page-title {
    font-size: 26px;
  }

  .masonry {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-top: 14px;
  }

  .masonry__col {
    display: contents;
  }

  .card,
  .tile {
    order: var(--o, 0);
  }

  .wide {
    margin-top: 8px;
  }

  .contact-card {
    top: 66px;
    left: 8px;
    right: 8px;
    width: auto;
    padding: 20px;
  }

  .contact-card p {
    font-size: 14px;
  }

  .map-actions {
    left: 8px;
    right: 8px;
    bottom: 72px;
    gap: 8px;
  }

  .btn--map {
    flex: 1;
    width: auto;
    height: 50px;
    font-size: 15px;
  }

  .lightbox__img {
    max-width: calc(100vw - 16px);
    max-height: calc(100svh - 120px);
  }

  .lb-prev,
  .lb-next {
    top: auto;
    bottom: 24px;
    transform: none;
  }

  .lb-prev:hover,
  .lb-next:hover {
    transform: scale(1.04);
  }

  .lb-close {
    top: 12px;
    right: 12px;
    width: 44px;
    height: 44px;
  }
}

/* ==========================================================================
   Тёмная подложка для страниц без фото (если понадобится)
   ========================================================================== */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
