/**
 * OptaVideo.com — Product Page Custom Styles
 * UIKit 3 | Joomla 5.2
 */

/* ==========================================
   1. PRODUCT HEADER & META INFO
   ========================================== */

.product-header {
    margin-bottom: 25px;
}

.product-header h1 {
    font-size: 2em;
    line-height: 1.5;
    margin: 0;
}

.product-info {
    display: flex;
    margin-top: 1em;
    gap: 1em;
    font-weight: 700;
}

.product-info span {
    color: #666;
    font-weight: 400;
}

/* ==========================================
   2. NAVIGATION TABS & BRAND LOGO
   ========================================== */

/* --- Sticky wrapper --- */
.product-tabs-sticky-wrapper {
    width: 100%;
    margin-bottom: 25px;
    isolation: isolate;
}

.product-tabs-sticky-wrapper.uk-sticky-fixed,
.product-tabs-sticky-wrapper.uk-active {
    z-index: 980;
}

.product-tabs-title {
    background: #fff;
    padding: 0.5em 1em;
    transition: all 0.3s ease;
}

.product-tabs-sticky-wrapper.uk-sticky-fixed .product-tabs-title {
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
    padding: 0;
}

#product-tabs-sticky.is-sticky-active .product-tabs-title {
    box-shadow: 0 2px 15px rgba(0, 0, 0, 0.1);
}

/* --- Scroll container & arrows --- */
.product-tabs-nav-scroll {
    position: relative;
    display: flex;
    align-items: center;
    width: 100%;
    overflow: hidden;
}

.product-tabs-nav-scroll .product-nav-tabs {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    scroll-behavior: smooth;
    padding: 4px;
}

.product-tabs-nav-scroll .product-nav-tabs::-webkit-scrollbar {
    display: none;
}

