/* overrides.css — сюда добавляй стили для перезаписи */

.sections__container-bg .section-bg-picture {
    position: absolute;
    inset: 0;
    min-width: 0;
    min-height: 0;
    display: block;
    width: 100%;
    height: 100%;
}

.sections__container-bg .section-bg-picture img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

#start .section__row-container .flex-row-picture,
#start .section__column-container.mob .flex-row-picture {
    display: contents;
}

#reg .section__image-container .reg-split-picture {
    display: flex;
    width: 100%;
    max-width: 100%;
    align-items: center;
    justify-content: center;
}

#reg .section__image-container .reg-split-picture .section__image {
    width: 100%;
    height: auto;
    max-width: 100%;
    display: block;
}

@media screen and (max-width: 768px) {
    #start .section__image-container>picture .section__image {
        max-width: 300px;
        max-height: 300px;
        margin-inline: auto;
    }
}

/* SEOX-2275: colors per Figma макет — brand blue #3C549D (highlight),
   gold CTA gradient (token primary/orange_lin: #fdca6b -> #ffdeaa) with dark text. */
.selected {
    color: #3C549D;
}

.big-button {
    background: linear-gradient(to left, #fdca6b 0%, #ffdeaa 100%);
    color: #28261b;
}

h1 .selected {
    text-transform: uppercase;
}

.section__delivery {
    background: #D5D4D4;
}

/* SEOX-2275: content table provides 3 ingredients; hide empty right composition column.
   Layout (reviewer point 2): bottle image on TOP, the 3 ingredient cards in a
   horizontal row below. */
#composition .section__row-container > .section__column-container:last-child { display: none; }
#composition .section__row-container {
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    gap: 36px;
}
/* bottle image — top, centered, in normal flow (not absolute) */
#composition .section__image-container-center {
    order: -1;
    width: 100%;
    display: flex;
    justify-content: center;
}
#composition .section__image-container-center img {
    position: static;
    inset: auto;
    margin: 0;
    max-height: 440px;
    max-width: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
}
/* 3 ingredient cards in a row — CSS grid, equal thirds (no flex-grow) */
#composition .section__row-container > .section__column-container:first-child {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    width: 100%;
    max-width: none;
}
#composition .section__row-container > .section__column-container:first-child .section__card { width: auto; }
#composition .section__row-container > .section__column-container:first-child .small { max-width: none; }
@media (max-width: 767px) {
    #composition .section__row-container > .section__column-container:first-child { grid-template-columns: 1fr; }
    #composition .section__image-container-center img { max-height: 340px; }
}

/* === Hero (start) fix — stock single-2 bug: scene image went full width, form dropped under it.
   Restore "image | form" row on desktop; constrain image on tablet. === */
@media screen and (min-width: 481px) {
  #start .section__image.desk { width: 100%; height: 100%; object-fit: cover; object-position: center; border-radius: 16px; max-height: 100%; }
}
/* single-2 widens the hero content row only at >=1280 (at 1200 the row is just ~622px wide,
   so the fixed ~564px form squeezes the flex:1 picture to ~42px). So: side-by-side only at
   >=1280; below that STACK (picture full-width centered, form below) — no collapse at 770-1279. */
@media screen and (min-width: 1280px) {
  #start .section__container > .section__column-container > .section__row-container:nth-child(2) { flex-wrap: nowrap; align-items: stretch; }
  #start .section__container > .section__column-container > .section__row-container:nth-child(2) > picture { flex: 1 1 0; min-width: 340px; align-self: stretch; display: flex; overflow: hidden; border-radius: 16px; }
}
@media screen and (min-width: 481px) and (max-width: 1279px) {
  #start .section__container > .section__column-container > .section__row-container:nth-child(2) { flex-wrap: wrap; }
  #start .section__container > .section__column-container > .section__row-container:nth-child(2) > picture { flex: 0 0 100%; width: 100%; max-width: 520px; margin-inline: auto; display: flex; overflow: hidden; border-radius: 16px; }
}

/* === Reg (final) fix — stock single-2 bug: two bottles (bg + foreground). Keep one on a light card. === */
#reg .section__image-container { background-image: none; background-color: #e9eef5; }
/* reg image: width auto + allow shrink to fit the card (user request) */
#reg .section__image { width: auto; flex-shrink: 1; }

/* Header logo: keep aspect ratio (don't stretch to width=120 attribute) */
.header__logo { width: auto; }

