/* =====================================================================
 *  «Знахідка» — доповнення до стилів шаблону.
 *  Тут ЛИШЕ те, чого не було у вихідній верстці (нові компоненти
 *  бекенду). Оригінальні стилі шаблону не перевизначаються.
 * ===================================================================== */

/* =====================================================================
 *  1. КАРТКА ТОВАРУ — однакова висота в ряду
 * ===================================================================== */
.tf-grid-layout > .card-product,
.swiper-slide > .card-product {
    display: flex;
    flex-direction: column;
    height: 100%;
}
.card-product .card-product-wrapper {
    flex-shrink: 0;
}
/* усі фото одного формату — головна причина «стрибків» висоти */
.card-product .card-product-wrapper .image-wrap {
    display: block;
    position: relative;
    aspect-ratio: 4 / 5;
    overflow: hidden;
}
.card-product .card-product-wrapper .image-wrap img,
.card-product .card-product-wrapper .image-wrap picture {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}
.card-product .card-product-info {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    gap: 6px;
}
/* назва — рівно два рядки в усіх картках */
.card-product .card-product-info > .title {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 2.7em;
}
/* характеристики займають вільне місце, ціна й кнопка притискаються донизу */
.card-product .card-product-info .tovarFilters {
    flex: 1 1 auto;
}
.card-product .card-product-info .price {
    margin-top: auto;
}
.card-product .card-product-info .btn-main-product {
    margin-top: 8px;
}
@supports not (aspect-ratio: 4 / 5) {
    .card-product .card-product-wrapper .image-wrap { padding-top: 125%; }
    .card-product .card-product-wrapper .image-wrap img { position: absolute; inset: 0; }
}

/* ціна зі знижкою */
.card-product .price .old-price {
    text-decoration: line-through;
    color: #9aa3b0;
    margin-right: 8px;
    font-weight: 400;
}
.card-product .price .new-price { font-weight: 600; }

