.lifestyle-gallery {
  --gallery-ink: #25382b;
  --gallery-accent: #244a30;
  --gallery-muted: #526257;
  --gallery-surface: #f1f4ef;
  max-width: 1550px;
  margin: 0 auto;
  padding: clamp(44px, 7vw, 96px) var(--gutter, 24px);
  color: var(--gallery-ink);
  min-width: 0;
}

.lifestyle-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  grid-template-areas: 'title steps' 'intro intro';
  gap: 10px 18px;
  align-items: center;
}

.lifestyle-head h2 {
  grid-area: title;
  font-size: clamp(30px, 4.1vw, 52px);
  line-height: 1.22;
  margin: 0;
  overflow-wrap: anywhere;
}

.lifestyle-intro {
  grid-area: intro;
  max-width: 42em;
  margin: 0;
  color: var(--gallery-muted);
  font-size: 17px;
  line-height: 1.7;
}

.lifestyle-stepper {
  grid-area: steps;
  display: flex;
  gap: 8px;
}

.lifestyle-gallery button {
  color: inherit;
  font: inherit;
  touch-action: manipulation;
}

.lifestyle-stepper button,
.lifestyle-filters button,
.lifestyle-dialog-head button {
  display: inline-grid;
  min-height: 44px;
  place-items: center;
  border: 1px solid #d7e0d5;
  background: #fff;
}

.lifestyle-stepper button {
  width: 44px;
  padding: 0;
  border-radius: 50%;
  font-size: 26px;
  line-height: 1;
}

.lifestyle-stepper button[aria-disabled='true'] {
  opacity: .48;
  cursor: default;
  border-style: dashed;
}

.lifestyle-stepper button[hidden],
.lifestyle-play-icon,
[data-lifestyle-play][data-paused] .lifestyle-pause-icon { display: none; }

[data-lifestyle-play][data-paused] .lifestyle-play-icon { display: initial; }

.lifestyle-filters {
  display: flex;
  min-width: 0;
  gap: 8px;
  margin: 16px 0 14px;
  padding: 4px 4px 6px;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scrollbar-width: thin;
}

.lifestyle-filters button {
  flex: 0 0 auto;
  padding: 7px 16px;
  border-radius: 999px;
  white-space: nowrap;
  font-size: 15px;
}

.lifestyle-filters button[aria-pressed='true'] {
  color: #fff;
  border-color: var(--gallery-accent);
  background: var(--gallery-accent);
  font-weight: 650;
}

.lifestyle-track {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: min(70%, 650px);
  gap: clamp(14px, 2vw, 28px);
  margin: 14px 0 0;
  padding: 5px 5px 15px;
  min-width: 0;
  overflow-x: auto;
  overscroll-behavior-x: contain;
  scroll-padding-inline: 5px;
  scroll-snap-type: x mandatory;
  scroll-behavior: auto;
  scrollbar-width: thin;
  list-style: none;
}

.lifestyle-track-single { grid-auto-columns: min(100%, 900px); }
.lifestyle-card { min-width: 0; scroll-snap-align: start; }
.lifestyle-card[hidden] { display: none; }
.lifestyle-card figure { margin: 0; }

.lifestyle-photo {
  position: relative;
  display: block;
  width: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  border-radius: 12px;
  overflow: hidden;
  background: var(--gallery-surface);
  cursor: zoom-in;
}

.lifestyle-photo img {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 3 / 2;
  object-fit: contain;
}

.lifestyle-enlarge {
  position: absolute;
  right: 12px;
  bottom: 12px;
  padding: 6px 10px;
  border-radius: 999px;
  color: #fff;
  background: #20362be8;
  font-size: 12px;
  line-height: 1.3;
}

.lifestyle-card figcaption { padding: 12px 1px 0; }
.lifestyle-card h3 { margin: 0; font-size: clamp(19px, 2.3vw, 25px); line-height: 1.45; }
.lifestyle-card p { margin: 7px 0 0; color: var(--gallery-muted); font-size: 16px; line-height: 1.7; }
.lifestyle-card h3, .lifestyle-card p { overflow-wrap: anywhere; }

.lifestyle-gallery :focus-visible {
  outline: 2px solid #315f40;
  outline-offset: 2px;
}

.lifestyle-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.lifestyle-dialog {
  width: min(calc(100% - 32px), 1100px);
  max-width: none;
  max-height: calc(100dvh - 32px);
  padding: clamp(12px, 2.3vw, 26px);
  border: 0;
  border-radius: 14px;
  overflow: auto;
  overscroll-behavior: contain;
  color: var(--gallery-ink);
  background: #fff;
}

.lifestyle-dialog::backdrop { background: #15251acc; }

.lifestyle-dialog-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.lifestyle-dialog-head h3 { min-width: 0; margin: 0; font-size: clamp(17px, 2.5vw, 24px); overflow-wrap: anywhere; }
.lifestyle-dialog-head button { flex: none; padding: 6px 14px; border-radius: 999px; font-size: 15px; }
.lifestyle-dialog-media { display: grid; place-items: center; }
.lifestyle-dialog-media img {
  display: block;
  width: auto;
  height: auto;
  max-width: 100%;
  max-height: max(160px, calc(100dvh - 158px));
  object-fit: contain;
}
.lifestyle-dialog-copy { color: var(--gallery-muted); font-size: 15px; line-height: 1.7; margin: 12px 0 0; }

@media (max-width: 760px) {
  .lifestyle-track { grid-auto-columns: 84%; }
  .lifestyle-track-single { grid-auto-columns: 100%; }
  .lifestyle-intro { font-size: 16px; }
  .lifestyle-head { gap: 8px 12px; }
  .lifestyle-filters { margin-block: 12px 8px; }
  .lifestyle-filters button { padding-inline: 13px; font-size: 14px; }
  .lifestyle-card p { font-size: 15px; }
}

@media (max-width: 360px) {
  .lifestyle-gallery { padding-inline: min(var(--gutter, 24px), 18px); }
  .lifestyle-head h2 { font-size: 27px; }
  .lifestyle-stepper { gap: 5px; }
  .lifestyle-enlarge { right: 8px; bottom: 8px; }
}
