/* Product Single — dealer.international
   Depends on: components.css
   Loads conditionally on is_product().
   Source of truth: PRODUCT-SINGLE-SYSTEM.md */

/* =========================================================================
   @font-face — NoticeIII (cares list icons)
   ========================================================================= */

@font-face {
    font-family: "NoticeIII";
    src: url("../fonts/NoticeIII.woff") format("woff");
    font-display: swap;
    font-weight: normal;
    font-style: normal;
}

/* =========================================================================
   Storefront resets — neutralize parent theme product page chrome
   ========================================================================= */

.single-product .site-content > .col-full {
    max-width: var(--container-max);
    padding-inline: var(--padding-mobile);
    margin: 0 auto;
}

.single-product div.product .woocommerce-product-gallery,
.single-product div.product .summary {
    width: 100%;
    margin: 0;
    float: none;
}

/* Storefront's desktop full-width product layout targets `.summary` with
   higher specificity (`.storefront-full-width-content.single-product ...`).
   Our visual frame owns the two-column layout, so the WooCommerce summary
   wrapper must behave as a normal grid item inside the frame. */
.single-product div.product .dealer-single-frame > .summary {
    width: 100%;
    margin: 0;
    float: none;
}

/* Storefront adds clearfix pseudo-elements to `div.product`. Because the
   product container is our CSS Grid shell, those pseudo-elements would become
   anonymous grid items. Keep the parent reset local to the product page. */
.single-product div.product::before,
.single-product div.product::after {
    content: none;
    display: none;
}

/* =========================================================================
   Product Single — local design tokens (homepage-style scoping)
   ========================================================================= */

.single-product div.product {
    --single-gap-block: 20px;
    --single-gap-summary: 20px;
    --single-summary-max: 100%;
    --single-divider-color: rgba(0, 0, 0, 0.12);
    --single-meta-color: rgba(0, 0, 0, 0.55);
    --single-stock-color: var(--color-error);
    --single-frame-max: 1280px;
    --single-frame-radius: 5px;
    --single-frame-shadow: none;
    --single-frame-shadow-gutter: 0px;
    --single-frame-padding-y: 0px;
    --single-frame-padding-x: 0px;
    --single-frame-gap: 20px;
    --single-gallery-thumb-size: 88px;
    --single-gallery-main-aspect: 344 / 474;
    --single-gallery-main-max: 100%;
    --single-gallery-main-radius: 0;
    --single-gallery-thumb-aspect: 519 / 650;

    display: grid;
    grid-template-columns: 1fr;
    gap: var(--single-gap-block);
    width: 100%;
    margin: 0;
    padding-block: 20px 40px;
}

/* Breadcrumbs — single full-width row at the top of the page, above the
   product card, on every breakpoint (`woocommerce_before_single_product`).
   Mobile/tablet: left-aligned so a long trail reads from "Головна" and scrolls
   from the start. Desktop (>=1024px): centered horizontally (Symbol-style). */
.single-product .dealer-breadcrumbs--top {
    margin: 12px 0;
}

@media (min-width: 1024px) {
    .single-product .dealer-breadcrumbs--top {
        /* Breadcrumbs own the top-of-page spacing now (they are the first
           element, above the product card). Symmetric margin + zeroed
           `.product` padding-top below → equal gap above and below. */
        margin: 24px 0;
    }

    .single-product .dealer-breadcrumbs--top .dealer-breadcrumbs__inner {
        text-align: center;
    }
}

.dealer-single-frame {
    display: grid;
    grid-template-columns: 1fr;
    gap: var(--single-frame-gap);
    width: min(calc(100% - (var(--single-frame-shadow-gutter) * 2)), var(--single-frame-max));
    margin-inline: auto;
    padding: var(--single-frame-padding-y) var(--single-frame-padding-x);
    background: var(--color-white);
    border-radius: var(--single-frame-radius);
    box-shadow: var(--single-frame-shadow);
    overflow: hidden;
    align-items: start;
}

/* =========================================================================
   Layout — two-column on desktop, stacked on mobile/tablet
   ========================================================================= */

.dealer-single-gallery,
.dealer-single-frame > .summary,
.dealer-single-summary {
    width: 100%;
    grid-column: 1;
}

.dealer-single-summary {
    display: flex;
    flex-direction: column;
    gap: var(--single-gap-summary);
    max-width: var(--single-summary-max);
}

/* =========================================================================
   Gallery
   ========================================================================= */

.dealer-single-gallery {
    display: grid;
    grid-template-columns: 1fr;
    gap: 12px;
}

.dealer-single-gallery--empty .dealer-single-gallery__main {
    background: #f5f5f5;
    aspect-ratio: var(--single-gallery-main-aspect);
}

.dealer-single-gallery__thumbs {
    display: none;
    margin: 0;
    padding: 0;
    list-style: none;
}

