/*
 * Altezza — галерея фотографий магазина на странице «О нас».
 * Отдельный файл, подключается только на /about/. Все правила с префиксом .alag.
 * Палитра сайта: #13465b / #1c6a88.
 */
.about-sec .alag-host { margin: 0 0 22px; }

.alag {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr);
  grid-template-rows: repeat(2, clamp(196px, 25.2vw, 280px));
  gap: 16px;
}
.alag-item {
  position: relative;
  display: block;
  min-width: 0;
  overflow: hidden;
  border-radius: 16px;
  background: #e8eff3;
  box-shadow: 0 10px 28px rgba(19, 70, 91, .14);
  cursor: zoom-in;
  text-decoration: none;
  transition: box-shadow .25s ease, transform .25s ease;
}
.alag-item--1 { grid-row: 1 / span 2; }
.about-sec .alag-host .alag-item img {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 0;
  box-shadow: none;
  object-fit: cover;
  transition: transform .5s ease;
}
.about-sec .alag-host .alag-item--1 img { object-position: 50% 36%; }
.about-sec .alag-host .alag-item--2 img { object-position: 50% 28%; }
.about-sec .alag-host .alag-item--3 img { object-position: 50% 52%; }

.alag-item:hover { box-shadow: 0 16px 36px rgba(19, 70, 91, .22); transform: translateY(-2px); }
.about-sec .alag-host .alag-item:hover img { transform: scale(1.035); }
.alag-item:focus-visible { outline: 3px solid #1c6a88; outline-offset: 3px; }

.alag-caption {
  position: absolute;
  left: 14px;
  bottom: 14px;
  max-width: calc(100% - 28px);
  padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  font-size: 14px;
  font-weight: 600;
  line-height: 1.2;
  color: #13465b;
  box-shadow: 0 4px 14px rgba(19, 70, 91, .18);
}
.alag-zoom {
  position: absolute;
  top: 14px;
  right: 14px;
  display: grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: #13465b;
  box-shadow: 0 4px 14px rgba(19, 70, 91, .18);
  opacity: 0;
  transform: scale(.9);
  transition: opacity .2s, transform .2s;
}
.alag-item:hover .alag-zoom,
.alag-item:focus-visible .alag-zoom { opacity: 1; transform: none; }

/* Планшет: большое фото сверху, две других рядом */
@media (max-width: 1030px) {
  .alag { grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; gap: 14px; }
  .alag-item--1 { grid-row: auto; grid-column: 1 / -1; aspect-ratio: 3 / 2; }
  .about-sec .alag-host .alag-item--1 img { object-position: 50% 14%; }
  .alag-item--2, .alag-item--3 { aspect-ratio: 4 / 5; }
  .alag-zoom { opacity: 1; transform: none; }
}
/* Телефон: вертикальная сетка */
@media (max-width: 560px) {
  .alag { grid-template-columns: minmax(0, 1fr); gap: 12px; }
  .alag-item--1, .alag-item--2, .alag-item--3 { grid-column: auto; aspect-ratio: 4 / 5; }
  .about-sec .alag-host .alag-item--1 img { object-position: 50% 36%; }
  .alag-item { border-radius: 12px; }
  .alag-caption { left: 10px; bottom: 10px; font-size: 13px; padding: 7px 12px; }
  .alag-zoom { top: 10px; right: 10px; width: 34px; height: 34px; }
}

/* ---------- Просмотрщик ---------- */
html.alag-lock { overflow: hidden; }
.alag-dialog {
  width: 100vw;
  max-width: 100vw;
  height: 100vh;
  height: 100dvh;
  max-height: none;
  margin: 0;
  padding: 0;
  border: 0;
  background: rgba(8, 24, 33, .94);
  color: #fff;
}
.alag-dialog::backdrop { background: rgba(8, 24, 33, .94); }
.alag-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  height: 100%;
  padding: 56px 72px 28px;
  box-sizing: border-box;
}
.alag-figure {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  max-width: 100%;
  max-height: 100%;
  margin: 0;
}
.alag-full {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: calc(100vh - 150px);
  max-height: calc(100dvh - 150px);
  object-fit: contain;
  border-radius: 8px;
  background: #0d2430;
}
.alag-figcap { display: flex; gap: 16px; align-items: baseline; font-size: 15px; line-height: 1.3; color: #dcebf2; }
.alag-count { font-size: 13px; color: #8fb0c0; }
.alag-btn {
  position: absolute;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .28);
  border-radius: 50%;
  background: rgba(255, 255, 255, .1);
  color: #fff;
  cursor: pointer;
  transition: background .18s, border-color .18s;
}
.alag-btn:hover { background: rgba(255, 255, 255, .22); border-color: rgba(255, 255, 255, .55); }
.alag-btn:focus-visible { outline: 3px solid #8cc2d6; outline-offset: 2px; }
.alag-close { top: 14px; right: 16px; }
.alag-prev, .alag-next { top: 50%; margin-top: -23px; }
.alag-prev { left: 14px; }
.alag-next { right: 14px; }
@media (max-width: 700px) {
  .alag-stage { padding: 60px 12px 20px; }
  .alag-full { max-height: calc(100dvh - 150px); }
  .alag-prev, .alag-next { top: auto; bottom: 14px; margin: 0; }
  .alag-prev { left: calc(50% - 56px); }
  .alag-next { right: calc(50% - 56px); }
  .alag-figcap { margin-bottom: 52px; }
}
@media (prefers-reduced-motion: reduce) {
  .alag-item, .about-sec .alag-host .alag-item img, .alag-zoom, .alag-btn { transition: none; }
  .alag-item:hover, .about-sec .alag-host .alag-item:hover img { transform: none; }
}
