/* ==========================================================================
   Abeille Gallery — hero + catalog
   Everything is scoped under .abg so Elementor / theme styles stay untouched.
   Accent green #30453C matches the live site.
   ========================================================================== */

/* Шрифты объявлены прямо здесь, чтобы файл был самодостаточным: hero и каталог
   выглядят правильно, даже если fonts.css почему-то не подключился.
   fonts.css — то же самое для остального сайта и редактора Elementor. */
@font-face {
  font-family: 'SangBleu Sunrise';
  src: url('fonts/sangbleusunrise-regular.woff2') format('woff2'),
       url('fonts/sangbleusunrise-regular.ttf') format('truetype');
  font-weight: 100 900; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'TT Norms Std Trl Cnd';
  src: url('fonts/TT_Norms_Std_Trial_Condensed_Thin.otf') format('opentype');
  font-weight: 100 200; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'TT Norms Std Trl Cnd';
  src: url('fonts/TT_Norms_Std_Trial_Condensed_Regular.otf') format('opentype');
  font-weight: 300 400; font-style: normal; font-display: swap;
}
@font-face {
  font-family: 'TT Norms Std Trl Cnd';
  src: url('fonts/TT_Norms_Std_Trial_Condensed_Medium.otf') format('opentype');
  font-weight: 500 600; font-style: normal; font-display: swap;
}

.abg,
.abg-lightbox {
  /* accents — same green as abeillegallery.com */
  --abg-green: #30453C;
  --abg-green-soft: #354A3E;
  --abg-green-line: #445950;
  --abg-burgundy: #A54C48;
  --abg-burgundy-deep: #8F3F3C;

  /* neutrals */
  --abg-warm-white: #FEFCF9;
  --abg-cream-light: #FAF8F4;
  --abg-sand: #E8DFD0;
  --abg-taupe: #C4B5A0;
  --abg-warm-gray: #8A7E72;
  --abg-charcoal: #2C2824;
  --abg-deep-brown: #1A1612;

  --abg-font-display: 'SangBleu Sunrise', 'Cormorant Garamond', Georgia, serif;
  --abg-font-text: 'TT Norms Std Trl Cnd', 'Helvetica Neue', Arial, sans-serif;

  --abg-shadow-card: 0 1px 25px rgba(0, 0, 0, .06);
  --abg-ease: cubic-bezier(.22, .61, .36, 1);
  --abg-max: 1320px;

  /* tweak the chip counter here */
  --abg-chip-badge-size: 9px;
}

.abg {
  box-sizing: border-box;
  max-width: var(--abg-max);
  margin: 0 auto;
  padding: 0 24px;
  font-family: var(--abg-font-text);
  color: var(--abg-charcoal);
  -webkit-font-smoothing: antialiased;
}
.abg *, .abg *::before, .abg *::after { box-sizing: border-box; }
.abg img { display: block; max-width: 100%; height: auto; }
.abg a { text-decoration: none; }
.abg-em { font-style: italic; color: var(--abg-burgundy); }
.abg-arrow { width: 21px; height: 14px; flex: none; }
.abg :focus-visible,
.abg-lightbox :focus-visible { outline: 2px solid var(--abg-burgundy); outline-offset: 3px; }

/* ---------------------------------------------------------------- buttons */
/* Те же меры против кнопочных стилей темы: состояния прописаны явно. */
.abg .abg-btn,
.abg a.abg-btn,
.abg button.abg-btn {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  height: 59px;
  padding: 0 26px;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  border: 1px solid transparent;
  border-radius: 16px;
  font-family: var(--abg-font-text);
  font-size: 15px;
  font-weight: 400;
  letter-spacing: .04em;
  line-height: 1;
  text-transform: none;
  text-decoration: none;
  text-shadow: none;
  background-image: none;
  box-shadow: none;
  cursor: pointer;
  transition: background-color .2s, color .2s, border-color .2s, transform .15s;
}
.abg .abg-btn:active { transform: translateY(1px); }
.abg .abg-btn[hidden] { display: none; }