.dealer-single-gallery__thumb-button {
    display: block;
    width: 100%;
    margin: 0;
    padding: 0;
    border: 0;
    background: transparent;
    cursor: pointer;
    box-shadow: none;
}

.dealer-single-gallery__thumb-image {
    display: block;
    width: 85px;
    height: 85px;
    background: white;
    object-fit: contain;
    border-radius: 0;
    opacity: 0.4;
    transition: opacity 0.15s ease;
}

/* Active thumb stays full; inactive thumbs dim. Hover/focus restore for affordance. */
.dealer-single-gallery__thumb.is-active .dealer-single-gallery__thumb-image,
.dealer-single-gallery__thumb-button:hover .dealer-single-gallery__thumb-image,
.dealer-single-gallery__thumb-button:focus-visible .dealer-single-gallery__thumb-image {
    opacity: 1;
}

.dealer-single-gallery__main {
    position: relative;
    width: 100%;
}

.dealer-single-gallery__viewport {
    position: relative;
    width: 100%;
    max-width: var(--single-gallery-main-max);
    aspect-ratio: var(--single-gallery-main-aspect);
    justify-self: center;
    background: #f5f5f5;
    border-radius: var(--single-gallery-main-radius);
    overflow: hidden;
}

.dealer-single-gallery__slides {
    position: relative;
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    list-style: none;
}

.dealer-single-gallery__slide {
    position: absolute;
    inset: 0;
    display: none;
}

.dealer-single-gallery__slide.is-active {
    display: block;
}

.dealer-single-gallery__image {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Decorative overlay — arrows are an exception to the web-native rule */
.dealer-single-gallery__nav {
    position: absolute;
    z-index: 2;
    top: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    padding: 0;
    border: 0;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 50%;
    color: var(--color-black);
    cursor: pointer;
    transform: translateY(-50%);
    transition: background-color 0.15s ease;
}

.dealer-single-gallery__nav:hover {
    background: rgba(255, 255, 255, 1);
}

.dealer-single-gallery__nav--prev {
    left: 12px;
}

.dealer-single-gallery__nav--next {
    right: 12px;
}

.dealer-single-gallery__dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin: 12px 0 0;
    padding: 0;
    list-style: none;
}

.dealer-single-gallery__dot-button {
    width: 8px;
    height: 8px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.3);
    cursor: pointer;
}

.dealer-single-gallery__dot.is-active .dealer-single-gallery__dot-button {
    background: var(--color-black);
}

/* Lightbox — fullscreen overlay for active gallery image */
.dealer-single-lightbox {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(0, 0, 0, 0.92);
}

.dealer-single-lightbox[hidden] {
    display: none;
}

.dealer-single-lightbox__stage {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.dealer-single-lightbox__image {
    display: block;
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.dealer-single-lightbox__close {
    position: absolute;
    top: 20px;
    right: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: var(--color-white);
    cursor: pointer;
}

.dealer-single-lightbox__close:hover {
    background: rgba(255, 255, 255, 0.2);
}

.dealer-single-lightbox__close:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 2px;
}

.dealer-single-lightbox__nav {
    position: absolute;
    z-index: 1;
    top: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: var(--color-white);
    cursor: pointer;
    transform: translateY(-50%);
    transition: background-color 0.15s ease;
}

.dealer-single-lightbox__nav:hover {
    background: rgba(255, 255, 255, 0.22);
}

.dealer-single-lightbox__nav:focus-visible {
    outline: 2px solid var(--color-white);
    outline-offset: 2px;
}

.dealer-single-lightbox__nav--prev {
    left: 16px;
}

.dealer-single-lightbox__nav--next {
    right: 16px;
}

/* =========================================================================
   Summary — brand, title, price, stock label
   ========================================================================= */

.dealer-single-summary__header {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.dealer-single-summary__brand {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 18px;
    font-weight: 600;
    line-height: 1.2;
}

.dealer-single-summary__title,
.single-product .dealer-single-summary__title,
.single-product .dealer-single-summary h1.dealer-single-summary__title {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-light);
    line-height: 1.3;
    letter-spacing: 0;
    text-transform: none;
}

.dealer-single-summary__price {
    margin-top: 8px;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: var(--font-weight-medium);
    line-height: 1.5;
}

.dealer-single-summary__price del {
    color: var(--color-black);
    text-decoration-thickness: 1px;
    margin-right: 8px;
}

.dealer-single-summary__price ins {
    text-decoration: none;
    color: var(--color-error);
}

.dealer-single-summary__stock-label {
    margin: 4px 0 0;
    color: var(--single-stock-color);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-medium);
}

/* =========================================================================
   Size row — size-chart link, "no size" link, wishlist heart
   ========================================================================= */

.dealer-single-summary__size-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.dealer-single-summary__notify-link {
    margin-left: auto;
}