/* === Certificate (solutions): image width 100% on ALL viewports (fills its container) === */
#solutions .section__column-container--relative .section__image { width: 100% !important; height: auto !important; max-width: none !important; margin-inline: auto; display: block; }
/* tablet & mobile (<=1024 covers iPad ~810-834): stack columns so the cert spans the full page width */
@media (max-width: 1024px) {
  #solutions .section__row-container--dark { flex-wrap: wrap; }
  #solutions .section__row-container--dark > .section__column-container { width: 100%; }
}
/* "Ver certificado oficial" button — left side (in the text column), per mockup */
.cert-button { display: inline-flex; align-items: center; justify-content: center; margin-top: 20px; align-self: flex-start; }
@media (max-width: 768px) {
  .cert-button { display: flex; width: 100%; max-width: 360px; }
}

/* === Reviews: round avatars (no squish/stretch) + author block aligned left === */
#review .section__card .section__row-container img[src*="eroprost-review-photo"] { flex-shrink: 0; width: 56px !important; height: 56px !important; border-radius: 50%; object-fit: cover; }
#review .section__card .section__row-container.center { justify-content: flex-start; text-align: left; }

/* === #tips: content table has 6 precautions (5 & 6 had empty key cells, so the builder
   rendered only 4). We add cards 5 & 6, so let the cards row wrap into a grid (3 per row). === */
#tips .section__row-container--nowrap { flex-wrap: wrap; align-items: stretch; }
#tips .section__row-container--nowrap > .section__item { flex: 1 1 30%; min-width: 240px; }
/* shorter cards: drop the 390px min-height + the space-between gap; pack content at top (per mockup) */
#tips .section__item--card-grey { min-height: auto !important; justify-content: flex-start; gap: 12px; padding: 20px; }
/* single-2 makes the LAST tip card's text white (it was the overlay/image card). Now it's a plain
   grey card -> white on grey is invisible. Force dark text on all grey precaution cards. */
#tips .section__item--card-grey p { color: #444a49 !important; }

/* ============================================================================
   SEOX-2275 review round 2 (reviewer Anastasiya M, по Figma макету)
   ============================================================================ */

/* --- Point 3: trust bar under header + duplicated before order block --------
   NB: bundle.css has `ul[class],ol[class]{padding:0}` (specificity 0,1,1) which
   beats a bare `.trust-bar__list` (0,1,0) and zeroed the vertical padding (bar
   looked cramped). Scope under `.trust-bar` (0,2,0) so the padding actually wins. */
.trust-bar { background: #3C549D; }
.trust-bar .trust-bar__list {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px 24px;
    margin: 0;
    padding: 18px 0;
    list-style: none;
}
.trust-bar__item {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1 1 auto;
    justify-content: center;
    color: #fff;
    font-weight: 600;
    font-size: 16px;
    line-height: 1.2;
}
.trust-bar__icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #fff;
    flex-shrink: 0;
}
.trust-bar__icon svg { width: 22px; height: 22px; }
@media (max-width: 768px) {
    .trust-bar .trust-bar__list { gap: 12px 16px; padding: 14px 0; }
    .trust-bar__item { flex: 1 1 42%; justify-content: flex-start; font-size: 13px; gap: 10px; }
    .trust-bar__icon { width: 34px; height: 34px; }
    .trust-bar__icon svg { width: 18px; height: 18px; }
}

/* --- Point 3: hero rating + intro column (rating above promo, top-aligned to
   the right of the h1, per Figma макет). Stock single-2 hero row centers items
   vertically (align-items: stretch/normal) which floated the rating in the middle;
   top-align the row and group rating+promo into one right column. --- */
#start .section__container > .section__column-container > .section__row-container:first-child {
    align-items: flex-start;
}
.hero-intro {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 14px;
    /* Behaves exactly like the stock single-2 h1/promo: max-width 566 with the
       default flex (0 1 auto, shrinkable) so it sits next to the h1 and never
       grows wider/sticks out. NO flex-grow — that breaks the lander. */
    max-width: 566px;
}
.hero-intro > p { margin: 0; }
.hero-rating {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
}
.hero-rating__score { font-weight: 800; font-size: 20px; color: #28261b; }
.hero-rating__stars { width: 116px; height: 19px; flex-shrink: 0; }
.hero-rating__text { color: #5c5a52; font-size: 15px; }

/* (composition layout handled above — bottle on top, 3 cards in a row) */

/* --- Point 1: review cards must always contain the author block (no overflow) --- */
#review .tns-item { height: auto !important; }
#review .section__card.large { height: auto !important; padding-bottom: 28px; }