.abg .abg-btn--primary,
.abg a.abg-btn--primary,
.abg button.abg-btn--primary { background-color: var(--abg-green); color: #fff; }
.abg .abg-btn--primary:hover,
.abg .abg-btn--primary:focus,
.abg .abg-btn--primary:active,
.abg a.abg-btn--primary:hover,
.abg button.abg-btn--primary:hover { background-color: var(--abg-green-soft); color: #fff; }

.abg .abg-btn--outline,
.abg a.abg-btn--outline,
.abg button.abg-btn--outline {
  background-color: transparent;
  border-color: var(--abg-green);
  color: var(--abg-green);
}
.abg .abg-btn--outline:hover,
.abg .abg-btn--outline:focus,
.abg .abg-btn--outline:active,
.abg button.abg-btn--outline:hover { background-color: var(--abg-green); color: #fff; }
.abg .abg-btn--outline.is-loading { opacity: .55; pointer-events: none; }

.abg .abg-icon-btn,
.abg a.abg-icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 59px;
  height: 59px;
  border: 1px solid var(--abg-green);
  border-radius: 100px;
  background-color: transparent;
  background-image: none;
  box-shadow: none;
  color: var(--abg-green);
  transition: background-color .2s, color .2s, transform .15s;
}
.abg .abg-icon-btn svg { width: 24px; height: 24px; }
.abg .abg-icon-btn:hover,
.abg .abg-icon-btn:focus,
.abg a.abg-icon-btn:hover { background-color: var(--abg-green); color: #fff; }
.abg .abg-icon-btn:active { transform: translateY(1px); }

/* ------------------------------------------------------------------- hero */
.abg-hero {
  display: flex;
  align-items: center;
  gap: 48px;
  padding-top: 56px;
  padding-bottom: 56px;
}
/* текстовая колонка заметно шире фотографии, чтобы строки не рвались */
.abg-hero__text { flex: 1 1 58%; min-width: 0; }
.abg-hero__h1 {
  margin: 0;
  font-family: var(--abg-font-display);
  font-weight: 500;
  font-size: clamp(34px, 4.4vw, 60px);
  line-height: 1.06;
  letter-spacing: -.01em;
  color: var(--abg-green);
  text-transform: none;
  max-width: 100%;
}
/* подзаголовок под H1 */
.abg .abg-hero__p {
  margin: 26px 0 0;
  max-width: 100%;
  font-family: var(--abg-font-text);
  font-weight: 400;
  font-size: clamp(17px, 1.5vw, 21px);
  line-height: 1.5;
  color: var(--abg-green-line);
  text-wrap: pretty;
}
.abg .abg-hero__p .abg-em { font-family: var(--abg-font-display); font-size: 1.06em; }

.abg-hero__cta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-wrap: wrap;
  margin-top: 36px;
}

/* Пропорция задана контейнеру, фото внутри — в процентах. Так овал остаётся
   овалом на любой ширине и не превращается в круг на мобильном. */
.abg .abg-hero__media {
  position: relative;
  flex: 0 1 42%;
  width: auto;
  max-width: 460px;
  aspect-ratio: 520 / 618;
  height: auto;
}
.abg .abg-hero__ring {
  position: absolute;
  inset: 0;
  border: 1.5px solid var(--abg-burgundy);
  border-radius: 50%;
}
/* Специфичность с запасом: тема и Elementor любят сбрасывать радиус у img */
.abg .abg-hero__media .abg-hero__photo,
.abg .abg-hero__media img.abg-hero__photo {
  position: absolute;
  left: 9.6%;
  top: 8%;
  width: 80.8%;
  height: 84%;
  max-width: none;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
}
.abg-hero__photo--empty {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--abg-cream-light);
  border: 1px dashed var(--abg-taupe);
  color: var(--abg-warm-gray);
  font-size: 14px;
  letter-spacing: .06em;
  text-align: center;
  line-height: 1.6;
}

/* ---------------------------------------------------------------- gallery */
.abg-gallery { padding-top: 64px; padding-bottom: 80px; }
.abg-gallery__head { margin-bottom: 28px; }
.abg-sec-head {
  margin: 0;
  font-family: var(--abg-font-display);
  font-weight: 500;
  font-size: clamp(30px, 3.4vw, 46px);
  line-height: 1.05;
  color: var(--abg-green);
  text-transform: none;
}
.abg-sec-sub {
  margin: 14px 0 0;
  font-family: var(--abg-font-display);
  font-style: italic;
  font-size: clamp(17px, 1.6vw, 22px);
  color: var(--abg-burgundy);
}

/* chips ------------------------------------------------------------------ */
.abg-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 34px 0 36px;
}
/* Кнопочные стили темы и кита Elementor бьют по любому <button>, поэтому
   каждое состояние чипса задано явно и с запасом по специфичности. */