.product-tabs-scroller {
    position: absolute;
    top: 0;
    bottom: 0;
    display: flex;
    align-items: center;
    z-index: 2;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

.product-tabs-scroller.hidden {
    opacity: 0;
    pointer-events: none;
}

/* Градиент контейнер — всегда виден, служит индикатором переполнения */
.product-tabs-scroller:not(.hidden) {
    opacity: 1;
    pointer-events: none;
    /* не блокируем scroll/touch на табах */
    transition: opacity 0.2s ease;
}

/* Кнопка скрыта по умолчанию */
.product-tabs-scroller:not(.hidden) .product-tabs-scroller-btn {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease;
}

/* При наведении на nav — показываем кнопку */
.product-tabs-nav-scroll:hover .product-tabs-scroller:not(.hidden) .product-tabs-scroller-btn {
    opacity: 1;
    pointer-events: auto;
}

.product-tabs-scroller-left {
    left: 0;
    background: linear-gradient(90deg, #fff 60%, rgba(255, 255, 255, 0) 100%);
    padding-right: 16px;
}

.product-tabs-scroller-right {
    right: 0;
    background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, #fff 40%);
    padding-left: 16px;
}

.product-tabs-scroller-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: opacity 0.2s ease, background-color 0.2s, box-shadow 0.2s;
    pointer-events: auto;
}

.product-tabs-scroller-btn svg {
    display: block;
}

/* --- Flex-колонки sticky-bar --- */
.product-tabs-nav-col {
    min-width: 0;
    /* позволяет flex-элементу сужаться ниже содержимого */
    overflow: hidden;
}

.product-dealer-col {
    padding-left: 12px;
    flex-shrink: 0;
}

/* --- Tab items (uk-subnav uk-subnav-pill — стандартный UIKit3 pill-nav) --- */
.product-nav-tabs.uk-subnav>*> :first-child {
    display: flex;
    align-items: center;
    column-gap: .25em;
    color: #585858;
    background-color: #f4f5f6;
    font-size: 1.125rem;
    font-weight: 500;
    text-transform: none;
    transition: background-color 0.15s ease, color 0.15s ease;
    padding: 0.75rem 1.25rem;
    border-radius: 5px;
    line-height: 20px;
    white-space: nowrap;
}

.product-nav-tabs.uk-subnav>*>a:hover {
    background-color: #e6e8ec;
    color: #585858;
    text-decoration: none;
}

.product-nav-tabs.uk-subnav>.uk-active>a,
.product-nav-tabs.uk-subnav>*>a:active {
    background-color: #038096;
    color: #fff;
}

.product-nav-tabs.uk-subnav-pill>*>a::before {
    display: none;
}

/* uk-nav-pill (nav component, not subnav) */
.product-nav-tabs.uk-nav-pill>*>a::after {
    display: none;
}

/* --- Sticky state: compact tabs --- */
.product-tabs-sticky-wrapper.uk-sticky-fixed .product-nav-tabs.uk-subnav>*> :first-child {
    font-size: 13px;
}

.product-tabs-sticky-wrapper.uk-sticky-fixed .brand-logo {
    padding: 6px 10px;
}

.product-tabs-sticky-wrapper.uk-sticky-fixed .brand-logo img {
    max-width: 70px;
    max-height: 50px;
}

/* --- Brand official badge: flex-wrap для переноса на следующую строку при нехватке места --- */
.brand-official-badge {
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.brand-official-badge>span {
    flex: 0 1 auto;
    min-width: 0;
    font-size: 0.8em;
    line-height: 1.3;
    white-space: normal;
    text-align: center;
}

/* В sticky-баре: сброс tablet-override margin-top/width */
.product-tabs-title .brand-official-badge {
    margin-top: 0;
    width: auto;
    justify-content: flex-end;
}

/* --- Brand logo --- */
.brand-logo {
    background: #fff;
    padding: 10px 15px;
    border-radius: 5px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.brand-logo img {
    max-width: 100px;
    max-height: 100px;
    height: auto;
    display: block;
}

/* --- Anchor offset for sticky header --- */
#desc,
#pecs,
#specs,
#reviews,
#product-full-description {
    scroll-margin-top: var(--product-sticky-offset, 90px);
}

/* ==========================================
   3. PRODUCT GALLERY
   ========================================== */

.product-gallery {
    position: relative;
}

.product-main-img {
    border: 1px solid #e5e5e5;
    background: #f8f9fa;
    position: relative;
    overflow: hidden;
    border-radius: 8px;
}

.product-main-img img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-main-img:hover img {
    transform: scale(1.05);
}

.product-gallery-slider {
    margin-top: 15px;
}

.product-gallery-slider .uk-slider-items>li {
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 6px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.product-gallery-slider .uk-slider-items>li:hover {
    border-color: #038096;
    box-shadow: 0 2px 8px;
}

.product-gallery-slider .uk-slider-items>li.uk-active {
    border-color: #038096;
    box-shadow: 0 2px 8px rgba(3, 128, 150, 0.3);
}

.product-gallery-slider img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    display: block;
}

.slider-nav-prev,
.slider-nav-next {
    background: rgba(0, 0, 0, 0.5);
    width: 40px;
    height: 40px;
    border-radius: 50%;
    color: #fff !important;
    transition: all 0.3s ease;
}

.slider-nav-prev:hover,
.slider-nav-next:hover {
    background: #038096;
}

/* ==========================================
   4. PRODUCT INFO (right column)
   ========================================== */

.product-info-wrapper {
    background: #fff;
    padding: 20px;
    border-radius: 5px;
}

/* --- Features --- */
.product-features {
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid #038096;
}

.product-features-content ul {
    list-style: none;
    padding-left: 0;
    margin: 10px 0 0 0;
}

.product-features-content ul li {
    padding: 8px 0 8px 25px;
    border-bottom: 1px solid #e5e5e5;
    position: relative;
}

.product-features-content ul li:last-child {
    border-bottom: none;
}

.product-features-content ul li::before {
    content: "\2713";
    color: #038096;
    font-weight: bold;
    font-size: 16px;
    position: absolute;
    left: 0;
    top: 8px;
}

/* --- Stock status --- */
.product-stock {
    border-bottom: 1px solid #e8e8e8;
    padding: 20px 0;
}

/* --- Price --- */
.product-price {
    font-size: 26px;
    border-bottom: 1px solid #e8e8e8;
    padding: 20px 0;
}

.product-price .old-price {
    text-decoration: line-through;
    color: #999;
    font-size: 20px;
    display: block;
    margin-bottom: 5px;
}

/* --- Buy block --- */
.product-buy {
    border-bottom: 1px solid #e8e8e8;
    padding: 20px 0;
}

.quantity-selector {
    display: flex;
    align-items: center;
    width: 100%;
    max-width: 190px;
    border: 0;
    border-radius: 0;
    overflow: visible;
    background: transparent;
}

.quantity-selector .quantity-wrapper {
    justify-content: flex-start;
    width: 100%;
}

.quantity-selector .item-count-wrapper,
.quantity-selector .quantity-btn {
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.08);
}

.product-buy .quantity-selector .quantity-btn {
    width: 44px !important;
    min-width: 44px !important;
    height: 44px !important;
}

.product-buy .quantity-selector .item-count-wrapper {
    height: 44px;
}

.product-buy .quantity-selector .input-quantity {
    height: 44px !important;
    line-height: 44px;
}

.product-buy .uk-grid {
    align-items: stretch;
}

.product-buy .uk-width-auto\@s {
    display: flex;
}

.product-buy-buttons,
.product-buy-buttons .jbprice-buttons {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 10px;
}

.product-buy-buttons .jbprice-buttons-add,
.product-quick-order {
    min-height: 44px;
    padding: 0 18px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.product-buy .buttons_full_block .jbprice-buttons-add,
.product-buy .product-quick-order {
    min-height: 44px !important;
    padding: 0 18px !important;
    border-radius: 10px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.product-buy-buttons .jbprice-buttons.in-cart .jbprice-buttons-goto {
    min-height: 44px;
    padding: 0 18px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-weight: 600;
    line-height: 1.2;
    text-align: center;
    transition: background-color 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.product-buy-buttons .jbprice-buttons .jbprice-buttons-goto,
.product-buy .buttons_full_block .jbprice-buttons .jbprice-buttons-goto {
    display: none;
}

.product-buy .buttons_full_block .jbprice-buttons.in-cart .jbprice-buttons-goto {
    min-height: 44px !important;
    padding: 0 18px !important;
    border-radius: 10px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.product-buy-buttons .jbprice-buttons.not-in-cart .jbprice-buttons-goto,
.product-buy .buttons_full_block .jbprice-buttons.not-in-cart .jbprice-buttons-goto {
    display: none !important;
}

.product-buy-buttons .jbprice-buttons-add,
.product-buy-buttons .jbprice-buttons-goto {
    border: 1px solid #15819e;
    box-shadow: 0 10px 24px rgba(21, 129, 158, 0.16);
}

.product-buy .buttons_full_block .jbprice-buttons-add {
    background: #15819e !important;
    border: 1px solid #15819e !important;
    color: #fff !important;
    box-shadow: 0 10px 24px rgba(21, 129, 158, 0.16) !important;
}

.product-buy-buttons .jbprice-buttons-add {
    background: #15819e;
    color: #fff;
}

.product-buy-buttons .jbprice-buttons-goto,
.product-quick-order {
    background: #fff;
    color: #15819e;
    border: 1px solid #15819e;
}

.product-buy .buttons_full_block .jbprice-buttons-goto,
.product-buy .product-quick-order {
    background: #fff !important;
    color: #15819e !important;
    border: 1px solid #15819e !important;
    box-shadow: 0 10px 24px rgba(21, 129, 158, 0.12) !important;
}

.product-buy .quantity-selector .quantity-btn:hover,
.product-buy .quantity-selector .quantity-btn:focus,
.product-buy .quantity-selector .quantity-btn:focus-visible {
    background: #15819e;
    border-color: #15819e;
    box-shadow: 0 10px 22px rgba(21, 129, 158, 0.24);
}

.product-buy-buttons .jbprice-buttons-add:hover,
.product-buy-buttons .jbprice-buttons-add:focus,
.product-buy-buttons .jbprice-buttons-add:focus-visible,
.product-buy-buttons .jbprice-buttons-goto:hover,
.product-buy-buttons .jbprice-buttons-goto:focus,
.product-buy-buttons .jbprice-buttons-goto:focus-visible,
.product-quick-order:hover,
.product-quick-order:focus,
.product-quick-order:focus-visible {
    background: #15819e;
    border-color: #15819e;
    color: #fff;
    box-shadow: 0 10px 22px rgba(21, 129, 158, 0.24);
}

.product-buy .buttons_full_block .jbprice-buttons-add:hover,
.product-buy .buttons_full_block .jbprice-buttons-add:focus,
.product-buy .buttons_full_block .jbprice-buttons-add:focus-visible,
.product-buy .buttons_full_block .jbprice-buttons-goto:hover,
.product-buy .buttons_full_block .jbprice-buttons-goto:focus,
.product-buy .buttons_full_block .jbprice-buttons-goto:focus-visible,
.product-buy .product-quick-order:hover,
.product-buy .product-quick-order:focus,
.product-buy .product-quick-order:focus-visible {
    background: #15819e !important;
    border-color: #15819e !important;
    color: #fff !important;
    box-shadow: 0 10px 22px rgba(21, 129, 158, 0.24) !important;
}

.product-buy .quantity-selector .input-quantity:focus {
    border-color: #15819e;
    box-shadow: inset 0 0 0 1px rgba(21, 129, 158, 0.22), 0 0 0 3px rgba(21, 129, 158, 0.12);
}

/* --- Cart buttons: show text, hide icon on product page --- */
.jbprice-buttons-goto>.tm-product-card-add-button-icon,
.jbprice-buttons-remove>.tm-product-card-add-button-icon,
.buttons_full_block>.jbprice-buttons button .tm-product-card-add-button-icon {
    display: none;
}

.jbprice-buttons-goto>.tm-product-card-add-button-text,
.jbprice-buttons-remove>.tm-product-card-add-button-text,
.buttons_full_block>.jbprice-buttons button .tm-product-card-add-button-text {
    display: inline-block;
}

.product-buy-buttons .tm-product-card-add-button-text {
    white-space: nowrap;
}

/* --- Shipping & payment --- */
.product-shipping,
.product-payment {
    padding: 20px 0;
}

.product-shipping {
    border-bottom: 1px solid #e8e8e8;
}

.product-shipping-title,
.product-payment-title {
    font-weight: 700;
    margin-bottom: 30px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 20px;
}

.product-shipping ul,
.product-payment ul {
    margin-left: 20px;
}

.product-shipping ul li,
.product-payment ul li {
    margin: 15px 0;
}

/* ==========================================
   5. PRODUCT SLIDERS (accessories, similar)
   ========================================== */

.product-similar {
    background: #fff;
    padding: 20px;
    border-radius: 4px;
    margin: 20px auto;
}

.control-arrow {
    gap: 3px;
}

.slider-control-btn {
    background: #fff;
    width: 40px;
    height: 40px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid #e5e5e5;
    transition: all 0.3s ease;
    color: #333 !important;
}

.slider-control-btn:hover {
    background: #038096;
    border-color: #038096;
    color: #fff !important;
    transform: scale(1.1);
}

/* --- Slider product card --- */
.product-card-slider-item {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
    display: block;
    height: 100%;
}

.product-card-slider-item:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
    border-color: #038096;
}

.product-card-slider-item .product-cat {
    font-size: 11px;
    color: #999;
    text-transform: uppercase;
    margin-bottom: 8px;
    font-weight: 600;
}

.product-card-slider-item .product-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    min-height: 40px;
    color: #333;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-card-slider-item .product-price {
    display: flex;
    flex-direction: column;
    gap: 5px;
    margin-top: 10px;
}

.product-card-slider-item .old-price {
    text-decoration: line-through;
    color: #999;
    font-size: 13px;
}

.product-card-slider-item .reg-price {
    font-size: 18px;
    font-weight: 700;
    color: #038096;
}

.product-card-slider-item .reg-price.c-2 {
    color: #e53e3e;
}

.product-card-slider-item .uk-button {
    margin-top: 10px;
}

/* --- Slider article card --- */
.article-card {
    background: #fff;
    border: 1px solid #e5e5e5;
    border-radius: 5px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.article-card:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-4px);
}

.article-card .article-img {
    overflow: hidden;
    height: 200px;
    position: relative;
}

.article-card .article-img img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.article-card:hover .article-img img {
    transform: scale(1.1);
}

.article-card .article-cat {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.article-card .article-cat.b-1 {
    background: #e3f2fd;
    color: #1976d2;
}

.article-card .article-cat.b-2 {
    background: #f3e5f5;
    color: #7b1fa2;
}

.article-card .article-date {
    color: #999;
    font-size: 12px;
}

.article-card .article-title {
    font-size: 15px;
    font-weight: 600;
    color: #333;
    margin-top: 8px;
}

/* ==========================================
   6. CONTENT TABS (description, specs, reviews)
   ========================================== */

.product-full-description>.product-tab-content,
.product-tab-content #reviews {
    background: #fff;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.product-full-description>.product-tab-content>h2.uk-h2 {
    font-size: 30px;
    font-weight: 900;
    padding: 0;
    margin: 0 0 20px 0;
}

.product-full-description>.product-tab-content>h2 {
    margin: 20px 0;
    font-weight: 800;
    font-size: 20px;
}

.product-full-description>.product-tab-content>p {
    margin: 20px 0 0 0;
    line-height: 1.5;
}

.product-full-description>.product-tab-content>p:first-child {
    margin: 0;
}

/* --- Tables inside content tabs --- */
.product-full-description>.product-tab-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 0;
}

.product-full-description>.product-tab-content table tr {
    border: transparent;
}

.product-full-description>.product-tab-content table tr:hover {
    background: none;
}

.product-full-description>.product-tab-content table td {
    padding: 5px;
    border: none;
    line-height: 24px;
}

.product-full-description>.product-tab-content table td>h2,
.product-full-description>.product-tab-content table td>h3,
.product-full-description>.product-tab-content table td>h4,
.product-full-description>.product-tab-content table td>h5,
.product-full-description>.product-tab-content table td>h6,
.product-full-description>.product-tab-content table td>p {
    margin: 0 0 10px 0;
    padding: 0;
}

.product-full-description>.product-tab-content table td>ul {
    margin: 0 0 10px 20px;
    padding: 0;
}

.product-full-description>.product-tab-content table td:first-child {
    font-weight: 600;
    width: 40%;
}

/* ==========================================
   7. COLLAPSIBLE SECTIONS
   ========================================== */

.product-full-description section.product-tab-content {
    position: relative;
    margin-bottom: 18px;
}

.collapsible-content {
    overflow: hidden;
    transition: max-height .36s cubic-bezier(.2, .9, .2, 1);
    will-change: max-height;
    max-height: none;
}

.section-toggle {
    display: inline-flex;
    align-items: center;
    gap: .5em;
    background: #e8e8e8;
    color: #585858;
    padding: 10px 15px;
    line-height: 20px;
    border: transparent;
    border-radius: 5px;
    cursor: pointer;
    transition: background .18s ease, color .18s ease, border-color .18s ease;
}

.section-toggle:hover {
    background: #038096;
    color: #fff;
}

.section-toggle span[uk-icon] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.2em;
}

