.gallery-page,
.gallery-photo-zone-page {
  --gallery-blue: #065ca9;
  --gallery-red: #ed1c24;
  --gallery-dark: #2c2c34;
  --gallery-ink: #202631;
  --gallery-muted: #5b6573;
  --gallery-line: rgba(6, 92, 169, 0.14);
  --gallery-shadow: 0 18px 48px rgba(20, 35, 55, 0.12);
  --gallery-radius: 22px;
  overflow-x: clip;
}

.gallery-page #main-content,
.gallery-photo-zone-page #main-content {
  overflow: hidden;
  color: var(--gallery-ink);
  background:
    radial-gradient(circle at top right, rgba(6, 92, 169, 0.08), transparent 30%),
    linear-gradient(180deg, #f8fbff 0%, #f2f4f8 100%);
}

.gallery-page #main-content img,
.gallery-page #main-content video,
.gallery-photo-zone-page #main-content img {
  display: block;
  max-width: 100%;
}

.gallery-hero {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: linear-gradient(120deg, rgba(6, 92, 169, 0.95), rgba(44, 44, 52, 0.97));
}

.gallery-hero::before {
  position: absolute;
  inset: 0;
  content: "";
  pointer-events: none;
  opacity: 0.4;
  background:
    linear-gradient(transparent 0 90%, rgba(255, 255, 255, 0.06) 90% 100%),
    repeating-linear-gradient(90deg, transparent 0 12%, rgba(255, 255, 255, 0.05) 12% 13%);
}

.gallery-hero__inner {
  position: relative;
  z-index: 1;
  padding-top: clamp(48px, 4vw, 52px);
  padding-bottom: clamp(48px, 5vw, 64px);
}

.gallery-hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2.8rem, 7vw, 5.4rem);
  line-height: 0.98;
  letter-spacing: 0.01em;
  text-transform: uppercase;
}

.gallery-hero p {
  max-width: 820px;
  margin: 0;
  color: #e5edf5;
  font-size: clamp(1rem, 2vw, 1.18rem);
  line-height: 1.75;
}

.gallery-section-nav {
  position: sticky;
  top: 87px;
  z-index: 800;
  border-bottom: 1px solid var(--gallery-line);
  background: rgba(248, 251, 255, 0.95);
  box-shadow: 0 10px 30px rgba(20, 35, 55, 0.06);
  backdrop-filter: blur(14px);
}

.gallery-section-nav__inner {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
  padding-top: 16px;
  padding-bottom: 16px;
}

.gallery-section-nav a {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 11px 20px;
  border: 1px solid rgba(6, 92, 169, 0.18);
  border-radius: 999px;
  color: var(--gallery-dark);
  background: #fff;
  box-shadow: 0 8px 24px rgba(20, 35, 55, 0.07);
  font-weight:500;
  text-align: center;
  text-decoration: none;
  transition: color 180ms ease, background-color 180ms ease, border-color 180ms ease, transform 180ms ease;
}

.gallery-section-nav a:hover,
.gallery-section-nav a:focus-visible {
  border-color: var(--gallery-blue);
  color: #fff;
  background: var(--gallery-blue);
  transform: translateY(-2px);
}

.gallery-section {
  padding-top: clamp(58px, 7vw, 92px);
  padding-bottom: clamp(34px, 5vw, 64px);
}

.gallery-section--hall {
  padding-bottom: clamp(76px, 9vw, 120px);
}

.gallery-section__title {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 30px;
}

.gallery-section__title::after {
  width: min(42%, 420px);
  height: 5px;
  border-radius: 99px;
  content: "";
  background: linear-gradient(90deg, var(--gallery-blue) 0 50%, var(--gallery-red) 50% 100%);
}

.gallery-kicker {
  margin: 0 0 5px;
  color: var(--gallery-blue);
  font-size: 0.76rem;
  font-weight:500;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.gallery-section__title h2 {
  margin: 0;
  color: var(--gallery-dark);
  font-size: clamp(2.25rem, 5vw, 4.2rem);
  line-height: 1;
  text-transform: uppercase;
}

.gallery-zone-grid,
.gallery-photo-grid,
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 250px));
  justify-content: center;
  gap: 22px;
}