.dealer-single-summary__size-row--dropdown-notify .dealer-single-summary__wishlist {
    margin-left: auto;
}

.dealer-single-summary__wishlist {
    display: inline-flex;
    margin-left: 12px;
}

.dealer-single-summary__wishlist .dealer-product-card__wishlist,
.single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist {
    position: static;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    min-width: 0;
    min-height: 0;
    padding: 0;
    border: 0;
    border-radius: 50%;
    background: transparent;
    box-shadow: none;
    color: var(--color-black);
    cursor: pointer;
    line-height: 0;
}

.dealer-single-summary__wishlist .dealer-product-card__wishlist:hover,
.single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist:hover {
    background: transparent;
    color: var(--color-black);
    transform: none;
    box-shadow: none;
}

.dealer-single-summary__wishlist .dealer-product-card__wishlist-icon,
.single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist-icon {
    display: block;
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

/* =========================================================================
   Form / Add to cart
   ========================================================================= */

.dealer-single-summary__form {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

/* Hide quantity input — design uses fixed qty 1.
   `!important` is required: WC's frontend JS sets inline display on .quantity. */
.dealer-single-summary__form .quantity {
    display: none !important;
}

/* Single add-to-cart button uses the shared .btn-primary .btn-full variant.
   The variation-add-to-cart-button.php override (in dealer-child/woocommerce/)
   adds those classes to the WC-rendered <button>; the Storefront .button.alt
   shim in base.css neutralizes the parent theme's purple skin. */
.dealer-single-summary__form button.single_add_to_cart_button.disabled,
.dealer-single-summary__form button.single_add_to_cart_button.wc-variation-selection-needed {
    opacity: var(--btn-disabled-opacity);
    cursor: not-allowed;
}

.single-product div.product .dealer-single-summary__form button.single_add_to_cart_button.wc-variation-selection-needed {
    opacity: 1;
    cursor: pointer;
    pointer-events: auto;
    background-color: var(--color-primary);
}

.single-product div.product .dealer-single-summary__form button.single_add_to_cart_button.disabled.wc-variation-selection-needed {
    /* Storefront sets `.button.disabled { opacity: .5 !important; }`.
       This state is clickable only to explain missing variation choices. */
    opacity: 1 !important;
    cursor: pointer;
    pointer-events: auto;
    background-color: var(--color-primary);
    color: var(--color-white);
}

.single-product div.product .dealer-single-summary__form button.single_add_to_cart_button {
    border-radius: 5px;
}

.dealer-single-add-error {
    display: block;
    margin-top: 10px;
    color: var(--color-error);
    font-family: var(--font-family);
    font-size: 15px;
    font-weight: var(--font-weight-medium);
    line-height: 1.5;
}

/* Storefront gives the native single-product cart form extra padding/margins.
   The dealer summary owns spacing through its local flex gaps instead. */
.single-product div.product .dealer-single-summary__form form.cart {
    margin: 0;
    padding: 0;
}

.single-product div.product .dealer-single-summary__form .variations_button {
    padding-top: 0;
}

/* =========================================================================
   Variations table — replace WC default <table> chrome with clean stacks
   ========================================================================= */

.single-product div.product .dealer-single-summary__form table.variations {
    display: flex;
    flex-direction: column;
    gap: 15px;
    width: 100%;
    margin: 0 0  25px;
    border: 0;
    background: transparent;
}

.single-product div.product .dealer-single-summary__form table.variations tbody,
.single-product div.product .dealer-single-summary__form table.variations tr {
    display: contents;
}

.single-product div.product .dealer-single-summary__form table.variations th.label,
.single-product div.product .dealer-single-summary__form table.variations td.value {
    display: block;
    width: 100%;
    padding: 0;
    border: 0;
    background: transparent;
    text-align: left;
}

.woo-selected-variation-item-name {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-semibold);
    line-height: 1;
}
.single-product div.product .dealer-single-summary__form table.variations .value {
    margin-bottom: 0;
}

.single-product div.product .dealer-single-summary__form table.variations select {
    max-width: 100%;
}

.single-product div.product .dealer-single-summary__form table.variations th.label label {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-semibold);
    line-height: 1;
}

/* "Reset" link that WC injects under variations — hide, redundant for our UX */
.dealer-single-summary__form .reset_variations,
.dealer-single-summary__form a.reset_variations {
    display: none !important;
}

/* =========================================================================
   Size dropdown shell — desktop/tablet dropdown, mobile inline grid.
   The shell wraps the plugin's button list. Toggle is mobile-hidden, panel
   stays inline on mobile (grid) and collapses on tablet+desktop (dropdown).
   ========================================================================= */

.dealer-size-dropdown {
    position: relative;
    width: 100%;
}