.section-toggle-wrap {
    display: flex;
    justify-content: center;
    padding: 12px 0 0;
    position: relative;
    z-index: 2;
}

section.product-tab-content.collapsed .section-toggle-wrap::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 48px;
    height: 48px;
    pointer-events: none;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.95));
}

section.no-toggle .section-toggle {
    display: none !important;
}

section.product-tab-content[style*="display: none"] {
    visibility: hidden;
    height: 0;
    margin: 0;
    padding: 0;
}

/* ==========================================
   8. SIDEBAR BANNERS
   ========================================== */

.product-sidebar>div {
    background: #fff;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
    overflow: hidden;
}

.product-sidebar .banner-item img {
    width: 100%;
    height: auto;
    display: block;
}

/* ==========================================
   9. VIDEO EMBED
   ========================================== */

.product-video-full {
    max-width: 100%;
    margin: 0 auto;
}

.product-video-full iframe,
.product-video-full video {
    width: 100%;
    height: 100%;
    max-width: 100%;
    border-radius: 8px;
    background: #000;
    display: block;
}

.product-video-full .uk-responsive-width {
    position: relative;
    width: 100%;
    padding-bottom: 56.25%;
    height: 0;
}

.product-video-full .uk-responsive-width iframe,
.product-video-full .uk-responsive-width video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