.abg .abg-filters .abg-chip,
.abg .abg-filters .abg-chip:link,
.abg .abg-filters .abg-chip:visited {
  position: relative;
  -webkit-appearance: none;
  appearance: none;
  font-family: var(--abg-font-text);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: .03em;
  line-height: 1;
  text-transform: none;
  text-decoration: none;
  text-shadow: none;
  color: var(--abg-warm-gray);
  background-color: transparent;
  background-image: none;
  border: 1px solid var(--abg-sand);
  border-radius: 100px;
  padding: 12px 20px;
  margin: 0;
  box-shadow: none;
  cursor: pointer;
  transition: color .2s, border-color .2s, background-color .2s;
}
.abg .abg-filters .abg-chip:hover,
.abg .abg-filters .abg-chip:focus,
.abg .abg-filters .abg-chip:focus-visible,
.abg .abg-filters .abg-chip:active {
  color: var(--abg-green);
  background-color: transparent;
  background-image: none;
  border-color: var(--abg-green);
  box-shadow: none;
}
.abg .abg-filters .abg-chip.is-active,
.abg .abg-filters .abg-chip.is-active:hover,
.abg .abg-filters .abg-chip.is-active:focus,
.abg .abg-filters .abg-chip.is-active:active {
  color: #fff;
  background-color: var(--abg-green);
  background-image: none;
  border-color: var(--abg-green);
  box-shadow: none;
}

.abg-chip__count {
  position: absolute;
  top: -1px;
  left: 8px;
  min-width: 14px;
  padding: 2px 4px;
  border-radius: 100px;
  background: var(--abg-sand);
  color: var(--abg-green);
  font-size: var(--abg-chip-badge-size);
  line-height: 1;
  letter-spacing: 0;
  text-align: center;
}
.abg .abg-chip.is-active .abg-chip__count { background: var(--abg-burgundy); color: #fff; }

/* grid ------------------------------------------------------------------- */
.abg-grid { column-count: 3; column-gap: 30px; }
.abg-grid__empty {
  margin: 40px 0;
  text-align: center;
  font-size: 17px;
  color: var(--abg-warm-gray);
}
.abg-grid__empty[hidden] { display: none; }

.abg-card {
  break-inside: avoid;
  margin: 0 0 44px;
  animation: abg-in .4s var(--abg-ease) both;
}
@keyframes abg-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* frame: nothing moves on hover — only what is inside it */
.abg-card__frame {
  position: relative;
  overflow: hidden;
  border-radius: 14px;
  background: var(--abg-cream-light);
  box-shadow: var(--abg-shadow-card);
  transition: box-shadow .4s var(--abg-ease);
}
.abg-card__img {
  width: 100%;
  display: block;
}
.abg-card__link { position: absolute; inset: 0; z-index: 2; }

/* veil + bottom bar */
.abg-card__veil {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(26, 22, 18, .62) 0%, rgba(26, 22, 18, .14) 42%, rgba(26, 22, 18, 0) 72%);
  opacity: 0;
  transition: opacity .35s var(--abg-ease);
  pointer-events: none;
}
/* bottom-left: "Подробнее" */
.abg-card__bar {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  z-index: 3;
  display: flex;
  align-items: center;
  padding: 16px;
  opacity: 0;
  transform: translateY(6px);
  transition: opacity .3s var(--abg-ease), transform .3s var(--abg-ease);
  pointer-events: none;
}
.abg-card__more {
  font-family: var(--abg-font-text);
  font-size: 14px;
  letter-spacing: .06em;
  color: #fff;
  border-bottom: 1px solid rgba(255, 255, 255, .45);
  padding-bottom: 2px;
}