.dealer-size-dropdown__toggle {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    width: 100%;
    height: 50px;
    padding: 0 20px;
    margin: 0;
    border: 1px solid var(--color-black);
    border-radius: 5px;
    background: var(--color-white);
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 15px;
    font-weight: 500;
    line-height: 1;
    text-align: left;
    cursor: pointer;
    box-shadow: none;
    transition: border-color 0.15s ease;
}

.dealer-size-dropdown__toggle:hover {
    border: 1px solid var(--color-primary);
    background: var(--color-white);
}

.dealer-size-dropdown__toggle:focus-visible {
    outline: 1px solid var(--color-primary);
    outline-offset: 1px;
}

.dealer-size-dropdown__label {
    flex: 1 1 auto;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dealer-size-dropdown__arrow {
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--color-black);
    transition: transform 0.2s ease;
}

.dealer-size-dropdown[data-state="open"] .dealer-size-dropdown__arrow {
    transform: rotate(180deg);
}

.dealer-size-dropdown__panel {
    display: none;
    width: 100%;
    margin: 0;
    padding: 0;
    background: var(--color-white);
}

.dealer-size-dropdown[data-state="open"] .dealer-size-dropdown__panel {
    display: block;
}

.dealer-size-dropdown__notify {
    display: flex;
    width: 100%;
    margin: 5px 0px 0px 5px;
    padding: 10px 0 0;
    font-size: 14px;
}
.dealer-size-dropdown__notify:hover {
    background: var(--color-white);
}

/* =========================================================================
   Size selector — button swatches (pa_rozmir, plugin-rendered).
   ========================================================================= */

.dealer-single-summary__form .button-variable-items-wrapper {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(70px, 1fr));
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.dealer-single-summary__form .button-variable-items-wrapper .variable-item.button-variable-item,
.single-product .dealer-single-summary__form .variable-item.button-variable-item {
    display: flex;
    align-items: center;
    justify-content: center;
    min-width: 0;
    width: auto;
    height: 50px;
    padding: 0 10px;
    margin: 0;
    border: 1px solid rgba(0, 0, 0, 0.65);
    border-radius: 5px;
    background: var(--color-white);
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: 500;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.15s ease, background-color 0.15s ease;
    box-shadow: none;
}

.dealer-single-summary__form .variable-item.button-variable-item:hover {
    border-color: var(--color-black);
}

.dealer-single-summary__form .variable-item.button-variable-item .variable-item-contents,
.dealer-single-summary__form .variable-item.button-variable-item .variable-item-span,
.dealer-single-summary__form .variable-item.button-variable-item .variable-item-span-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: auto;
    height: auto;
    color: inherit;
    font: inherit;
    background: transparent;
    border: 0;
}

.dealer-single-summary__form .variable-item.button-variable-item.selected,
.dealer-single-summary__form .variable-item.button-variable-item.selected:hover {
    background: var(--color-black);
    border-color: var(--color-black);
    color: var(--color-white);
}

.dealer-single-summary__form .variable-item.button-variable-item.disabled,
.dealer-single-summary__form .variable-item.button-variable-item.wvs-disabled,
.dealer-single-summary__form .variable-item.button-variable-item[aria-disabled="true"] {
    color: rgba(0, 0, 0, 0.35);
    background-image: none;
    cursor: not-allowed;
    text-decoration: line-through;
    pointer-events: none;
    opacity: 1;
}

.dealer-single-summary__form .variable-item.button-variable-item.disabled .variable-item-contents,
.dealer-single-summary__form .variable-item.button-variable-item.disabled .variable-item-span,
.dealer-single-summary__form .variable-item.button-variable-item.wvs-disabled .variable-item-contents,
.dealer-single-summary__form .variable-item.button-variable-item.wvs-disabled .variable-item-span {
    background-image: none;
}

/* =========================================================================
   Color swatches — square color tiles (pa_kolir, plugin-rendered).
   ========================================================================= */

.dealer-single-summary__form .color-variable-items-wrapper {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin: 0 0 0 5px;
    padding: 0;
    list-style: none;
}

.dealer-single-summary__form .variable-item.color-variable-item,
.single-product .dealer-single-summary__form .variable-item.color-variable-item {
    width: 30px;
    height: 30px;
    margin: 0;
    padding: 0;
    border: 1px solid rgba(0, 0, 0, 1);
    border-radius: 4px;
    background: var(--color-white);
    cursor: pointer;
    transition: outline 0.15s ease, border-color 0.15s ease;
    box-shadow: none;
    overflow: hidden;
}

.dealer-single-summary__form .variable-item.color-variable-item:hover {
    border-color: var(--color-black);
}