/* ==========================================
   10. ANIMATIONS
   ========================================== */

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.product-tab-content {
    animation: fadeIn 0.28s ease-in-out;
}

/* ==========================================
   11. ACCESSIBILITY
   ========================================== */

.uk-button:focus,
.slider-control-btn:focus,
.product-nav-tabs a:focus {
    outline: 2px solid #038096;
    outline-offset: 2px;
}

.product-nav-tabs a:focus-visible {
    outline: 3px solid #038096;
    outline-offset: 3px;
    box-shadow: 0 0 0 4px rgba(3, 128, 150, 0.2);
}

.product-buy button:focus-visible,
.product-quick-order:focus-visible,
.section-toggle:focus-visible {
    outline: 3px solid #15819e;
    outline-offset: 2px;
    box-shadow: 0 0 0 4px rgba(21, 129, 158, 0.2);
}

@media (prefers-contrast: high) {

    .brand-official-badge,
    .product-buy-buttons .uk-button-primary {
        background: #00a000;
    }

    .product-price {
        color: #008000;
    }
}

@media (prefers-reduced-motion: reduce) {

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* ==========================================
   12. PRINT
   ========================================== */

@media print {

    .product-tabs-title,
    .product-nav-tabs,
    .product-similar,
    .product-sidebar,
    .product-buy,
    .slider-control-btn {
        display: none !important;
    }

    .product-tab-content {
        border: none;
        padding: 0;
    }
}

/* ==========================================
   13. RESPONSIVE: Tablet (max-width: 960px)
   ========================================== */

@media (max-width: 960px) {
    .product-header {
        margin-bottom: 20px;
    }

    .product-header h1 {
        font-size: 1.5em;
        line-height: 1.3;
        margin-bottom: 12px;
    }

    .brand-official-badge {
        margin-top: 15px;
        width: 100%;
        justify-content: center;
    }

    .product-main-img {
        height: auto;
        min-height: 300px;
        aspect-ratio: 1 / 1;
    }

    .product-info-wrapper {
        margin-top: 20px;
    }

    .product-price {
        font-size: 24px;
    }

    .product-nav-tabs {
        flex-wrap: nowrap;
        gap: 5px;
    }

    .product-nav-tabs li:first-child {
        padding-left: 1em;
    }

    .product-nav-tabs li {
        flex: 0 0 auto;
        padding: 0;
    }

    .product-nav-tabs li a,
    .product-nav-tabs li a:first-child {
        padding: 0.6rem 1rem;
    }

    .product-tabs-sticky-wrapper {
        width: 100%;
    }

    .product-tabs-title .uk-container {
        padding-left: var(--uk-container-padding, 15px);
        padding-right: var(--uk-container-padding, 15px);
    }

    .product-tab-content {
        padding: 0
    }

    .product-card-slider-item {
        min-width: 280px;
    }
}

/* ==========================================
   14. RESPONSIVE: Mobile (max-width: 640px)
   ========================================== */

@media (max-width: 640px) {

    /* --- Header --- */
    .product-header {
        margin-bottom: 12px;
    }

    .product-info {
        font-size: 1em;
    }

    /* --- Gallery --- */
    .product-main-img {
        min-height: 250px;
    }

    .product-gallery-slider img {
        height: 70px;
    }

    /* --- Navigation tabs --- */
    /* .product-tabs-nav-scroll {
        width: 100%;
        padding: .3em 0;
        margin: 0;
        overflow: hidden;
        flex-wrap: nowrap;
        align-content: center;
        justify-content: flex-start;
    } */

    .product-nav-tabs li:first-child {
        padding-left: 1em
    }

    .product-nav-tabs li {
        padding-left: 5px;
    }

    .product-nav-tabs.uk-subnav>*> :first-child {
        font-size: 13px;
        padding: 0.45rem 0.75rem;
        white-space: nowrap;
    }

    .product-tabs-sticky-wrapper {
        border-radius: 0;
    }

    .product-tabs-title {
        margin-left: 0;
        margin-right: 0;
        padding: 0;
        border-bottom: 1px solid #e5e5e5;
    }

    /* На мобильных: dealer сжимается, показываем только логотип */
    .product-dealer-col {
        padding-left: 6px;
    }

    .product-dealer-col .brand-official-badge>span {
        display: none;
        /* Скрываем текст «Официальный дилер» на мобильных, остаётся только лого */
    }

    /* Стрелки на мобильных: всегда видимы, т.к. hover недоступен на touch-устройствах.
       UIKit3 click-события уже привязаны, tap по кнопке скроллирует список. */
    .product-tabs-scroller:not(.hidden) .product-tabs-scroller-btn {
        opacity: 1;
        pointer-events: auto;
        /* Увеличиваем tap-target до рекомендованных 44px (WCAG 2.1) */
        min-width: 40px;
        min-height: 40px;
        width: 40px;
        height: 40px;
    }

    /* Уже-градиент на мобильных — освобождаем пространство под табы */
    .product-tabs-scroller-left {
        padding-right: 8px;
        background: linear-gradient(90deg, #fff 50%, rgba(255, 255, 255, 0) 100%);
    }

    .product-tabs-scroller-right {
        padding-left: 8px;
        background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0%, #fff 50%);
    }

    .product-tabs-sticky-wrapper.uk-sticky-fixed .product-nav-tabs {
        gap: 4px;
    }

    /* --- Price & buy --- */
    .product-price {
        font-size: 22px;
    }

    .product-buy {
        padding: 15px;
    }

    .product-buy .uk-grid {
        flex-direction: column;
        gap: 10px;
    }

    .quantity-selector {
        max-width: none;
        display: flex;
    width: 100%;
    background: transparent;
    flex-direction: column;
    flex-wrap: nowrap;
    align-content: center;
    justify-content: center;
    align-items: center;
    }

    .quantity-selector .quantity-wrapper {
        justify-content: flex-start;
    }

    .quantity-selector .item-count-wrapper,
    .quantity-selector .input-quantity {
        width: 56px !important;
        min-width: 56px;
    }

    .product-buy .quantity-selector .quantity-btn {
        width: 44px !important;
        min-width: 44px !important;
        height: 44px !important;
    }

    .product-buy-buttons,
    .product-buy-buttons .jbprice-buttons {
        width: 100%;
        flex-direction: column;
    }

    .product-buy-buttons .jbprice-buttons-add,
    .product-buy-buttons .jbprice-buttons-goto,
    .product-quick-order {
        width: 100%;
        min-height: 44px;
    }

    .product-buy .uk-width-auto\@s {
        width: 100%;
    }

    .product-buy button,
    .product-quick-order {
        width: 100%;
        justify-content: center;
        min-height: 44px;
    }

    /* --- Info sections --- */
    .product-features,
    .product-shipping,
    .product-payment {
        padding: 12px;
    }

    /* --- Sliders --- */
    .product-card-slider-item {
        min-width: 240px;
        padding: 10px;
    }

    .product-similar {
        padding: 20px 10px;
    }

    .slider-control-btn,
    .tm-slidenav {
        width: 44px;
        height: 44px;
        background: rgba(0, 0, 0, 0.7);
    }

    .article-card .article-img {
        height: 150px;
    }

    /* --- Content tabs --- */
    .product-tab-content {
        font-size: 15px;
        line-height: 1.6;
    }

    .product-tab-content h2 {
        font-size: 20px;
        margin-bottom: 15px;
    }

    .product-tab-content p {
        margin-bottom: 12px;
    }

    .product-tab-content ul,
    .product-tab-content ol {
        padding-left: 20px;
    }

    .product-tab-content li {
        margin-bottom: 8px;
    }

    .product-tab-content table {
        display: block;
        width: 100%;
        overflow-x: auto;
    }

    .product-tab-content table tr {
        display: flex;
        flex-direction: column;
        border-bottom: 1px solid #e5e5e5;
        padding: 10px 0;
    }

    .product-tab-content table td,
    .product-tab-content table th {
        display: block;
        width: 100%;
        padding: 5px 0;
        border: none;
    }

    .product-tab-content table th {
        font-weight: bold;
        color: #038096;
        margin-bottom: 3px;
    }

    /* --- Collapsible sections --- */
    .section-toggle {
        padding: 8px 12px;
        font-size: 14px;
    }

    section.product-tab-content.collapsed .section-toggle-wrap::before {
        bottom: 44px;
        height: 40px;
    }

    /* --- Accessibility: touch targets --- */
    .product-nav-tabs a,
    .section-toggle {
        min-height: 44px;
        min-width: 44px;
    }
}