.gallery-zone-grid {
  margin-bottom: 0;
}

.gallery-zone-card,
.gallery-media-card {
  overflow: hidden;
  border: 1px solid rgba(6, 92, 169, 0.1);
  border-radius: var(--gallery-radius);
  color: var(--gallery-dark);
  background: #fff;
  box-shadow: var(--gallery-shadow);
}

.gallery-zone-card {
  display: grid;
  min-height: 220px;
  grid-template-rows: 1fr auto;
  text-decoration: none;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.gallery-zone-card img {
  width: 100%;
  height: 170px;
  object-fit: cover;
}

.gallery-zone-card span,
.gallery-video-card span {
  display: block;
  padding: 16px 18px;
  border-top: 4px solid transparent;
  border-image: linear-gradient(90deg, var(--gallery-blue) 0 50%, var(--gallery-red) 50% 100%) 1;
  font-size: 1rem;
  font-weight:500;
  line-height: 1.3;
  text-align: left;
}

.gallery-media-card {
  width: 100%;
  padding: 0;
  font: inherit;
  cursor: zoom-in;
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.gallery-zone-card:hover,
.gallery-zone-card:focus-visible,
.gallery-media-card:hover,
.gallery-media-card:focus-visible {
  transform: translateY(-4px);
  box-shadow: 0 24px 58px rgba(20, 35, 55, 0.18);
}

.gallery-photo-card {
  aspect-ratio: 4 / 3;
}

.gallery-photo-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-video-card {
  display: grid;
  grid-template-rows: auto 1fr;
  align-content: start;
  cursor: pointer;
}

.gallery-video-card video {
  width: 100%;
  aspect-ratio: 16 / 9;
  background: #111;
  object-fit: cover;
  pointer-events: none;
}

.gallery-zone-card:focus-visible,
.gallery-media-card:focus-visible,
.gallery-section-nav a:focus-visible {
  outline: 3px solid rgba(6, 92, 169, 0.34);
  outline-offset: 4px;
}

.gallery-photo-zone-page .gallery-zone-hero {
  color: #fff;
  background: linear-gradient(120deg, rgba(6, 92, 169, 0.96), rgba(44, 44, 52, 0.98));
}

.gallery-photo-zone-page .gallery-zone-hero__inner {
  padding-top: clamp(32px, 3vw, 42px);
  padding-bottom: clamp(42px, 4vw, 56px);
}

.gallery-photo-zone-page .gallery-zone-hero h1 {
  margin: 8px 0 12px;
  font-size: clamp(2.35rem, 6vw, 4.8rem);
  line-height: 1;
}

.gallery-photo-zone-page .gallery-zone-hero .gallery-kicker,
.gallery-photo-zone-page .gallery-zone-count {
  color: #e5edf5;
}

.gallery-photo-zone-page .gallery-zone-count {
  margin: 0;
  font-weight:500;
}

.gallery-photo-zone-page .gallery-back-link {
  display: inline-flex;
  margin-bottom: 24px;
  padding: 10px 16px;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 999px;
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
  font-weight:500;
  text-decoration: none;
}

.gallery-photo-zone-page .gallery-back-link:hover,
.gallery-photo-zone-page .gallery-back-link:focus-visible {
  background: rgba(255, 255, 255, 0.18);
}

.gallery-photo-zone-page .gallery-back-link:focus-visible {
  outline: 3px solid rgba(255, 255, 255, 0.55);
  outline-offset: 3px;
}

.gallery-photo-zone-page .gallery-photo-zone-content {
  padding-top: clamp(48px, 7vw, 84px);
  padding-bottom: clamp(76px, 9vw, 120px);
}

.gallery-photo-zone-page .gallery-zone-footer {
  display: flex;
  margin-top: clamp(28px, 5vw, 48px);
}

.gallery-photo-zone-page .gallery-back-link--bottom {
  margin-bottom: 0;
  border-color: rgba(6, 92, 169, 0.35);
  color: var(--gallery-blue);
  background: #fff;
}

.gallery-photo-zone-page .gallery-back-link--bottom:hover,
.gallery-photo-zone-page .gallery-back-link--bottom:focus-visible {
  color: #fff;
  background: var(--gallery-blue);
}

.gallery-photo-zone-page .gallery-back-link--bottom:focus-visible {
  outline-color: rgba(6, 92, 169, 0.4);
}
.gallery-page.gallery-modal-open,
.gallery-photo-zone-page.gallery-modal-open {
  overflow: hidden;
}

.gallery-modal[hidden],
.gallery-modal__image-slot[hidden],
.gallery-modal__video-slot[hidden] {
  display: none;
}

.gallery-modal {
  position: fixed;
  inset: 0;
  z-index: 4000;
  display: grid;
  min-height: 100vh;
  min-height: 100dvh;
  place-items: center;
  padding: 22px;
}

.gallery-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 9, 16, 0.9);
  cursor: zoom-out;
}