/* top-right: lightbox trigger, sits clear of the caption */
.abg .abg-card__zoom {
  -webkit-appearance: none;
  appearance: none;
  padding: 0;
  margin: 0;
  box-shadow: none;
  position: absolute;
  top: 12px;
  right: 12px;
  z-index: 4;
  width: 38px;
  height: 38px;
  border-radius: 100px;
  border: 1px solid rgba(255, 255, 255, .5);
  background: rgba(26, 22, 18, .32);
  -webkit-backdrop-filter: blur(6px);
  backdrop-filter: blur(6px);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  transform: translateY(-4px);
  transition: opacity .3s var(--abg-ease), transform .3s var(--abg-ease),
              background .25s, color .25s, border-color .25s;
}
.abg .abg-card__zoom svg { width: 17px; height: 17px; }
.abg .abg-card__zoom:hover,
.abg .abg-card__zoom:focus { background-color: #fff; color: var(--abg-green); border-color: #fff; }
.abg .abg-card__zoom:focus-visible { opacity: 1; transform: none; }

/* hover: nothing moves or rescales — light veil, caption, quiet shadow */
@media (hover: hover) {
  .abg-card:hover .abg-card__frame { box-shadow: 0 8px 28px rgba(0, 0, 0, .11); }
  .abg-card:hover .abg-card__veil { opacity: 1; }
  .abg-card:hover .abg-card__bar { opacity: 1; transform: none; }
  .abg-card:hover .abg-card__zoom { opacity: 1; transform: none; }
  .abg .abg-card:hover .abg-card__title,
  .abg .abg-card:hover h3.abg-card__title { color: var(--abg-burgundy); }
}
/* touch devices: no hover state exists — keep the affordance visible,
   with a lighter veil so the artwork stays readable */
@media (hover: none) {
  .abg-card__veil {
    opacity: 1;
    background: linear-gradient(to top, rgba(26, 22, 18, .5) 0%, rgba(26, 22, 18, 0) 46%);
  }
  .abg-card__bar { opacity: 1; transform: none; }
  .abg .abg-card__zoom { opacity: 1; transform: none; }
}

.abg-card__body { display: block; color: inherit; }
/* Названия товаров в Woo набраны вразнобой, поэтому приводим их к одному виду:
   всё строчными, заглавная только первая. */
.abg .abg-card .abg-card__title,
.abg .abg-card h3.abg-card__title {
  margin: 14px 0 0;
  padding: 0;
  /* кит Elementor задаёт типографику всем h3 — держим своё принудительно */
  font-family: var(--abg-font-text) !important;
  font-weight: 400 !important;
  font-size: 17px !important;
  line-height: 1.3 !important;
  letter-spacing: normal;
  color: var(--abg-charcoal);
  text-transform: lowercase;
  transition: color .25s var(--abg-ease);
}
.abg .abg-card .abg-card__title::first-letter { text-transform: uppercase; }
.abg-card__foot {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 12px;
  margin-top: 8px;
}
.abg-card__cat {
  font-family: var(--abg-font-display);
  font-style: italic;
  font-size: 15px;
  color: var(--abg-taupe);
}
.abg-card__price {
  font-family: var(--abg-font-display);
  font-size: 21px;
  white-space: nowrap;
  color: var(--abg-green);
}
.abg-card__price--sold { color: var(--abg-burgundy); font-style: italic; }
.abg-card__price--ask {
  font-size: 15px;
  font-style: italic;
  color: var(--abg-warm-gray);
  white-space: normal;
  text-align: right;
}

.abg-gallery__foot { display: flex; justify-content: center; margin-top: 12px; }

/* ------------------------------------------- плашка «продано» на карточке товара */
.abg.abg-sold {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  max-width: 720px;
  margin: 0 0 24px;
  padding: 20px 22px;
  background: var(--abg-cream-light);
  border: 1px solid var(--abg-sand);
  border-radius: 14px;
}
.abg-sold__mark {
  flex: none;
  width: 44px;
  height: 44px;
  border-radius: 100px;
  background: rgba(165, 76, 72, .1);
  color: var(--abg-burgundy);
  display: flex;
  align-items: center;
  justify-content: center;
}
.abg-sold__mark svg { width: 22px; height: 22px; }

/* текст не уже 240px — кончилось место, кнопка сама переносится вниз */
.abg-sold__body { flex: 1 1 240px; min-width: 0; }

.abg .abg-sold__title {
  margin: 0;
  font-family: var(--abg-font-display) !important;
  font-size: 19px !important;
  line-height: 1.25 !important;
  color: var(--abg-burgundy);
  text-wrap: balance;
}
.abg .abg-sold__text {
  margin: 6px 0 0;
  font-family: var(--abg-font-text) !important;
  font-size: 15px !important;
  line-height: 1.45 !important;
  color: var(--abg-warm-gray);
  text-wrap: pretty;
}
.abg .abg-sold__btn,
.abg a.abg-sold__btn {
  flex: 0 1 auto;
  height: 50px;
  padding: 0 20px;
  gap: 10px;
  white-space: nowrap;
}
.abg .abg-sold__btn svg { width: 18px; height: 18px; }

@media (max-width: 640px) {
  .abg.abg-sold { gap: 14px; padding: 16px 16px 18px; }
  .abg-sold__mark { width: 36px; height: 36px; }
  .abg-sold__mark svg { width: 18px; height: 18px; }
  .abg-sold__body { flex: 1 1 calc(100% - 50px); }
  .abg .abg-sold__title { font-size: 17px !important; }
  .abg .abg-sold__text { font-size: 14px !important; }
  .abg .abg-sold__btn,
  .abg a.abg-sold__btn { flex: 1 0 100%; justify-content: center; height: 46px; }
}

/* -------------------------------------------------------------- lightbox */
.abg-lightbox {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(26, 22, 18, .9);
  -webkit-backdrop-filter: blur(3px);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  transition: opacity .3s var(--abg-ease), visibility .3s;
  font-family: var(--abg-font-text);
}
.abg-lightbox.is-open { opacity: 1; visibility: visible; }
.abg-lightbox * { box-sizing: border-box; }

.abg-lightbox__stage {
  position: relative;
  max-width: min(1100px, 100%);
  max-height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}
.abg-lightbox__img {
  max-width: 100%;
  max-height: calc(100vh - 190px);
  border-radius: 10px;
  box-shadow: 0 18px 60px rgba(0, 0, 0, .45);
  transform: scale(.97);
  opacity: 0;
  transition: transform .35s var(--abg-ease), opacity .3s var(--abg-ease);
}
.abg-lightbox.is-open .abg-lightbox__img { transform: none; opacity: 1; }
.abg-lightbox__img.is-swapping { opacity: 0; }

.abg-lightbox__caption {
  text-align: center;
  color: #fff;
  max-width: 640px;
}
.abg-lightbox .abg-lightbox__title {
  font-family: var(--abg-font-display);
  font-size: 22px;
  line-height: 1.2;
  margin: 0;
  font-weight: 500;
}
.abg-lightbox .abg-lightbox__meta {
  margin: 6px 0 0;
  font-size: 13px;
  letter-spacing: .06em;
  color: var(--abg-taupe);
}
.abg-lightbox .abg-lightbox__link,
.abg-lightbox a.abg-lightbox__link,
.abg-lightbox a.abg-lightbox__link:link,
.abg-lightbox a.abg-lightbox__link:visited {
  display: inline-block;
  margin-top: 12px;
  padding: 0 0 2px;
  font-family: var(--abg-font-text);
  font-size: 15px;
  color: #fff;
  background: none;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, .5);
  text-decoration: none;
}
.abg-lightbox .abg-lightbox__link:hover,
.abg-lightbox a.abg-lightbox__link:hover,
.abg-lightbox a.abg-lightbox__link:focus { color: #fff; border-bottom-color: #fff; }

.abg-lightbox .abg-lightbox__btn,
.abg-lightbox button.abg-lightbox__btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 52px;
  height: 52px;
  padding: 0;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: 100px;
  background-color: rgba(255, 255, 255, .08);
  background-image: none;
  box-shadow: none;
  color: #fff;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color .25s, border-color .25s;
}
.abg-lightbox .abg-lightbox__btn:hover,
.abg-lightbox .abg-lightbox__btn:focus,
.abg-lightbox .abg-lightbox__btn:active {
  background-color: rgba(255, 255, 255, .2);
  border-color: rgba(255, 255, 255, .7);
  color: #fff;
}
.abg-lightbox__btn svg { width: 20px; height: 20px; }
/* стрелки при одной фотографии: [hidden] должен победить display:flex базового правила */
.abg-lightbox .abg-lightbox__btn[hidden],
.abg-lightbox button.abg-lightbox__btn[hidden] { display: none; }
.abg-lightbox__prev { left: -76px; }
.abg-lightbox__next { right: -76px; }