.dealer-single-summary__form .variable-item.color-variable-item .variable-item-contents,
.dealer-single-summary__form .variable-item.color-variable-item .variable-item-span,
.dealer-single-summary__form .variable-item.color-variable-item .variable-item-span-color {
    display: block;
    width: 100%;
    height: 100%;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.dealer-single-summary__form .variable-item.color-variable-item.selected {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
    border-color: var(--color-white);
}

.dealer-single-summary__form .variable-item.color-variable-item.disabled,
.dealer-single-summary__form .variable-item.color-variable-item.wvs-disabled,
.dealer-single-summary__form .variable-item.color-variable-item[aria-disabled="true"] {
    opacity: 0.35;
    cursor: not-allowed;
    pointer-events: none;
}

/* WC variation single price/availability messages */
.dealer-single-summary__form .woocommerce-variation,
.dealer-single-summary__form .single_variation {
    margin: 12px 0;
}

.dealer-single-summary__form .woocommerce-variation-price {
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
}

/* Hide the per-variation stock count line ("5 на складі") that WC's
   wc-add-to-cart-variation.js injects after the user picks all attributes.
   The summary already renders an explicit "Немає у наявності" label for
   the OOS state; the in-stock count is noise per design. */
.dealer-single-summary__form .woocommerce-variation-availability {
    display: none !important;
}

/* =========================================================================
   Details — description + care icons + article/color
   ========================================================================= */

.dealer-single-summary__details {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-top: 10px;
}

.dealer-single-summary__details-title {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: var(--font-weight-semibold);
    line-height: 1.3;
}

/* Ingredients ("Склад") — value only, styled like the description (black),
   so it doesn't read like the muted meta lines (article / design color). */
.dealer-single-summary__ingredients {
    margin: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
}

.dealer-single-summary__description {
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
    padding-bottom: 10px;
}

.dealer-single-summary__description p {
    margin: 0 0 8px;
}

.dealer-single-summary__description p:last-child {
    margin-bottom: 0;
}

.dealer-single-summary__description ul {
    margin: 6px 0;
    padding-left: 22px;
    list-style: disc;
}

.dealer-single-summary__description li {
    margin-bottom: 2px;
}

.dealer-care-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.dealer-care-list__item {
    position: relative;
    display: inline-flex;
}

.dealer-care-icon {
    position: relative;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    color: var(--color-black);
    font-family: "NoticeIII", monospace;
    font-size: 35px;
    line-height: 1;
}

.dealer-care-icon:focus {
    outline: 1px solid currentColor;
    outline-offset: 3px;
}

.dealer-care-icon::after {
    position: absolute;
    z-index: 3;
    bottom: calc(100% + 8px);
    left: 50%;
    width: max-content;
    max-width: min(260px, calc(100vw - 32px));
    padding: 7px 9px;
    border: 1px solid var(--color-black);
    background: var(--color-white);
    color: var(--color-black);
    content: attr(data-care-label);
    font-family: var(--font-family);
    font-size: 12px;
    font-weight: 500;
    line-height: 1.35;
    opacity: 0;
    pointer-events: none;
    text-align: left;
    transform: translateX(-50%) translateY(2px);
    transition: opacity 160ms ease, transform 160ms ease;
}

.dealer-care-icon:hover::after,
.dealer-care-icon:focus::after {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.dealer-care-list__status {
    display: none;
    margin: -2px 0 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 13px;
    font-weight: 500;
    line-height: 1.45;
}

.dealer-single-summary__sku {
    margin: 0;
    color: var(--single-meta-color);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: 500;
    line-height: 1.5;
}

/* =========================================================================
   Divider + returns link
   ========================================================================= */

.dealer-single-summary__divider {
    width: 100%;
    height: 1px;
    margin: 8px 0;
    border: 0;
    background: var(--single-divider-color);
}

.dealer-single-summary__returns {
    align-self: flex-start;
}

/* =========================================================================
   Out-of-stock state — notify CTA
   ========================================================================= */

.dealer-single-summary__cta {
    display: flex;
}

/* Out-of-stock notify CTA uses the shared .btn-outline-light .btn-full variant.
   No local styling — the dealer-single-summary__notify-cta class is kept
   only as a JS hook for the modal opener. */

/* =========================================================================
   Notify modal — "Повідомте мене" (open/close + AJAX submit).
   Shared dialog shell styles live in components.css.
   ========================================================================= */

/* Notify form */

.dealer-notify-form {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin: 0;
    padding: 0;
    border: 0;
}

.dealer-notify-form__sizes {
    margin: 0;
    padding: 0;
    border: 0;
}

.dealer-notify-form__legend {
    margin: 0 0 10px;
    padding: 0;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-light);
    line-height: 1.4;
}

.dealer-notify-form__size-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.dealer-notify-form__size {
    position: relative;
    display: block;
    cursor: pointer;
}

.dealer-notify-form__size-input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    margin: 0;
    opacity: 0;
    cursor: pointer;
}