/* товар без наявності */
.product-out-stock .card-product-wrapper { opacity: .5; }
.product-out-stock .card-product-info > .title { color: #8b8b8b; }
.on-sale-item.pNOut { background: #8a8a8a; color: #fff; }
.btn-main-product.btnCartOut { opacity: .75; }

/* =====================================================================
 *  2. КАТАЛОГ
 * ===================================================================== */
.wrapper-control-shop { position: relative; }
.catalog-loader {
    position: absolute; inset: 0; z-index: 5;
    display: flex; align-items: center; justify-content: center;
    background: rgba(255, 255, 255, .7);
}
.catalog-loader .spinner {
    width: 38px; height: 38px;
    border: 3px solid #e5e5e5; border-top-color: #181818;
    border-radius: 50%; animation: znSpin .8s linear infinite;
}
@keyframes znSpin { to { transform: rotate(360deg); } }
.js-catalog-grid.is-loading { opacity: .45; pointer-events: none; transition: opacity .2s; }

.catalog-empty, .cart-empty-page {
    grid-column: 1 / -1;
    text-align: center;
    padding: 56px 20px;
}
.catalog-empty .empty-icon,
.cart-empty-page .empty-icon,
.tf-mini-cart-empty .empty-icon {
    font-size: 52px; color: #d5d5d5; margin-bottom: 14px; line-height: 1;
}
.catalog-empty h5, .cart-empty-page h4 { margin-bottom: 8px; }
.catalog-empty p, .cart-empty-page p { margin-bottom: 20px; color: #777; }

.facet-disabled { opacity: .45; }
.facet-color {
    display: inline-block; width: 14px; height: 14px;
    border-radius: 50%; border: 1px solid #ddd;
    margin-right: 6px; vertical-align: -2px;
}
.filter-badge {
    display: inline-block; width: 8px; height: 8px;
    border-radius: 50%; background: #d93025; margin-left: 6px; vertical-align: 2px;
}
.category-description { font-size: 15px; line-height: 1.7; }
.category-description-bottom { border-top: 1px solid var(--line, #e5e5e5); padding-top: 24px; }
.pagination-dots { opacity: .5; cursor: default; }
.meta-filter-shop { margin-bottom: 14px; }
.count-text { font-size: 14px; color: #777; }

/* =====================================================================
 *  3. ЖИВИЙ ПОШУК
 * ===================================================================== */
.search-suggestions {
    margin-top: 12px; max-height: 60vh; overflow-y: auto;
    border-radius: 8px; background: #fff; border: 1px solid #eee;
}
.ss-block { padding: 10px 14px; border-bottom: 1px solid #f2f2f2; }
.ss-block:last-child { border-bottom: 0; }
.ss-title {
    font-size: 12px; letter-spacing: .06em; text-transform: uppercase;
    color: #999; margin-bottom: 8px;
}
.ss-cat {
    display: inline-block; padding: 6px 12px; margin: 0 6px 6px 0;
    border: 1px solid #e5e5e5; border-radius: 20px; font-size: 13px; transition: .2s;
}
.ss-cat:hover { background: #181818; color: #fff; border-color: #181818; }
.ss-cat span { color: #999; font-size: 12px; }
.ss-cat:hover span { color: #ddd; }
.ss-item { display: flex; align-items: center; gap: 12px; padding: 8px 0; transition: .2s; }
.ss-item:hover { background: #fafafa; }
.ss-img {
    flex: 0 0 52px; width: 52px; height: 62px;
    overflow: hidden; border-radius: 6px; background: #f6f6f6;
}
.ss-img img { width: 100%; height: 100%; object-fit: cover; }
.ss-info { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.ss-name {
    font-size: 14px; line-height: 1.35; overflow: hidden;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.ss-price { font-size: 14px; font-weight: 600; }
.ss-price s { color: #aaa; font-weight: 400; margin-right: 6px; }
.ss-more {
    display: block; padding: 12px 14px; text-align: center;
    font-size: 14px; font-weight: 600; background: #f7f7f7;
}
.ss-more:hover { background: #181818; color: #fff; }
.ss-empty { padding: 20px 14px; text-align: center; color: #888; font-size: 14px; }
.search-page-form { display: flex; gap: 12px; max-width: 620px; align-items: stretch; }
.search-page-form .text { flex: 1; }
.search-cat-list { display: flex; flex-wrap: wrap; gap: 8px; }
.search-cat-item {
    padding: 8px 16px; border: 1px solid #e5e5e5;
    border-radius: 24px; font-size: 14px; transition: .2s;
}
.search-cat-item:hover { background: #181818; color: #fff; border-color: #181818; }
.search-cat-item span { color: #999; }

/* =====================================================================
 *  4. КОШИК
 * ===================================================================== */
.tf-mini-cart-empty { text-align: center; padding: 56px 24px; }
.tf-mini-cart-empty h6 { margin-bottom: 6px; }
.tf-mini-cart-empty p { color: #888; margin-bottom: 20px; font-size: 14px; }
.cart-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.tf-cart-item .old-price { text-decoration: line-through; color: #aaa; margin-right: 6px; }
.js-cart-remove { cursor: pointer; }

/* =====================================================================
 *  5. ФОРМИ ТА ПОВІДОМЛЕННЯ
 * ===================================================================== */
.field-wrap { position: relative; display: flex; flex-direction: column; }
.field-error {
    display: block; color: #d93025; font-size: 12px;
    line-height: 1.4; margin-top: 4px;
}
.field-error:empty { display: none; }
input.is-invalid, textarea.is-invalid, select.is-invalid { border-color: #d93025 !important; }

.alert-msg { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px; }
.alert-success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.alert-error   { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* повідомлення підписки — у футері темний фон */
footer .subscribe-msg { margin-top: 8px; font-size: 13px; }
footer .subscribe-msg.is-success { color: #6ee7a8; }
footer .subscribe-msg.is-error   { color: #fca5a5; }
footer .field-error { color: #fca5a5; }

.checkout-trust {
    display: flex; flex-direction: column; gap: 10px;
    padding-top: 18px; border-top: 1px solid var(--line, #e5e5e5);
}
.trust-item { display: flex; align-items: center; gap: 10px; font-size: 14px; color: #555; }
.trust-item i { font-size: 20px; }

.is-loading { position: relative; pointer-events: none; opacity: .75; }
.is-loading::after {
    content: ""; position: absolute; top: 50%; right: 14px;
    width: 15px; height: 15px; margin-top: -7.5px;
    border: 2px solid rgba(255, 255, 255, .4); border-top-color: #fff;
    border-radius: 50%; animation: znSpin .7s linear infinite;
}
.btn-white.is-loading::after,
.tf-btn.btn-white.is-loading::after { border-color: rgba(0,0,0,.2); border-top-color: #181818; }

.form-contact .grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-bottom: 14px; }
.form-contact .field-wrap { margin-bottom: 14px; }
.form-contact textarea,
.tf-page-checkout textarea {
    width: 100%; min-height: 100px; padding: 12px 16px;
    border: 1px solid var(--line, #e5e5e5); border-radius: 8px;
    font-family: inherit; font-size: 14px; resize: vertical;
}
@media (max-width: 575px) { .form-contact .grid-2 { grid-template-columns: 1fr; } }

/* =====================================================================
 *  6. TOAST
 * ===================================================================== */
.zn-toast-wrap {
    position: fixed; right: 20px; bottom: 20px; z-index: 99999;
    display: flex; flex-direction: column; gap: 10px; pointer-events: none;
}
.zn-toast {
    display: flex; align-items: center; gap: 10px;
    min-width: 260px; max-width: 360px; padding: 14px 18px;
    border-radius: 10px; background: #181818; color: #fff;
    font-size: 14px; line-height: 1.4;
    box-shadow: 0 10px 30px rgba(0,0,0,.18);
    transform: translateY(16px); opacity: 0;
    transition: transform .3s cubic-bezier(.2,.8,.3,1), opacity .3s;
    pointer-events: auto;
}
.zn-toast.show { transform: translateY(0); opacity: 1; }
.zn-toast-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 22px; height: 22px; min-width: 22px; border-radius: 50%;
    background: #2cb769; color: #fff; font-size: 13px; font-weight: 700;
}
.zn-toast-error { background: #7f1d1d; }
.zn-toast-error .zn-toast-icon { background: #ef4444; }
@media (max-width: 575px) {
    .zn-toast-wrap { right: 12px; left: 12px; bottom: 80px; }
    .zn-toast { min-width: 0; max-width: none; }
}

/* =====================================================================
 *  7. COOKIE — оформлення береться зі stylev2.css шаблону (темна панель).
 *     Тут лише поведінка приховування та відступ під мобільну панель.
 * ===================================================================== */
.cookie-bar.hide { transform: translateY(100%); transition: transform .4s ease; }
@media (max-width: 767px) { .cookie-bar { bottom: 60px; } }

/* =====================================================================
 *  8. МОДАЛКА УСПІШНОГО ЗАМОВЛЕННЯ
 * ===================================================================== */
.modal-order-success .modal-dialog { max-width: 560px; }
.modal-order-success .modal-content { border-radius: 14px; padding: 0; border: 0; }
.order-success-inner { position: relative; padding: 38px 34px 32px; text-align: center; }
.order-success-inner .icon-close-popup {
    position: absolute; top: 16px; right: 18px; cursor: pointer; font-size: 16px;
}
.order-success-icon { color: #2cb769; margin-bottom: 16px; }
.order-success-icon .oschk {
    stroke-dasharray: 48; stroke-dashoffset: 48;
    animation: osDraw .6s .15s ease forwards;
}
@keyframes osDraw { to { stroke-dashoffset: 0; } }
.order-success-title { margin-bottom: 8px; }
.order-success-sub { color: #666; font-size: 14px; line-height: 1.6; margin-bottom: 22px; }
.order-success-box {
    text-align: left; background: #f8f8f8; border-radius: 10px;
    padding: 16px 18px; margin-bottom: 18px;
}
.osb-row { display: flex; justify-content: space-between; gap: 14px; padding: 5px 0; font-size: 14px; }
.osb-row span { color: #888; flex-shrink: 0; }
.osb-row b { text-align: right; }
.order-success-items { text-align: left; max-height: 210px; overflow-y: auto; margin-bottom: 16px; }
.osi-row { display: flex; align-items: center; gap: 12px; padding: 9px 0; border-bottom: 1px solid #f0f0f0; }
.osi-row:last-child { border-bottom: 0; }
.osi-img { flex: 0 0 44px; width: 44px; height: 54px; border-radius: 6px; overflow: hidden; background: #f4f4f4; }
.osi-img img { width: 100%; height: 100%; object-fit: cover; }
.osi-info { flex: 1; min-width: 0; }
.osi-name {
    font-size: 14px; line-height: 1.35; overflow: hidden;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.osi-qty { font-size: 12px; color: #999; margin-top: 2px; }
.osi-total { font-weight: 600; font-size: 14px; white-space: nowrap; }
.order-success-total {
    display: flex; justify-content: space-between; align-items: center;
    padding: 14px 0; border-top: 2px solid #181818; font-size: 17px; margin-bottom: 16px;
}
.order-success-total b { font-size: 21px; }
.order-success-help { font-size: 13px; color: #777; margin-bottom: 18px; }
.order-success-help a { font-weight: 600; text-decoration: underline; }
.order-success-actions { display: flex; gap: 10px; flex-direction: column; }
.order-success-static { max-width: 600px; margin: 0 auto; border: 1px solid #eee; border-radius: 14px; }
@media (max-width: 575px) { .order-success-inner { padding: 30px 20px 24px; } }

/* =====================================================================
 *  9. ОСОБИСТИЙ КАБІНЕТ
 * ===================================================================== */
.account-initials {
    display: flex; align-items: center; justify-content: center;
    width: 84px; height: 84px; border-radius: 50%;
    background: #181818; color: #fff; font-size: 30px; font-weight: 600;
    margin: 0 auto 12px;
}
.order-status-badge {
    display: inline-block; padding: 4px 12px; border-radius: 20px;
    color: #fff; font-size: 12px; font-weight: 600; white-space: nowrap;
}
.order-detail-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.order-detail-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 16px; margin-top: 18px;
}
.odg-box { background: #f8f8f8; border-radius: 10px; padding: 16px 18px; }
.odg-box h6 {
    margin-bottom: 8px; font-size: 13px; text-transform: uppercase;
    letter-spacing: .04em; color: #888;
}
.odg-box p { font-size: 14px; margin: 2px 0; }
.order-item-cell { display: flex; align-items: center; gap: 12px; }
.oic-img { flex: 0 0 46px; width: 46px; height: 56px; border-radius: 6px; overflow: hidden; background: #f4f4f4; }
.oic-img img { width: 100%; height: 100%; object-fit: cover; }
.order-detail-total { margin-top: 18px; border-top: 1px solid #eee; padding-top: 14px; }
.odt-row { display: flex; justify-content: space-between; padding: 5px 0; font-size: 15px; }
.odt-final { font-size: 19px; font-weight: 600; border-top: 2px solid #181818; margin-top: 8px; padding-top: 12px; }
.order-history { list-style: none; padding: 0; margin: 0; }
.order-history li {
    display: flex; gap: 12px; padding: 10px 0;
    border-left: 2px solid #eee; padding-left: 16px; margin-left: 5px; position: relative;
}
.oh-dot { position: absolute; left: -7px; top: 14px; width: 12px; height: 12px; border-radius: 50%; border: 2px solid #fff; }
.order-history b { display: block; font-size: 14px; }
.order-history .text-secondary { font-size: 12px; color: #999; }
.btn-sm { padding: 7px 16px; font-size: 13px; }

/* =====================================================================
 * 10. ТЕКСТОВІ СТОРІНКИ ТА ТОВАР
 *     Використовуються класи шаблону .polNew — тут лише доповнення.
 * ===================================================================== */
.polNew img { max-width: 100%; height: auto; border-radius: 8px; }
.polNew table { width: 100%; border-collapse: collapse; margin: 20px 0; border: 1px solid #ccc; }
.polNew th, .polNew td { border: 1px solid #e5e5e5; padding: 10px 14px; text-align: left; }
.polNew th { background: #f8f8f8; font-weight: 600; }
.polNew a { text-decoration: underline; }
.polNew h3 { font-size: clamp(16px, 1.6vw, 20px); font-weight: 600; margin-top: 18px; margin-bottom: 8px; }
.polNew ol li { list-style: decimal; }
.polNew li { margin-bottom: 6px; }

.product-description-content ul, .product-description-content ol { padding-left: 20px; margin-bottom: 14px; }
.product-description-content li { list-style: initial; margin-bottom: 6px; }
.product-attributes-table { width: 100%; border-collapse: collapse; }
.product-attributes-table td { padding: 11px 14px; border-bottom: 1px solid #eee; font-size: 14px; }
.product-attributes-table .attr-name { color: #888; width: 40%; }
.product-attributes-table .attr-value { font-weight: 500; }
.product-unavailable { background: #fef2f2; border: 1px solid #fecaca; border-radius: 10px; padding: 18px; }

.faqs-contact-box { background: #f8f8f8; border-radius: 12px; padding: 26px 24px; text-align: center; margin-top: 26px; }
.faqs-contact-box h5 { margin-bottom: 8px; }
.faqs-contact-box p { color: #777; margin-bottom: 16px; }
.faqs-contact-box .tf-btn { margin: 4px; display: inline-flex; }

.page404 { text-align: center; padding: 70px 20px; }
.page404 > div:first-child { font-size: 110px; font-weight: 700; line-height: 1; opacity: .12; }
.page404 h1 { margin: 14px 0 8px; }
.page404 p { color: #777; margin-bottom: 24px; }
.page404-actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-bottom: 28px; }
.page404-search { display: flex; gap: 10px; max-width: 440px; margin: 0 auto; }
.page404-search .text { flex: 1; }

.footer-legal { font-size: 12px; opacity: .7; }
.tf-social-icon.type-3 { display: flex; gap: 10px; list-style: none; padding: 0; }
.tf-social-icon.type-3 a {
    display: flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; border: 1px solid #e5e5e5; border-radius: 50%; transition: .2s;
}
.tf-social-icon.type-3 a:hover { background: #181818; color: #fff; border-color: #181818; }

/* службові відступи */
.mt_15 { margin-top: 15px; } .mt_20 { margin-top: 20px; } .mt_25 { margin-top: 25px; }
.mt_30 { margin-top: 30px; } .mt_40 { margin-top: 40px; }
.pt_15 { padding-top: 15px; } .pb_10 { padding-bottom: 10px; } .mb_15 { margin-bottom: 15px; }

/* =====================================================================
 * 11. ЗАГОЛОВКИ СЕКЦІЙ
 *     У шаблоні секції мали <h3>. Для SEO використовуємо <h2>,
 *     тому вирівнюємо його розмір під h3 шаблону.
 * ===================================================================== */
.heading-section h2,
.page-faqs-wrap h2 { font-size: 40px; line-height: 48px; }
@media (max-width: 1024px) {
    .heading-section h2,
    .page-faqs-wrap h2 { font-size: 24px; line-height: 34px; }
}

/* =====================================================================
 * 12. ВИПРАВЛЕННЯ ПОВЕДІНКИ КАРТКИ
 * ===================================================================== */

/* Якщо у товару лише одне фото — при наведенні воно не має зникати.
   У шаблоні .img-product гаситься завжди, розраховуючи на .img-hover. */
.card-product .card-product-wrapper .image-wrap:not(:has(.img-hover)):hover .img-product,
.card-product .card-product-wrapper:hover .image-wrap:not(:has(.img-hover)) .img-product {
    opacity: 1;
}
/* запасний варіант для браузерів без :has() — клас ставить бекенд */
.card-product.single-photo .card-product-wrapper:hover .image-wrap .img-product { opacity: 1; }

/* =====================================================================
 * 13. МОБІЛЬНА СІТКА — щоб дві картки гарантовано вміщались
 * ===================================================================== */
@media (max-width: 767px) {
    .tf-grid-layout.tf-col-2 { gap: 10px; }
    .card-product .card-product-info { gap: 4px; }
    .card-product .card-product-info > .title { font-size: 13px; line-height: 1.35; min-height: 2.7em; }
    .card-product .tovarFilters span { font-size: 11px; }
    .card-product .price { font-size: 15px; }
    .card-product .price .old-price { font-size: 13px; margin-right: 5px; }
    .card-product .btn-main-product {
        height: 38px; font-size: 11px; padding: 0 8px; letter-spacing: .02em;
    }
    .card-product .on-sale-wrap { gap: 4px; }
    .card-product .on-sale-item { font-size: 10px; padding: 2px 7px; }
    .pINWish a { width: 30px; height: 30px; font-size: 15px; }
}
@media (max-width: 400px) {
    .tf-grid-layout.tf-col-2 { gap: 8px; }
    .card-product .btn-main-product { font-size: 10px; height: 36px; }
    .card-product .card-product-info > .title { font-size: 12.5px; }
}

/* =====================================================================
 * 14. ТЕКСТОВІ СТОРІНКИ — рівні відступи (без зайвого зсуву зліва)
 * ===================================================================== */
.page-text-wrap { max-width: 900px; margin: 0 auto; width: 100%; }
.polNew > *:first-child { margin-top: 0; }
.polNew h2:first-of-type { margin-top: 0; }

/* =====================================================================
 * 15. ПІДПИСКА — помилка не зсуває кнопку
 * ===================================================================== */
footer .form-newsletter { position: relative; }
footer .subscribe-content { position: relative; }
footer .form-newsletter .field-error,
footer .form-newsletter .subscribe-msg {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin-top: 6px;
    font-size: 12.5px;
    line-height: 1.4;
    pointer-events: none;
}
footer .form-newsletter .subscribe-msg { pointer-events: auto; }

/* =====================================================================
 * 16. СТОРІНКА ТОВАРУ — кількість, кошик і сердечко в одному рядку
 * ===================================================================== */
.zn-buy-row {
    display: flex;
    align-items: flex-end;
    gap: 12px;
    flex-wrap: nowrap;
}
.zn-buy-row .tf-product-info-quantity { flex: 0 0 auto; margin: 0; }
.zn-buy-row .tf-product-info-quantity .title { white-space: nowrap; }
.zn-buy-row .wg-quantity { width: 130px; }
.zn-buy-row .zn-add-btn { flex: 1 1 auto; min-width: 0; }
.zn-buy-row .box-icon {
    flex: 0 0 auto;
    width: 52px; height: 52px;
    display: flex; align-items: center; justify-content: center;
    border: 1px solid var(--line, #e5e5e5); border-radius: 50%;
    transition: .2s;
}
.zn-buy-row .box-icon:hover,
.zn-buy-row .box-icon.active { background: #181818; color: #fff; border-color: #181818; }
.zn-buy-now { margin-top: 12px; }

/* мобільна розкладка ряду описана нижче, у розділі 31 */

/* =====================================================================
 * 17. ОФОРМЛЕННЯ ЗАМОВЛЕННЯ — кількість і видалення позиції
 * ===================================================================== */
.zn-qty-sm { width: 108px; margin-top: 8px; }
.zn-qty-sm .quantity-product { font-size: 14px; }
.zn-qty-sm .btn-quantity { font-size: 15px; }
.item-product .content-box { align-items: flex-start; }
.zn-item-right {
    display: flex; flex-direction: column; align-items: flex-end;
    gap: 10px; flex-shrink: 0;
}
.zn-item-remove {
    background: none; border: 0; padding: 4px; cursor: pointer;
    color: #9aa3b0; font-size: 13px; line-height: 1; transition: .2s;
}
.zn-item-remove:hover { color: #d93025; }

/* =====================================================================
 * 18. КАПЧА
 * ===================================================================== */
.zn-captcha { margin-bottom: 4px; }
.zn-captcha-label { display: block; margin-bottom: 8px; font-size: 14px; }
.zn-captcha-label b {
    display: inline-block; padding: 2px 10px; margin: 0 2px;
    background: #f1f3f5; border-radius: 6px; letter-spacing: .04em;
}
.zn-captcha-input { max-width: 220px; }

/* =====================================================================
 * 19. ХЛІБНІ КРИХТИ НА ТОВАРІ
 * ===================================================================== */
.tf-breadcrumb-list { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.tf-breadcrumb-list .icon { font-size: 10px; opacity: .5; }

/* =====================================================================
 * 20. TOAST — знизу по центру
 * ===================================================================== */
.zn-toast-wrap {
    right: auto;
    left: 50%;
    bottom: 26px;
    transform: translateX(-50%);
    align-items: center;
}
.zn-toast { transform: translateY(16px); }
.zn-toast.show { transform: translateY(0); }
@media (max-width: 767px) {
    .zn-toast-wrap { left: 12px; right: 12px; transform: none; bottom: 74px; }
}

/* =====================================================================
 * 21. КАТАЛОГ — сортування праворуч, пагінація з відступом
 * ===================================================================== */
.zn-shop-control {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    flex-wrap: wrap;
}
.zn-shop-control .tf-control-sorting { margin-left: auto; }
.js-catalog-pagination { margin-top: 36px; }
.js-catalog-pagination:empty { margin-top: 0; }
.wg-pagination { margin: 0; }

/* мобільна панель фільтрів */
body.zn-filter-open { overflow: hidden; }
.sidebar-filter .canvas-header .close-filter {
    cursor: pointer;
    padding: 10px;
    margin: -10px;
    font-size: 16px;
    position: relative;
    z-index: 5;
}

/* =====================================================================
 * 22. КОШИК — хрестик замість тексту, без горизонтального скролу
 * ===================================================================== */
.zn-remove-x {
    background: none; border: 0; padding: 4px; cursor: pointer;
    color: #b4b4b4; font-size: 13px; line-height: 1; transition: .2s;
}
.zn-remove-x:hover { color: #d93025; }

.modal-shopping-cart .tf-mini-cart-item { overflow: hidden; }
.modal-shopping-cart .tf-mini-cart-info { min-width: 0; }
.modal-shopping-cart .tf-mini-cart-info .content { gap: 10px; }
.modal-shopping-cart .tf-mini-cart-info .left { min-width: 0; flex: 1 1 auto; }
.modal-shopping-cart .tf-mini-cart-info .right {
    flex: 0 0 auto; text-align: right; white-space: nowrap;
}
.modal-shopping-cart .tf-mini-cart-info .text-title { overflow: hidden; }
.modal-shopping-cart .tf-mini-cart-info .text-title a {
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
    overflow: hidden; word-break: break-word;
}
.modal-shopping-cart .wrap,
.modal-shopping-cart .tf-mini-cart-wrap { overflow-x: hidden; }
@media (max-width: 575px) {
    .modal-shopping-cart .modal-dialog { max-width: 100%; }
    .modal-shopping-cart .tf-mini-cart-image { flex: 0 0 68px; width: 68px; }
    .modal-shopping-cart .tf-mini-cart-info .text-title a { font-size: 13px; }
    .modal-shopping-cart .wg-quantity { width: 100px; }
    .modal-shopping-cart .tf-mini-cart-info .right .text-button { font-size: 13px; }
}

/* =====================================================================
 * 23. ОФОРМЛЕННЯ — акуратний блок кількості (як у картці)
 * ===================================================================== */
.item-product .content-box { gap: 14px; }
.zn-qty-sm {
    width: 116px; margin-top: 10px;
    display: flex; align-items: center; justify-content: space-between;
    border: 1px solid var(--line, #e5e5e5); border-radius: 999px;
    height: 38px; overflow: hidden; background: #fff;
}
.zn-qty-sm .btn-quantity {
    width: 34px; height: 100%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; font-size: 16px; line-height: 1;
    color: #555; user-select: none; transition: .15s;
}
.zn-qty-sm .btn-quantity:hover { background: #f4f4f4; color: #181818; }
.zn-qty-sm .quantity-product {
    width: 100%; border: 0; text-align: center;
    font-size: 14px; font-weight: 600; padding: 0; background: transparent;
}
.zn-qty-sm .quantity-product:focus { outline: none; }
.zn-item-remove {
    width: 30px; height: 30px; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    background: #f6f6f6; border: 0; cursor: pointer;
    color: #b4b4b4; font-size: 11px; transition: .2s;
}
.zn-item-remove:hover { background: #fef2f2; color: #d93025; }

/* =====================================================================
 * 24. ТЕКСТОВІ СТОРІНКИ — рівний лівий край
 * ===================================================================== */
.page-text-block { width: 100%; max-width: 100%; margin: 0; }
.page-text-block > .polNew,
.polNew.page-text-block { max-width: 1000px; }

/* =====================================================================
 * 25. ВХІД І РЕЄСТРАЦІЯ — компактне розташування
 * ===================================================================== */
.zn-auth-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 40px;
    align-items: start;
    max-width: 1040px;
}
.zn-auth-form { min-width: 0; }
.zn-auth-form .heading { margin-bottom: 22px; }
.zn-form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.zn-auth-form .wrap { display: flex; flex-direction: column; gap: 14px; }
.zn-auth-form .button-submit { margin-top: 20px; }
.zn-auth-switch {
    margin-top: 16px; text-align: center; font-size: 14px; color: #666;
}
.zn-auth-switch a { font-weight: 600; text-decoration: underline; }

.zn-auth-side {
    background: #f7f7f5; border-radius: 14px; padding: 26px 24px;
    position: sticky; top: 24px;
}
.zn-auth-side h5 { margin-bottom: 16px; font-size: 18px; }
.zn-auth-benefits { list-style: none; padding: 0; margin: 0 0 20px; }
.zn-auth-benefits li {
    display: flex; align-items: flex-start; gap: 10px;
    padding: 7px 0; font-size: 14px; line-height: 1.5;
}
.zn-auth-benefits i { color: #2cb769; font-size: 12px; margin-top: 4px; flex-shrink: 0; }
.zn-auth-help {
    border-top: 1px solid #e3e3e0; padding-top: 16px;
    display: flex; flex-direction: column; gap: 4px; font-size: 14px;
}
.zn-auth-help span { color: #888; }
.zn-auth-help a { font-weight: 600; font-size: 17px; }

@media (max-width: 991px) {
    .zn-auth-wrap { grid-template-columns: 1fr; gap: 26px; }
    .zn-auth-side { position: static; order: 2; }
}
@media (max-width: 575px) {
    .zn-form-row { grid-template-columns: 1fr; }
}

/* =====================================================================
 * 26. МОБІЛЬНА СІТКА — дві картки вміщаються, сердечко рівно
 * ===================================================================== */
@media (max-width: 767px) {
    /* контейнер не має «розпирати» екран */
    .wrapper-control-shop .row { margin-left: 0; margin-right: 0; }
    .wrapper-control-shop .row > [class*="col-"] { padding-left: 0; padding-right: 0; }

    .tf-grid-layout.tf-col-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
    .card-product { min-width: 0; }

    /* сердечко: однаковий відступ від краю фото */
    .pINWish {
        height: 32px; width: 32px;
        top: 6px; right: 6px;
    }
    .pINWish a { font-size: 18px; display: flex; align-items: center; justify-content: center; }

    /* значки не перекривають сердечко */
    .card-product .on-sale-wrap { max-width: calc(100% - 46px); flex-wrap: wrap; }
}

@media (max-width: 575px) {
    .tf-grid-layout.tf-col-2 { gap: 10px; }
    .card-product .card-product-info { padding-top: 8px; }
}

/* горизонтальний скрол на мобільному — прибираємо повністю */
@media (max-width: 991px) {
    html, body { overflow-x: hidden; max-width: 100%; }
    .offcanvas, .modal { max-width: 100vw; }
}

/* =====================================================================
 * 27. МОДАЛКА «КУПИТИ В 1 КЛІК»
 * ===================================================================== */
.modal-quick-order .modal-dialog { max-width: 460px; }
.modal-quick-order .modal-content { border-radius: 14px; border: 0; }
.quick-order-inner { position: relative; padding: 32px 30px 28px; }
.quick-order-inner .icon-close-popup {
    position: absolute; top: 16px; right: 18px; cursor: pointer; font-size: 15px;
}
.quick-order-head { margin-bottom: 18px; }
.quick-order-head h5 { margin-bottom: 6px; }
.quick-order-head p { font-size: 13.5px; line-height: 1.55; margin: 0; }

.quick-order-product {
    display: flex; align-items: center; gap: 14px;
    background: #f8f8f7; border-radius: 10px;
    padding: 12px 14px; margin-bottom: 18px;
}
.quick-order-product .qo-img {
    flex: 0 0 54px; width: 54px; height: 64px;
    border-radius: 8px; overflow: hidden; background: #fff;
}
.quick-order-product .qo-img img { width: 100%; height: 100%; object-fit: cover; }
.quick-order-product .qo-info { min-width: 0; }
.quick-order-product .qo-name {
    font-weight: 600; font-size: 14px; line-height: 1.35;
    display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.quick-order-product .qo-meta { font-size: 13px; color: #777; margin-top: 4px; }

.modal-quick-order .field-wrap input {
    width: 100%; height: 48px; padding: 0 16px;
    border: 1px solid var(--line, #e5e5e5); border-radius: 8px; font-size: 14px;
}
.quick-order-note {
    margin: 14px 0 0; font-size: 12px; line-height: 1.5; color: #999; text-align: center;
}
.quick-order-note a { text-decoration: underline; }

.qo-success { text-align: center; padding: 12px 0; }
.qo-success-icon { color: #2cb769; margin-bottom: 12px; }
.qo-success-icon svg path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: qoDraw .55s .1s ease forwards; }
@keyframes qoDraw { to { stroke-dashoffset: 0; } }
.qo-success h5 { margin-bottom: 8px; }
.qo-success p { margin: 4px 0; font-size: 14px; }

@media (max-width: 575px) {
    .quick-order-inner { padding: 26px 20px 22px; }
}

/* =====================================================================
 * 28. ВХІД І РЕЄСТРАЦІЯ — картка + бічний блок
 * ===================================================================== */
.zn-auth-wrap {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 340px;
    gap: 32px;
    align-items: start;
    max-width: 1060px;
    margin: 0 auto;
}
.zn-auth-card {
    background: #fff;
    border: 1px solid var(--line, #e9e9e7);
    border-radius: 16px;
    padding: 34px 34px 30px;
    min-width: 0;
}
.zn-auth-head { margin-bottom: 22px; }
.zn-auth-head h4 { margin-bottom: 6px; }
.zn-auth-head p { font-size: 14px; margin: 0; }

.zn-auth-card .wrap { display: flex; flex-direction: column; gap: 14px; }
.zn-auth-card .button-submit { margin-top: 20px; }
.zn-auth-row {
    display: flex; align-items: center; justify-content: space-between;
    gap: 14px; flex-wrap: wrap;
}
.zn-auth-row .forget-password { white-space: nowrap; }

.zn-auth-divider {
    display: flex; align-items: center; gap: 14px;
    margin: 22px 0 16px; color: #a5a5a5; font-size: 13px;
}
.zn-auth-divider::before,
.zn-auth-divider::after {
    content: ""; flex: 1; height: 1px; background: var(--line, #e9e9e7);
}

.zn-auth-side {
    background: #f7f7f5;
    border-radius: 16px;
    padding: 28px 26px;
    position: sticky;
    top: 24px;
}
.zn-auth-side h5 { margin-bottom: 18px; font-size: 18px; }
.zn-auth-benefits { list-style: none; padding: 0; margin: 0 0 22px; }
.zn-auth-benefits li {
    display: flex; align-items: flex-start; gap: 11px;
    padding: 8px 0; font-size: 14px; line-height: 1.5;
}
.zn-auth-benefits i {
    color: #2cb769; font-size: 11px; margin-top: 5px; flex-shrink: 0;
}
.zn-auth-help {
    border-top: 1px solid #e3e3e0; padding-top: 18px;
    display: flex; flex-direction: column; gap: 5px; font-size: 14px;
}
.zn-auth-help span { color: #8a8a86; }
.zn-auth-help a { font-weight: 600; font-size: 18px; }

@media (max-width: 991px) {
    .zn-auth-wrap { grid-template-columns: 1fr; gap: 22px; }
    .zn-auth-side { position: static; order: 2; }
    .zn-auth-card { padding: 26px 22px 24px; }
}
@media (max-width: 575px) {
    .zn-form-row { grid-template-columns: 1fr; }
    .zn-auth-card { padding: 22px 18px 20px; border-radius: 12px; }
}

/* =====================================================================
 * 29. ПОРОЖНІЙ КОШИК — усе по центру
 * ===================================================================== */
.cart-empty-page {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 64px 20px 72px;
}
.cart-empty-page .tf-btn { display: inline-flex; margin: 0 auto; }
.tf-mini-cart-empty { display: flex; flex-direction: column; align-items: center; }
.tf-mini-cart-empty .tf-btn { max-width: 280px; }

/* =====================================================================
 * 30. СТОРІНКА ТОВАРУ — кількість і кнопка «В обране»
 * ===================================================================== */
.zn-buy-row .wg-quantity {
    width: 138px;
    height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border: 1px solid var(--line, #e5e5e5);
    border-radius: 999px;
    overflow: hidden;
    background: #fff;
}
.zn-buy-row .wg-quantity .btn-quantity {
    width: 44px; height: 100%;
    display: flex; align-items: center; justify-content: center;
    font-size: 19px; line-height: 1; color: #6b6b6b;
    cursor: pointer; user-select: none; transition: .15s;
}
.zn-buy-row .wg-quantity .btn-quantity:hover { background: #f3f3f2; color: #181818; }
.zn-buy-row .wg-quantity .btn-quantity:active { background: #ebebea; }
.zn-buy-row .wg-quantity .quantity-product {
    width: 100%; border: 0; background: transparent; text-align: center;
    font-size: 16px; font-weight: 600; padding: 0;
}
.zn-buy-row .wg-quantity .quantity-product:focus { outline: none; }

/* кнопка «В обране» */
.zn-wish-btn {
    flex: 0 0 auto;
    width: 52px; height: 52px;
    display: inline-flex; align-items: center; justify-content: center;
    border: 1px solid var(--line, #e5e5e5);
    border-radius: 50%;
    background: #fff;
    color: #9a9a97;
    font-size: 22px;
    cursor: pointer;
    padding: 0;
    transition: transform .18s cubic-bezier(.3,1.4,.5,1), background .2s, color .2s, border-color .2s;
}
.zn-wish-btn:hover {
    border-color: #e5484d;
    color: #e5484d;
    background: #fff5f5;
}
.zn-wish-btn.active {
    background: #e5484d;
    border-color: #e5484d;
    color: #fff;
}
.zn-wish-btn.active:hover { background: #cf3f43; border-color: #cf3f43; }
.zn-wish-btn.just-added { animation: znHeartPop .42s ease; }
@keyframes znHeartPop {
    0%   { transform: scale(1); }
    40%  { transform: scale(1.22); }
    70%  { transform: scale(.94); }
    100% { transform: scale(1); }
}

/* сердечко на картці товару в каталозі */
.pINWish a.active { color: #e5484d; }
.pINWish:has(a.active) { background: #fff; }
.pINWish:has(a.active):hover { background: #e5484d; }
.pINWish:has(a.active):hover a { color: #fff; }

@media (max-width: 767px) {
    .zn-buy-row .wg-quantity { height: 48px; width: 100%; }
    .zn-wish-btn { width: 48px; height: 48px; font-size: 20px; }
}

/* =====================================================================
 * 31. МОБІЛЬНИЙ: кількість + кошик + сердечко в один ряд
 * ===================================================================== */
@media (max-width: 767px) {
    .zn-buy-row {
        flex-wrap: nowrap;
        align-items: center;
        gap: 8px;
    }
    /* мітка «Кількість:» на мобільному зайва — вона зрозуміла з вигляду */
    .zn-buy-row .zn-qty-label { display: none; }

    .zn-buy-row .tf-product-info-quantity { flex: 0 0 auto; }
    .zn-buy-row .wg-quantity {
        width: 106px;
        height: 48px;
    }
    .zn-buy-row .wg-quantity .btn-quantity { width: 32px; font-size: 17px; }
    .zn-buy-row .wg-quantity .quantity-product { font-size: 15px; }

    .zn-buy-row .zn-add-btn {
        flex: 1 1 auto;
        order: 0;
        min-width: 0;
        height: 48px;
        padding: 0 10px;
        font-size: 12.5px;
        letter-spacing: .01em;
        white-space: nowrap;
        overflow: hidden;
    }
    .zn-buy-row .zn-wish-btn { width: 48px; height: 48px; font-size: 20px; }

    .zn-buy-now { margin-top: 10px; }
}

/* на зовсім вузьких екранах ховаємо суму в кнопці — лишається дія */
@media (max-width: 400px) {
    .zn-buy-row { gap: 6px; }
    .zn-buy-row .wg-quantity { width: 94px; }
    .zn-buy-row .wg-quantity .btn-quantity { width: 28px; }
    .zn-buy-row .zn-add-btn { font-size: 12px; padding: 0 6px; }
    .zn-buy-row .zn-add-btn .tf-qty-price { display: none; }
    .zn-buy-row .zn-add-btn > span:first-child::after { content: ""; }
    .zn-buy-row .zn-wish-btn { width: 44px; height: 44px; font-size: 18px; }
}

/* =====================================================================
 * 32. iOS: без автозуму при фокусі на полі
 *
 *     Safari на iPhone збільшує сторінку, якщо шрифт поля менший
 *     за 16px. Ставимо рівно 16px — зум не спрацьовує, вигляд
 *     майже не змінюється.
 * ===================================================================== */
@media (max-width: 991px) {
    input[type="text"],
    input[type="password"],
    input[type="email"],
    input[type="tel"],
    input[type="number"],
    input[type="search"],
    input[type="url"],
    input[type="date"],
    input[type="datetime-local"],
    textarea,
    select {
        font-size: 16px !important;
    }
    /* поля кількості лишаються компактними, але теж без зуму */
    .wg-quantity .quantity-product { font-size: 16px !important; }
}


/* =====================================================================
 * 33. ПОЛЕ ПАРОЛЯ — іконка ока не з'їжджає при помилці
 *
 *     Раніше іконка центрувалась відносно всього поля (top: 50%).
 *     Щойн з'являвся текст помилки або підпис над полем, висота
 *     контейнера змінювалась — і око зсувалось.
 *     Тепер інпут з іконкою загорнуті в окремий контейнер, тож
 *     іконка завжди рівно по центру самого поля вводу.
 * ===================================================================== */
.password-field {
    position: relative;
    display: block;
    width: 100%;
}
.password-field > input { width: 100%; }

.form-has-password .password-field .toggle-password,
.password-field .toggle-password {
    position: absolute;
    right: 16px;
        top: 27px;
    transform: translateY(-50%);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 2;
    padding: 4px;
    margin: -4px;
}
.password-field .toggle-password i {
    font-size: 20px;
    line-height: 1;
    color: var(--Secondary-2, #797979);
    transition: color .15s;
}
.password-field .toggle-password:hover i { color: var(--Primary, #181818); }

/* текст не заповзає під іконку */
.password-field > input { padding-right: 46px !important; }