.abg-lightbox .abg-lightbox__close,
.abg-lightbox button.abg-lightbox__close {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 48px;
  height: 48px;
  padding: 0;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  border: 1px solid rgba(255, 255, 255, .35);
  border-radius: 100px;
  background-color: rgba(255, 255, 255, .08);
  background-image: none;
  box-shadow: none;
  color: #fff;
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}
.abg-lightbox .abg-lightbox__close:hover,
.abg-lightbox .abg-lightbox__close:focus { background-color: rgba(255, 255, 255, .2); color: #fff; }

.abg-lightbox__dots {
  display: flex;
  gap: 7px;
  justify-content: center;
}
.abg-lightbox .abg-lightbox__dot,
.abg-lightbox button.abg-lightbox__dot {
  width: 7px;
  height: 7px;
  min-width: 0;
  border-radius: 100px;
  border: 0;
  padding: 0;
  margin: 0;
  -webkit-appearance: none;
  appearance: none;
  background-color: rgba(255, 255, 255, .3);
  background-image: none;
  box-shadow: none;
  cursor: pointer;
  transition: background-color .25s, transform .25s;
}
.abg-lightbox .abg-lightbox__dot.is-active,
.abg-lightbox .abg-lightbox__dot.is-active:hover { background-color: #fff; transform: scale(1.25); }

html.abg-lock, body.abg-lock { overflow: hidden; }

/* ------------------------------------------------------------- responsive */
@media (max-width: 1100px) {
  .abg-hero { gap: 32px; }
  .abg .abg-hero__media { max-width: 380px; }
  .abg-grid { column-count: 2; column-gap: 24px; }
  .abg-lightbox__prev { left: 4px; }
  .abg-lightbox__next { right: 4px; }
}

@media (max-width: 860px) {
  .abg { padding: 0 20px; }
  /* text first, photo after — matches the reading order */
  .abg-hero {
    flex-direction: column;
    align-items: stretch;
    padding-top: 36px;
    gap: 36px;
  }
  /* пропорция та же, что на десктопе — овал, а не круг */
  .abg .abg-hero__media {
    flex: none;
    width: min(320px, 78vw);
    max-width: none;
    margin: 0 auto;
    order: 2;
  }
  .abg-hero__cta { margin-top: 30px; }
  .abg-gallery { padding-top: 40px; padding-bottom: 56px; }
  .abg-card { margin-bottom: 30px; }

  /* narrow screens are touch in practice — show the affordance without hover */
  .abg-card__veil {
    opacity: 1;
    background: linear-gradient(to top, rgba(26, 22, 18, .5) 0%, rgba(26, 22, 18, 0) 46%);
  }
  .abg-card__bar { opacity: 1; transform: none; }
  .abg .abg-card__zoom { opacity: 1; transform: none; }
}

/* phones — masonry stays at 2 columns */
@media (max-width: 560px) {
  .abg { padding: 0 16px; }
  .abg-grid { column-count: 2; column-gap: 14px; }
  .abg-card { margin-bottom: 22px; }
  .abg-card__frame { border-radius: 10px; }
  /* короткие заголовки в две строки: низ карточек не пляшет */
  .abg .abg-card .abg-card__title,
  .abg .abg-card h3.abg-card__title {
    margin-top: 9px;
    font-size: 16px !important;
    line-height: 1.3 !important;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
  }
  .abg-card__foot { flex-direction: column; align-items: flex-start; gap: 1px; margin-top: 4px; }
  .abg-card__cat { font-size: 11px; }
  .abg-card__price { font-size: 14px; }
  .abg-card__price--ask { font-size: 11px; text-align: left; }
  .abg-card__bar { padding: 10px; }
  .abg-card__more { font-size: 12px; letter-spacing: .04em; }
  .abg .abg-card__zoom { width: 32px; height: 32px; top: 8px; right: 8px; }
  .abg .abg-card__zoom svg { width: 15px; height: 15px; }

  /* кнопки на телефоне компактнее */
  .abg-hero { padding-top: 30px; }
  .abg .abg-btn,
  .abg a.abg-btn,
  .abg button.abg-btn { height: 46px; padding: 0 18px; font-size: 14px; gap: 10px; border-radius: 13px; }
  .abg .abg-btn .abg-arrow { width: 17px; height: 11px; }
  .abg .abg-icon-btn,
  .abg a.abg-icon-btn { width: 46px; height: 46px; }
  .abg .abg-icon-btn svg { width: 20px; height: 20px; }
  .abg-hero__cta { gap: 10px; margin-top: 24px; }
  .abg .abg-hero__p { margin-top: 18px; font-size: 16px; line-height: 1.45; }
  .abg-filters { gap: 8px; margin: 26px 0 28px; }
  .abg .abg-chip { font-size: 13px; padding: 11px 15px; }

  .abg-lightbox { padding: 12px; }
  .abg-lightbox__img { max-height: calc(100vh - 210px); }
  .abg-lightbox__btn { width: 44px; height: 44px; }
}

@media (max-width: 380px) {
  .abg-hero__cta { flex-wrap: nowrap; }
  .abg .abg-btn,
  .abg a.abg-btn,
  .abg button.abg-btn { flex: 1 1 auto; justify-content: center; padding: 0 12px; font-size: 13px; }
}

@media (prefers-reduced-motion: reduce) {
  .abg-card,
  .abg-card__veil,
  .abg-card__bar,
  .abg-card__zoom,
  .abg-lightbox,
  .abg-lightbox__img { animation: none !important; transition: none !important; }
}