.dealer-notify-form__size-label {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 50px;
    padding: 0 8px;
    border: 1px solid rgba(0, 0, 0, 0.18);
    border-radius: 8px;
    background: var(--color-white);
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: var(--font-weight-medium);
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.dealer-notify-form__size:hover .dealer-notify-form__size-label {
    border-color: var(--color-black);
}

.dealer-notify-form__size-input:checked + .dealer-notify-form__size-label {
    background: var(--color-black);
    border-color: var(--color-black);
    color: var(--color-white);
}

.dealer-notify-form__size-input:focus-visible + .dealer-notify-form__size-label {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.dealer-notify-form__field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.dealer-notify-form__field-label {
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-medium);
}

.dealer-notify-form__required {
    color: var(--color-error);
    margin-right: 2px;
}

.dealer-notify-form__input {
    width: 100%;
    height: 50px;
    padding: 12px 16px;
    border: 1px solid rgba(0, 0, 0, 0.18);
    border-radius: 10px;
    background: var(--color-white);
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 16px;
    font-weight: var(--font-weight-light);
    line-height: 1.2;
}

.dealer-notify-form__input:focus {
    border-color: var(--color-primary);
    outline: none;
}

.dealer-notify-form__legal {
    margin: 0;
    color: rgba(0, 0, 0, 0.55);
    font-family: var(--font-family);
    font-size: 12px;
    font-weight: var(--font-weight-light);
    line-height: 1.5;
}

.dealer-notify-form__legal a {
    color: inherit;
    text-decoration: none;
}

.dealer-notify-form__legal a:hover {
    text-decoration: underline;
}

.dealer-notify-form__status {
    margin: 0;
    min-height: 20px;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-medium);
    line-height: 1.4;
}

.dealer-notify-form__status[data-state="error"] {
    color: var(--color-error);
}

.dealer-notify-form__status[data-state="success"] {
    color: var(--color-primary);
}

/* Notify-modal submit button uses the shared .btn-primary .btn-full variant.
   No local styling — the dealer-notify-form__submit class is kept only as
   a JS hook for the AJAX submit handler. */

/* =========================================================================
   Related sections — Recommendations / Brand / Recently viewed.
   Each section is a row of shared product cards, responsive grid.
   ========================================================================= */

.single-product div.product .dealer-single-related {
    grid-column: 1 / -1;
    width: 100%;
    min-width: 0;
    margin-top: 30px;
}

.dealer-single-related__inner {
    display: flex;
    flex-direction: column;
    gap: 30px;
}

.dealer-single-related__row {
    width: 100%;
}

.dealer-single-related__title {
    margin: 0 0 16px;
    color: var(--color-black);
    font-family: var(--font-family);
    font-size: 14px;
    font-weight: var(--font-weight-medium);
    line-height: 1.5;
}

/* =========================================================================
   Responsive — Tablet (>= 768px)
   ========================================================================= */

/* =========================================================================
   Mobile-only — keep the size list inline as a grid (no dropdown UI)
   ========================================================================= */

@media (max-width: 767px) {
    .dealer-single-frame {
        border-radius: 0;
    }

    .dealer-single-gallery__viewport,
    .dealer-single-gallery__image {
        border-radius: 0;
    }

    .dealer-care-icon::after {
        content: none;
    }

    .dealer-care-icon.is-active {
        outline: 1px solid currentColor;
        outline-offset: 3px;
    }

    .dealer-care-list__status:not(:empty) {
        display: block;
    }

    .dealer-size-dropdown__toggle {
        display: none;
    }

    .dealer-size-dropdown__panel {
        display: block;
        position: static;
        margin: 0;
        padding: 0;
        border: 5;
        background: transparent;
        box-shadow: none;
    }
}