.gallery-modal__dialog {
  position: relative;
  z-index: 1;
  display: grid;
  max-width: calc(100vw - 44px);
  max-height: calc(100vh - 44px);
  max-height: calc(100dvh - 44px);
  place-items: center;
  outline: none;
}

.gallery-modal__image,
.gallery-modal__video {
  width: auto;
  height: auto;
  max-width: calc(100vw - 44px);
  max-height: calc(100vh - 44px);
  max-height: calc(100dvh - 44px);
  border-radius: 16px;
  background: #080b0f;
  box-shadow: 0 28px 90px rgba(0, 0, 0, 0.5);
  object-fit: contain;
}

.gallery-modal__image {
  cursor: zoom-out;
}

.gallery-modal__video {
  width: min(1100px, calc(100vw - 44px));
}

.gallery-modal__close {
  position: absolute;
  top: 10px;
  right: 10px;
  z-index: 3;
  display: grid;
  width: 48px;
  height: 48px;
  padding: 0;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 50%;
  color: #fff;
  background: rgba(24, 32, 42, 0.9);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
}

.gallery-modal__close:focus-visible {
  outline: 3px solid #fff;
  outline-offset: 3px;
}

.gallery-visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

@media (max-width: 720px) {
  .gallery-section-nav__inner {
    gap: 7px;
    padding-top: 12px;
    padding-bottom: 12px;
  }

  .gallery-section-nav a {
    min-height: 44px;
    padding: 9px 8px;
    font-size: 0.88rem;
  }

  .gallery-section {
}

  .gallery-section__title::after {
    width: 28%;
  }

  .gallery-zone-grid,
  .gallery-photo-grid,
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr));
    gap: 14px;
  }
}

@media (max-width: 640px) and (orientation: portrait) {
  .gallery-hall-card video {
    aspect-ratio: 4 / 5;
  }

  .gallery-modal__video {
    max-height: calc(100dvh - 44px);
  }
}

@media (max-width: 430px) {
  .gallery-zone-grid,
  .gallery-photo-grid,
  .gallery-grid {
    grid-template-columns: 1fr;
  }

  .gallery-section__title::after {
    display: none;
  }

  .gallery-modal {
    padding: 12px;
  }

  .gallery-modal__dialog,
  .gallery-modal__image,
  .gallery-modal__video {
    max-width: calc(100vw - 24px);
    max-height: calc(100vh - 24px);
    max-height: calc(100dvh - 24px);
  }
}

/* Shared section-title typography: RO and EN */
.gallery-page .gallery-section__title h2{
  font-family:"Acari Sans",sans-serif;
  font-size:clamp(30px,4vw,52px);
  font-weight:500;
  line-height:1;
  letter-spacing:normal;
  text-transform:uppercase;
}
