/* ЭКОЯР: новая карточка товара (подключается только шаблоном eco_product_full.tpl). */

/* --- крошки: как у kromski — строкой и на телефоне --- */
.breadcrumb.hidden-xs { display: block !important; background: none; padding: 0; margin: 8px 0 20px;
  font: 400 14px/1.6 var(--ey-font-ui); color: var(--ey-color-text-muted); }
.breadcrumb > li + li:before { content: "/\00a0"; color: var(--ey-color-text-muted); padding: 0 4px; }
.breadcrumb a { color: var(--ey-color-text-primary); text-decoration: underline; text-underline-offset: 2px; }
nav.visible-xs > .pager { display: none; }

.eyp { font-family: var(--ey-font-ui); color: var(--ey-color-text-primary); font-size: 16px; line-height: 1.6; padding-bottom: 40px; }
.eyp a { color: var(--ey-color-link); }
.eyp .hidden { display: none !important; }

/* --- верх: галерея + сводка --- */
.eyp-top { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 48px; align-items: start; }
.eyp-gallery { position: relative; min-width: 0; }
.eyp-badges { position: absolute; z-index: 2; top: 10px; left: 10px; }
.eyp-badges:empty { display: none; }

.eyp-main .splide__slide { display: flex; align-items: center; justify-content: center; background: #fff; }
.eyp-main .eyp-slide { display: block; width: 100%; cursor: zoom-in; overflow: hidden; }
.eyp-main img { display: block; width: 100%; height: auto; aspect-ratio: 1 / 1; object-fit: contain; }
.eyp-main video { display: block; width: 100%; aspect-ratio: 1 / 1; object-fit: contain; background: #000; }
.eyp-slide--video { position: relative; }

.eyp-thumbs { margin-top: 4px; }
.eyp-thumbs .splide__slide { aspect-ratio: 1 / 1; cursor: pointer; opacity: 1; background: #fff; }
.eyp-thumbs .splide__slide img { width: 100%; height: 100%; object-fit: cover; display: block; }
.eyp-thumbs.splide--nav > .splide__track > .splide__list > .splide__slide { border: 0; outline: 1px solid transparent; outline-offset: -1px; }
.eyp-thumbs.splide--nav > .splide__track > .splide__list > .splide__slide.is-active { border: 0; outline: 1px solid #bbb; outline-offset: -1px; }
.eyp-thumbs .splide__arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 1; display: flex; align-items: center; justify-content: center;
  width: 1.3em; height: 1.3em; padding: 0; border: 0; border-radius: 0; background: rgba(255, 255, 255, .8); color: #000; opacity: .85; cursor: pointer; font-size: 1rem; }
.eyp-thumbs .splide__arrow svg { width: .8em; height: .8em; fill: currentColor; }
.eyp-thumbs .splide__arrow--prev { left: 0; }
.eyp-thumbs .splide__arrow--prev svg { transform: scaleX(-1); }
.eyp-thumbs .splide__arrow--next { right: 0; }
.eyp-thumbs .splide__arrow:disabled { display: none; }
.eyp-thumb--video { display: flex; align-items: center; justify-content: center; background: #1a1d1a !important; }
.eyp-play { position: absolute; left: 50%; top: 50%; width: 56px; height: 56px; margin: -28px 0 0 -28px; border-radius: 50%;
  background: rgba(0, 0, 0, .55); pointer-events: none; }
.eyp-play:after { content: ""; position: absolute; left: 22px; top: 17px; border-style: solid; border-width: 11px 0 11px 18px; border-color: transparent transparent transparent #fff; }
.eyp-thumb--video .eyp-play { width: 28px; height: 28px; margin: -14px 0 0 -14px; }
.eyp-thumb--video .eyp-play:after { left: 11px; top: 8px; border-width: 6px 0 6px 9px; }

.eyp-summary { min-width: 0; }
.eyp-title { font: 700 34px/1.2 var(--ey-font-heading); margin: 0 0 12px; letter-spacing: -.01em; color: var(--ey-color-text-primary); }
.eyp-line { display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; color: var(--ey-color-text-muted); margin-bottom: 18px; }
.eyp-line__reviews { color: var(--ey-color-text-muted) !important; text-decoration: underline; text-underline-offset: 2px; }
.eyp-intro p { margin: 0 0 14px; }
.eyp-features h4 { font: 700 20px/1.3 var(--ey-font-heading); margin: 22px 0 8px; }
.eyp-features ul { margin: 0 0 18px; padding-left: 20px; }
.eyp-features li { margin: 2px 0; }
.eyp-features li::marker { color: var(--ey-color-accent-gold-strong); }

.eyp-options:empty { display: none; }
.eyp-options { margin: 18px 0 6px; }

.eyp-buy { border-top: 1px solid var(--ey-color-border-default); margin-top: 18px; padding-top: 20px; }
.eyp-price { display: flex; align-items: baseline; gap: 14px; flex-wrap: wrap; }
.eyp-price__new { font: 700 32px/1.1 var(--ey-font-ui); color: var(--ey-color-text-primary); }
.eyp-price__new .rubznak { font-weight: 500; }
.eyp-price__old { font-size: 18px; color: var(--ey-color-text-muted); text-decoration: line-through; }
.eyp-stock { margin: 6px 0 14px; font-size: 14px; color: var(--ey-color-text-muted); }
.eyp-stock:empty { display: none; }

.eyp-cart .addToCart { display: flex !important; gap: 10px; align-items: stretch; width: 100%; margin: 0 0 10px; }
.eyp-cart .addToCart.hide, .eyp-cart .addToCart.hidden { display: none !important; }
.eyp-qty { display: flex !important; width: auto !important; border: 1px solid var(--ey-color-border-default); border-radius: var(--ey-radius-control); overflow: hidden; }
.eyp-qty .btn-number { width: 40px; border: 0; background: #fff; font-size: 20px; line-height: 1; color: var(--ey-color-text-primary); cursor: pointer; }
.eyp-qty .btn-number:hover { background: var(--ey-color-bg-sunk); }
.eyp-qty .input-number { width: 44px; border: 0 !important; box-shadow: none !important; text-align: center; font: 500 16px var(--ey-font-ui); padding: 0; height: 52px; background: #fff; }

.eyp-btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 52px; padding: 0 24px;
  font: 600 16px/1.2 var(--ey-font-ui) !important; border-radius: var(--ey-radius-control); border: 1px solid transparent; cursor: pointer;
  text-decoration: none !important; transition: background .15s, border-color .15s, color .15s, transform .18s cubic-bezier(.2, .6, .2, 1), box-shadow .18s; }
.eyp-btn--primary { flex: 1 1 auto; background: var(--ey-button-primary-bg) !important; color: #fff !important; }
.eyp-btn--primary:hover { background: var(--ey-button-primary-bg-hover) !important; transform: translateY(-1px); box-shadow: 0 6px 16px rgba(0, 96, 48, .18); }
.eyp-btn--primary .icons { display: none; }
.eyp-btn--outline { background: #fff; color: var(--ey-color-action-primary) !important; border-color: var(--ey-color-action-primary); }
.eyp-btn--outline:hover { background: var(--ey-color-bg-sunk); }
.eyp-btn--ghost { background: var(--ey-color-bg-sunk); color: var(--ey-color-text-primary) !important; }
.eyp-b2b { width: 100%; }
.eyp-oneclick:empty { display: none; }
.eyp-oneclick { margin-top: 8px; font-size: 14px; }

.eyp-facts { margin: 22px 0 0; padding: 18px 20px; background: var(--ey-color-bg-sunk); border-radius: var(--ey-radius-card); font-size: 15px; }
.eyp-facts ul { list-style: none; margin: 0; padding: 0; }
.eyp-facts li { position: relative; padding-left: 22px; margin: 4px 0; }
.eyp-facts li:before { content: ""; position: absolute; left: 2px; top: .55em; width: 9px; height: 9px; transform: rotate(45deg);
  background: var(--ey-color-accent-gold-strong); }
.eyp-facts p { margin: 0 0 6px; }

.eyp-meta { margin-top: 18px; font-size: 14px; color: var(--ey-color-text-muted); display: grid; gap: 4px; }

/* --- вкладки (компьютер) / аккордеон (телефон) --- */
.eyp-tabs { margin-top: 56px; }
.eyp-tabs__nav { display: flex; flex-wrap: wrap; gap: 0 32px; border-bottom: 1px solid var(--ey-color-border-default); margin-bottom: 28px; }
.eyp-tabs__nav button { background: none; border: 0; padding: 12px 0; margin-bottom: -1px; border-bottom: 2px solid transparent;
  font: 500 17px/1.3 var(--ey-font-ui); color: var(--ey-color-text-muted); cursor: pointer; }
.eyp-tabs__nav button:hover { color: var(--ey-color-text-primary); }
.eyp-tabs__nav button.is-active { color: var(--ey-color-text-primary); border-bottom-color: var(--ey-color-action-primary); }
.eyp-panel { display: none; }
.eyp-panel.is-open { display: block; }
.eyp-acc { display: none; }
.eyp-panel__body { max-width: 900px; }
.eyp-prose h1, .eyp-prose h2, .eyp-prose h3 { font-family: var(--ey-font-heading); line-height: 1.25; margin: 1.2em 0 .5em; }
.eyp-prose h1 { font-size: 26px; } .eyp-prose h2 { font-size: 24px; } .eyp-prose h3 { font-size: 20px; }
.eyp-prose img { max-width: 100%; height: auto; }
.eyp-prose table { max-width: 100%; }
.eyp-docs { padding-left: 20px; }
.eyp-docs li { margin: 6px 0; }
.eyp-reviews-empty:not([data-count="0"]) { display: none; }
.eyp-reviews-empty { color: var(--ey-color-text-muted); }

/* --- липкая панель «В корзину» (телефон) --- */
.eyp-sticky { display: none; }

@media (max-width: 991px) {
  .eyp-top { gap: 32px; }
  .eyp-title { font-size: 28px; }
}

@media (max-width: 767px) {
  .eyp-top { grid-template-columns: minmax(0, 1fr); gap: 18px; }
  .breadcrumb.hidden-xs { margin: 4px 0 14px; font-size: 13px; }
  .eyp-title { font-size: 26px; margin-bottom: 8px; }
  .eyp-price__new { font-size: 28px; }

  .eyp-tabs { margin-top: 32px; border-top: 1px solid var(--ey-color-border-default); }
  .eyp-tabs__nav { display: none; }
  .eyp-panel, .eyp-panel.is-open { display: block; border-bottom: 1px solid var(--ey-color-border-default); }
  .eyp-panel.hidden { display: none !important; }
  .eyp-acc { display: flex; width: 100%; justify-content: space-between; align-items: center; background: none; border: 0; padding: 16px 0;
    font: 600 17px/1.3 var(--ey-font-ui); color: var(--ey-color-text-primary); text-align: left; cursor: pointer; }
  .eyp-acc:after { content: ""; width: 9px; height: 9px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
    transform: rotate(45deg); margin: -4px 4px 0 12px; transition: transform .2s; flex: none; }
  .eyp-panel.is-open .eyp-acc:after { transform: rotate(-135deg); margin-top: 4px; }
  .eyp-panel__body { display: none; padding-bottom: 18px; }
  .eyp-panel.is-open .eyp-panel__body { display: block; }
  .eyp-prose { overflow-x: auto; }

  .eyp-sticky { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 1029; align-items: center; gap: 12px;
    padding: 10px 14px calc(10px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--ey-color-border-default);
    box-shadow: 0 -4px 16px rgba(0, 0, 0, .06); transform: translateY(110%); transition: transform .2s ease; visibility: hidden; }
  .eyp-sticky.is-visible { transform: none; visibility: visible; }
  .eyp-sticky__info { flex: 1 1 auto; min-width: 0; }
  .eyp-sticky__name { font-size: 13px; color: var(--ey-color-text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .eyp-sticky__price { font: 700 18px/1.2 var(--ey-font-ui); }
  .eyp-sticky__btn { flex: none; min-height: 44px; padding: 0 18px; }
  html.eyp-sticky-on .fabs { bottom: 120px !important; transition: bottom .2s ease; }

  .breadcrumb.hidden-xs { display: flex !important; flex-wrap: nowrap; overflow-x: auto; white-space: nowrap; scrollbar-width: none; }
  .breadcrumb.hidden-xs::-webkit-scrollbar { display: none; }
  .breadcrumb > li { flex: none; }
}

/* --- просмотрщик: тема clean из GLightbox с поправками до вида kromski.com (Kadence «dark») --- */
.glightbox-clean .gslide-description { background: transparent; }
.glightbox-clean .gslide-title { display: none; }
@media (min-width: 769px) {
  .glightbox-container.glightbox-clean .goverlay { background: rgba(0, 0, 0, .75); }
  .glightbox-clean .gclose, .glightbox-clean .gnext, .glightbox-clean .gprev { background-color: rgba(0, 0, 0, .75); }
  .glightbox-clean .gclose:hover, .glightbox-clean .gnext:hover, .glightbox-clean .gprev:hover { background-color: rgba(0, 0, 0, .85); }
}
.glightbox-open .fabs, .glightbox-open .chat, html.eyg-open .fabs, html.eyg-open .chat { display: none !important; }

@media (prefers-reduced-motion: reduce) { .eyp-btn--primary:hover { transform: none; } }


/* --- итерация аудита: иерархия, пустые блоки, mobile-стек --- */
.eyp-tabs__nav button.hidden { display: none !important; }
.eyp-intro:empty { display: none; }
.eyp-subtitle { font-size: 14px; color: var(--ey-color-text-muted); margin: -4px 0 14px; line-height: 1.45; }
.eyp-subtitle:empty { display: none; }
.eyp-specs-from-des:empty { display: none; }
.eyp-specs-from-des table { width: 100%; border-collapse: collapse; margin: 0 0 12px; font-size: 15px; }
.eyp-specs-from-des th, .eyp-specs-from-des td { border-bottom: 1px solid var(--ey-color-border-default); padding: 8px 10px; text-align: left; vertical-align: top; }
.eyp-specs-from-des h3 { font: 700 20px/1.3 var(--ey-font-heading); margin: 0 0 12px; }
.eyp-options .eco-fam__all { margin-top: 8px; }
.eyp-options .eco-fam__all table { font-size: 13px; }

@media (max-width: 767px) {
  .eyp-sticky { z-index: 1030; }
  /* чат над липкой «В корзину», bar-tab на PDP скрываем */
  body:has(.eyp) .navbar-fixed-bottom.bar-tab,
  body:has(.eyp) .bar-padding-fix { display: none !important; }
  html.eyp-sticky-on .ecc-btn { bottom: calc(72px + env(safe-area-inset-bottom, 0px)) !important; }
  html.eyp-sticky-on .ecc-tip { bottom: calc(80px + env(safe-area-inset-bottom, 0px)) !important; }
  html.eyp-sticky-on #chatWidget { bottom: calc(72px + env(safe-area-inset-bottom, 0px)) !important; }
  .eyp { padding-bottom: 24px; }
  html.eyp-sticky-on .eyp { padding-bottom: calc(88px + env(safe-area-inset-bottom, 0px)); }
}

/* заголовок секции уже есть у вкладки/аккордеона */
.eyp-specs-from-des > h3.eco-sec { display: none; }


/* PhotoSwipe (матовое стекло) на .eyp — стили в eco-gallery.css */
.eyp-gallery { position: relative; }
.eyp-main .eyp-slide.eyg-zoom { cursor: zoom-in; }
.eyp-gallery .eyg-share-btn { top: 12px; right: 12px; }
html.eyg-open .fabs, html.eyg-open .ecc-btn, html.eyg-open .ecc-tip, html.eyg-open .eyp-sticky { display: none !important; }


/* видео-вкладка (как в native eco-buy) */
.eyp .eyb-vid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(320px, 100%), 1fr)); gap: 16px; padding: 6px 0; }
.eyp .eyb-v { margin: 0; }
.eyp .eyb-v-play, .eyp .eyb-v-frame {
  position: relative; display: block; width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 12px; overflow: hidden;
  background: #1a1d1a center/cover no-repeat;
}
.eyp .eyb-v-play { cursor: pointer; }
.eyp .eyb-v-play::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,0) 50%, rgba(0,0,0,.35)); }
.eyp .eyb-v-play i {
  position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%;
  background: rgba(255,255,255,.92); box-shadow: 0 6px 20px rgba(0,0,0,.25); transition: transform .15s;
}
.eyp .eyb-v-play i::after { content: ""; position: absolute; left: 26px; top: 20px; border-style: solid; border-width: 12px 0 12px 20px; border-color: transparent transparent transparent #00753B; }
.eyp .eyb-v-play:hover i { transform: scale(1.08); }
.eyp .eyb-v-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.eyp .eyb-v figcaption { margin-top: 8px; font-size: 14px; line-height: 1.35; color: var(--ey-color-text-muted, #444); }
.eyp-reviews-empty { display: none !important; }

/* marketplace reviews pilot */
.eyp-mp-reviews { margin: 0 0 1.25rem; padding-bottom: 1rem; border-bottom: 1px solid rgba(0,0,0,.08); }
.eyp-mp-title { margin: 0 0 .5rem; font-size: 1.05rem; font-weight: 600; }
.eyp-mp-note { margin: 0 0 .85rem; font-size: .85rem; color: #666; font-style: italic; }
.eyp-mp-item { margin: 0 0 1rem; padding: .85rem 0 0; border-top: 1px solid rgba(0,0,0,.06); }
.eyp-mp-item:first-of-type { border-top: 0; padding-top: 0; }
.eyp-mp-item__head { display: flex; flex-wrap: wrap; align-items: center; gap: .4rem .7rem; margin-bottom: .4rem; }
.eyp-mp-badge { display: inline-block; padding: .15rem .5rem; font-size: .72rem; font-weight: 700; letter-spacing: .02em; text-transform: uppercase; border-radius: 3px; color: #fff; background: #7b2d8e; }
.eyp-mp-badge--wildberries { background: #7b2d8e; }
.eyp-mp-badge--ozon { background: #005bff; }
.eyp-mp-stars { color: #e6a800; letter-spacing: .05em; font-size: .95rem; }
.eyp-mp-meta { color: #777; font-size: .85rem; }
.eyp-mp-text { margin: .35rem 0 .55rem; line-height: 1.45; white-space: pre-wrap; }
.eyp-mp-media { display: flex; flex-wrap: wrap; gap: .45rem; }
.eyp-mp-photo img, .eyp-mp-video img { display: block; width: 88px; height: 88px; object-fit: cover; border-radius: 4px; background: #eee; }
.eyp-mp-video { position: relative; display: inline-block; }
.eyp-mp-video__badge { position: absolute; left: 4px; bottom: 4px; padding: 1px 5px; font-size: .65rem; font-weight: 700; color: #fff; background: rgba(0,0,0,.65); border-radius: 2px; }

.eyp-mp-answer {
  margin: .65rem 0 0;
  padding: .65rem .85rem;
  background: rgba(0,0,0,.035);
  border-left: 3px solid #2f6b4f;
  border-radius: 0 4px 4px 0;
}
.eyp-mp-answer__label {
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .03em;
  text-transform: uppercase;
  color: #2f6b4f;
  margin: 0 0 .3rem;
}
.eyp-mp-answer__text {
  margin: 0;
  line-height: 1.45;
  font-size: .92rem;
  color: #333;
  white-space: pre-wrap;
}