@media (min-width: 768px) {
    .single-product .site-content > .col-full {
        padding-inline: var(--padding-tablet);
    }

    .single-product div.product {
        --single-frame-gap: 24px;
        --single-gallery-main-aspect: 519 / 650;
        --single-gallery-main-max: 519px;
        --single-gallery-main-radius: 10px;

        padding-block: 32px 56px;
    }

    /* Desktop+tablet: dropdown panel becomes an absolute popover */
    .dealer-size-dropdown__panel {
        position: absolute;
        top: calc(100% + 10px);
        left: 0;
        right: 0;
        z-index: 5;
        padding: 20px 20px 30px 20px;
        border: 1px solid var(--color-black);
        border-radius: 5px;
        box-shadow: 0 2px 12px rgba(0, 0, 0, 0.1);
    }

    /* Inside the dropdown panel: list becomes a vertical stack of plain rows */
    .dealer-size-dropdown__panel .button-variable-items-wrapper {
        display: flex;
        flex-direction: column;
        gap: 10;
    }

    .dealer-size-dropdown__panel .variable-item.button-variable-item {
        height: 36px;
        padding: 0 8px;
        border: 0;
        border-radius: 5px;
        background: transparent;
        font-weight: var(--font-weight-light);
        justify-content: flex-start;
        text-align: left;
    }

    .dealer-size-dropdown__panel .variable-item.button-variable-item:hover {
        background: rgba(0, 0, 0, 0.04);
        border-color: transparent;
    }

    .dealer-size-dropdown__panel .variable-item.button-variable-item.selected,
    .dealer-size-dropdown__panel .variable-item.button-variable-item.selected:hover {
        background: rgba(0, 0, 0, 0.08);
        color: var(--color-black);
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .button-variable-items-wrapper {
        display: flex;
        flex-direction: column;
        gap: 0;
        margin: 0;
        padding: 0;
        list-style: none;
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item {
        display: flex;
        align-items: left;
        justify-content: flex-start;
        width: 100%;
        min-width: 0;
        height: 50px;
        margin-bottom: 10px;
        padding: 0 10px;
        border: 1;
        border-radius: 5px;
        background: transparent;
        color: var(--color-black);
        box-shadow: none;
        font-family: var(--font-family);
        font-size: 16px;
        font-weight: 500;
        line-height: 1;
        text-align: left;
        text-decoration: none;
        transform: none;
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item .variable-item-contents,
    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item .variable-item-span,
    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item .variable-item-span-button {
        display: inline-flex;
        align-items: center;
        justify-content: flex-start;
        width: auto;
        height: auto;
        color: inherit;
        background: transparent;
        border: 0;
        box-shadow: none;
        font: inherit;
        line-height: inherit;
        text-align: left;
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item:hover {
        border-color: transparent;
        background: rgba(0, 0, 0, 0.04);
        color: var(--color-black);
        box-shadow: none;
        transform: none;
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item.selected,
    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item.selected:hover {
        border-color: transparent;
        background: rgba(0, 0, 0, 0.08);
        color: var(--color-black);
        box-shadow: none;
    }

    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item.disabled,
    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item.wvs-disabled,
    .single-product .dealer-single-summary__form .dealer-size-dropdown__panel .variable-item.button-variable-item[aria-disabled="true"] {
        background: transparent;
        color: rgba(0, 0, 0, 0.35);
        box-shadow: none;
        cursor: not-allowed;
        opacity: 1;
        pointer-events: none;
        text-decoration: line-through;
    }

    .dealer-single-gallery {
        grid-template-columns: var(--single-gallery-thumb-size) 1fr;
        gap: 16px;
    }

    .dealer-single-gallery[data-slide-count="0"],
    .dealer-single-gallery[data-slide-count="1"] {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .dealer-single-gallery[data-slide-count="0"] .dealer-single-gallery__main,
    .dealer-single-gallery[data-slide-count="1"] .dealer-single-gallery__main {
        grid-column: 1;
        width: 100%;
    }

    .dealer-single-gallery__thumbs {
        display: flex;
        flex-direction: column;
        gap: 0px;
    }

    .dealer-single-gallery__thumb {
        width: var(--single-gallery-thumb-size);
        aspect-ratio: var(--single-gallery-thumb-aspect);
    }

    .dealer-single-gallery__nav {
        width: 44px;
        height: 44px;
    }

    .dealer-single-gallery__dots {
        display: none;
    }

    .dealer-single-summary__wishlist .dealer-product-card__wishlist-icon,
    .single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist-icon {
        width: 16px;
        height: 16px;
    }

    .dealer-single-summary__brand {
        font-size: 22px;
    }

    .dealer-single-summary__title {
        font-size: 20px;
    }

    .dealer-single-summary__price {
        font-size: 16px;
        padding-bottom: 20px;
    }

    .single-product div.product .dealer-single-related {
        margin-top: 40px;
    }

    .dealer-single-related__inner {
        gap: 40px;
    }

    .dealer-single-related__title {
        font-size: 16px;
    }
}

@media (min-width: 768px) and (max-width: 1023px) {
    .dealer-care-icon::after {
        content: none;
    }

    .dealer-care-icon.is-active {
        outline: 1px solid currentColor;
        outline-offset: 3px;
    }

    .dealer-care-list__status:not(:empty) {
        display: block;
    }
}

/* =========================================================================
   Responsive — Desktop (>= 1024px)
   ========================================================================= */

@media (min-width: 1024px) {
    .single-product .site-content > .col-full {
        padding-inline: var(--padding-desktop);
    }

    .single-product div.product {
        --single-frame-padding-y: 56px;
        --single-frame-padding-x: 20px;
        --single-frame-gap: 30px;
        --single-frame-shadow: 0 4px 4px rgba(0, 0, 0, 0.25);
        --single-frame-shadow-gutter: 4px;
        --single-gallery-thumb-size: 85px;

        grid-template-columns: 1fr;
        /* Top padding moved to the breadcrumb's symmetric margin (above the
           card); keep the 80px bottom for the related rows that follow. */
        padding-block: 0 80px;
    }

    .dealer-single-frame {
        grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
    }

    .dealer-single-frame > .dealer-single-gallery {
        grid-column: 1;
    }

    .dealer-single-frame > .summary {
        grid-column: 2;
    }

    .dealer-single-gallery {
        grid-template-columns: var(--single-gallery-thumb-size) 1fr;
        gap: 20px;
        align-items: center;
    }

    .dealer-single-gallery[data-slide-count="0"],
    .dealer-single-gallery[data-slide-count="1"] {
        grid-template-columns: 1fr;
    }

    .dealer-single-gallery:not([data-slide-count="0"]):not([data-slide-count="1"]) {
        grid-template-columns: var(--single-gallery-thumb-size) 48px minmax(0, 1fr) 48px;
        column-gap: 10px;
    }

    .dealer-single-gallery:not([data-slide-count="0"]):not([data-slide-count="1"]) .dealer-single-gallery__thumbs {
        grid-column: 1;
        grid-row: 1;
    }

    .dealer-single-gallery:not([data-slide-count="0"]):not([data-slide-count="1"]) .dealer-single-gallery__main {
        display: contents;
    }

    .dealer-single-gallery:not([data-slide-count="0"]):not([data-slide-count="1"]) .dealer-single-gallery__viewport {
        grid-column: 3;
        grid-row: 1;
    }

    .dealer-single-gallery__thumb {
        width: var(--single-gallery-thumb-size);
    }

    .dealer-single-gallery__nav--prev {
        left: auto;
    }

    .dealer-single-gallery__nav--next {
        right: auto;
    }

    .dealer-single-gallery__nav {
        position: static;
        grid-row: 1;
        width: 48px;
        height: 48px;
        background: transparent;
        border-radius: 0;
        transform: none;
    }

    .dealer-single-gallery__nav:hover {
        background: transparent;
        opacity: 0.72;
    }

    .dealer-single-gallery__nav--prev {
        grid-column: 2;
    }

    .dealer-single-gallery__nav--next {
        grid-column: 4;
    }

    .dealer-single-gallery__nav svg {
        width: 36px;
        height: 36px;
    }

    .dealer-single-summary {
        --single-summary-max: 100%;
        gap: 20px;
        padding-top: 20px;
    }

    .dealer-single-summary__brand {
        font-size: 22px;
        font-weight: var(--font-weight-semibold);
    }

    .dealer-single-summary__title,
    .single-product .dealer-single-summary__title,
    .single-product .dealer-single-summary h1.dealer-single-summary__title {
        font-size: 18px;
        font-weight: var(--font-weight-medium);
    }

    .dealer-single-summary__size-row {
        justify-content: space-between;
    }

    .dealer-single-summary__wishlist {
        margin-left: 0;
    }

    .dealer-single-summary__wishlist .dealer-product-card__wishlist-icon,
    .single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist-icon {
        width: 20px;
        height: 20px;
    }

    .dealer-single-summary__wishlist .dealer-product-card__wishlist,
    .single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist {
        width: 32px;
        height: 32px;
    }

    .dealer-single-summary__wishlist .dealer-product-card__wishlist:hover,
    .single-product .dealer-single-summary__wishlist .dealer-product-card__wishlist:hover {
        background: rgba(0, 0, 0, 0.06);
        border-radius: 50%;
    }

    .dealer-single-summary__form table.variations,
    .single-product .dealer-single-summary__form table.variations {
        margin-bottom: 16px;
    }

    .single-product div.product .dealer-single-summary__form table.variations tr:has([data-attribute_name="attribute_pa_rozmir"]) th.label,
    .single-product div.product .dealer-single-summary__form table.variations tr:has([data-attribute_name="attribute_pa_rozmir"]) th.label label {
        display: none;
    }

    .single-product div.product .dealer-single-summary__form table.variations tr:has([data-attribute_name="attribute_pa_kolir"]) {
        display: flex;
        flex-direction: column;
        gap: 8px;
    }

    .dealer-size-dropdown,
    .dealer-size-dropdown__toggle,
    .dealer-single-summary__form,
    .dealer-single-summary__form form.cart,
    .dealer-single-summary__form .variations_form,
    .dealer-single-summary__form .woocommerce-variation-add-to-cart,
    .dealer-single-summary__form button.single_add_to_cart_button {
        width: 100%;
    }

    .dealer-single-summary__divider {
        width: 100%;
        margin-top: 8px;
        margin-bottom: 0;
    }

    .single-product div.product .dealer-single-related {
        margin-top: 50px;
    }

    .dealer-single-related__inner {
        gap: 50px;
    }

    .dealer-single-related__title {
        font-size: 20px;
    }
}

/* =========================================================================
   Reduced motion — disable transitions
   ========================================================================= */

@media (prefers-reduced-motion: reduce) {
    .dealer-single-gallery__nav,
    .dealer-single-lightbox__nav,
    .dealer-single-summary__notify-cta {
        transition: none;
        animation: none;
    }
}
