.wf-products-grid.wishlist-products-grid {
    justify-content: start;
}

.wishlist-header {
    text-align: center;
    margin-bottom: 30px;
}

.wishlist-products-grid {
    display: flex;
    gap: 20px;
}

.wishlist-empty {
    text-align: center;
    padding: 50px 20px;
}

.wishlist-empty h2 {
    color: #333;
    margin-bottom: 15px;
}

.wishlist-empty p {
    color: #666;
    margin-bottom: 20px;
}

/* Стили для wishlist элемента в меню */
.thwwc-menu-item .button {
    border: none;
    padding: 2px 4px !important;
    min-width: 23px !important;
    width: fit-content !important;
    color: #fff !important;
}

/* Убираем wishlist из подменю и показываем только в основном меню */
.sub-menu .thwwc-menu-item:not(.thwwc-compare-menu-item) {
    display: none !important;
}

/* Обеспечиваем правильное отображение wishlist в основном меню */
#primary-menu>.thwwc-menu-item:not(.thwwc-compare-menu-item) {
    display: block !important;
}

.wf-archive-container .thwwc-full-section {
    /* position: absolute; */
    width: fit-content;
    /* top: 45%;
    left: 10px;
    z-index: 100; */
}

.thwwc-wishlist-btn {
    position: absolute;
    top: 150px;
    left: 17px;
    z-index: 100;
    background-color: rgba(255, 255, 255, 0.5);
    border: 1px solid #f1f1f1;
    margin: 0;
    transition: .2s;
}

@media (max-width: 768px) {
    .wishlist-products-grid {
        gap: 10px;
    }

    .thwwc-wishlist-btn {
        top: 100px;
    }
}

.professional-single-product-container .thwwc-wishlist-btn {
    top: 130px;
}

.wf-archive-container .thwwc-wishlist-btn:hover {
    background-color: rgba(255, 255, 255, .7);
}

.thwwc-wishlist-btn a {
    margin: 0;
}

.thwwac-icon {
    line-height: 1;
    font-size: 19px;
}

.professional-product-card .thwwac-icon {
    color: #f8104b;
}

.professional-product-card .thwwac-compare-icon,
.professional-product-card .thwwac-added-icon {
    color: #fff;
}

/* ===============================================
   Стили для счетчика сравнения в меню
   =============================================== */

/* Основные стили для элемента меню сравнения */
.thwwc-compare-menu-item {
    display: inline-block;
    vertical-align: middle;
}

/* Стили для ссылки счетчика сравнения */
.thwwac-compare-counter-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 5px 10px;
    text-decoration: none !important;
    transition: var(--transition);
}

/* Иконка сравнения - используется встроенная иконка плагина */
.thwwac-compare-counter-btn .thwwac-compare-icon {
    font-size: 24px;
    line-height: 1;
}

/* Счетчик количества товаров в сравнении */
#thwwac_compare_count {
    display: inline-block;
    min-width: 20px;
    padding: 2px 6px;
    border-radius: 20px;
    background: var(--primary-color);
    color: var(--text-inverse);
    font-size: 12px;
    font-weight: 600;
    text-align: center;
    line-height: 1.4;
    margin-left: -10px;
    margin-bottom: 15px;
}

/* Эффект при наведении */
.thwwac-compare-counter-btn:hover {
    opacity: 0.7;
    transform: translateY(-2px);
}

/* Адаптивные стили для мобильных устройств */
@media (max-width: 768px) {
    .thwwc-compare-menu-item {
        margin: 0 5px;
    }

    .thwwac-compare-counter-btn .thwwac-compare-icon {
        font-size: 20px;
    }

    #thwwac_compare_count {
        font-size: 11px;
        min-width: 18px;
        padding: 1px 5px;
    }
}

/**
 * Стили для табличной версии страницы сравнения
 * 
 * Используется с шорткодом [westface_compare_table]
 */

.btn-wrapper {
    /* display: flex;
    justify-content: center; */
    margin-block: 30px;
}

.compare-product-btns {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.compare-product-btns .btn-secondary {
    background: transparent;
    color: var(--accent-color);
}

.compare-product-btns .btn-secondary:hover {
    background: var(--accent-color);
    color: #fff;
}

.compare-product-btns .btn {
    line-height: 1;
}

/* ==========================================================================
   Основной контейнер таблицы
   ========================================================================== */

.thwwc-compare-page {
    display: none !important;
}

.westface-compare-table-wrapper {
    width: 100%;
    /* overflow-x: auto; */
    overflow-y: visible;
    margin: 20px 0;
    /* Скроллинг для мобильных */
    -webkit-overflow-scrolling: touch;
}

/* ==========================================================================
   Таблица сравнения
   ========================================================================== */

.westface-compare-table {
    width: 100%;
    border-collapse: collapse;
    background: #fff;
    table-layout: fixed;
    /* box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1); */
    /* Минимальная ширина для удобного чтения */
    /* min-width: 600px; */
}

.westface-compare-table td,
.westface-compare-table th {
    box-sizing: border-box;
}

/* ==========================================================================
   Sticky Product Row (Images + Titles + Remove buttons)
   ========================================================================== */

.compare-sticky-row {
    background: #fff;
    border-bottom: 3px solid #e0e0e0;
    position: relative;
}

/* Cloned sticky row wrapper (created by JavaScript) */
.compare-sticky-wrapper {
    animation: slideDown 0.3s ease;
    border-radius: 0;
    background: #fff;
}

.compare-sticky-scroll-wrapper {
    overflow-x: auto;
    overflow-y: hidden;
    -webkit-overflow-scrolling: touch;
    /* Hide scrollbar but keep functionality */
    scrollbar-width: none;
    /* Firefox */
    -ms-overflow-style: none;
    /* IE and Edge */
}

.compare-sticky-scroll-wrapper::-webkit-scrollbar {
    display: none;
    /* Chrome, Safari, Opera */
}

.compare-sticky-table {
    margin: 0 !important;
    box-shadow: none !important;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.compare-sticky-row .compare-attribute {
    vertical-align: top;
    padding-top: 20px;
}

/* Product Cell Wrapper */
.compare-product-cell {
    padding: 5px !important;
    vertical-align: top;
    width: 280px;
    min-width: 280px;
    max-width: 280px;
}

.compare-product-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
}

/* Product Image with Remove Button */
.compare-product-image {
    position: relative;
    width: 100%;
    margin: 0 auto;
}

.compare-product-image img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 4px;
}

/* Remove Button - Absolute positioning over image */
.compare-remove-btn {
    position: absolute;
    top: -8px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--primary-light);
    color: white;
    border: none;
    padding: 8px 10px;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    z-index: 100;
}

.compare-remove-btn:hover {
    background: var(--primary-dark);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.4);
}

.compare-remove-btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.compare-remove-btn i {
    font-size: 16px;
}

/* Product Title */
.compare-product-title {
    text-align: center;
    width: 100%;
}

.compare-product-title a {
    color: var(--text-primary);
    text-decoration: none;
    font-size: 16px;
    line-height: 1.4;
    display: block;
    transition: color 0.3s ease;
}

.compare-product-title a:hover {
    color: var(--text-secondary);
}

/* Product category */
.compare-product-category {
    color: #999;
    font-size: 13px;
    font-weight: normal;
    display: inline;
}

/* ==========================================================================
   Table Body
   ========================================================================== */

.westface-compare-table tbody tr {
    border-bottom: 1px solid #e0e0e0;
    transition: background 0.2s ease;
}

.westface-compare-table tbody tr:last-child {
    border-bottom: none;
}

/* ==========================================================================
   Table Cells
   ========================================================================== */

.westface-compare-table td {
    padding: 15px;
    vertical-align: middle;
}

.westface-compare-table td:last-child {
    border-right: none;
}

/* Attribute names column (sticky on horizontal scroll) */
.compare-attribute {
    font-weight: 600;
    color: #000;
    white-space: nowrap;
    width: 200px;
    max-width: 200px;
    min-width: 200px;
}

/* Value columns */
.compare-value {
    text-align: center;
    min-width: 280px;
}

.compare-value .professional-pricing-container {
    justify-content: center;
}

.compare-value .pricing-card.primary-pricing .price-display {
    justify-content: end;
}

.compare-value .pricing-card.secondary-pricing .price-display {
    justify-content: start;
}

/* Prices row */
.compare-row-prices .compare-value {
    font-weight: 600;
}

.compare-row-prices .price {
    display: inline-block;
}

.compare-row-prices .price del {
    color: #999;
    font-size: 14px;
    margin-right: 5px;
}

.compare-row-prices .price ins {
    text-decoration: none;
    color: #e74c3c;
}

/* Descriptions row */
.compare-row-descriptions .compare-value {
    text-align: left;
    font-size: 14px;
    line-height: 1.6;
    max-width: 300px;
}

.compare-description {
    color: #666;
}

/* Add to cart button row */
.compare-row-addtocart .compare-value {
    padding: 20px 15px;
}

/* .compare-row-addtocart .button {
    display: inline-block;
    padding: 12px 24px;
    background: #0073aa;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
    border: none;
    cursor: pointer;
    font-size: 14px;
}

.compare-row-addtocart .button:hover {
    background: #005177;
} */

/* ==========================================================================
   Status and Labels
   ========================================================================== */

/* Missing value */
.compare-na {
    color: #999;
    font-style: italic;
}

/* ==========================================================================
   Empty State
   ========================================================================== */

.westface-compare-empty {
    text-align: center;
    padding: 60px 20px;
    /* background: #f9f9f9; */
    border-radius: 8px;
}

.westface-compare-empty p {
    font-size: 18px;
    color: #666;
    margin-bottom: 20px;
}

/* .westface-compare-empty .button {
    display: inline-block;
    padding: 12px 30px;
    background: #0073aa;
    color: white;
    text-decoration: none;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.westface-compare-empty .button:hover {
    background: #005177;
} */

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media screen and (max-width: 768px) {
    /* Mobile styles */

    /* Reduce attribute column width */
    .compare-attribute {
        font-size: 14px;
    }

    .westface-compare-table-wrapper {
        width: 100%;
    }

    .westface-compare-table {
        overflow-x: auto;
        overflow-y: visible;

    }

    /* Smaller product images on mobile */
    .compare-product-image {
        width: 250px;
        max-width: 100%;
    }

    /* Smaller remove button */
    .compare-remove-btn {
        width: 30px;
        height: 30px;
        padding: 6px;
        top: 5px;
        right: 5px;
    }

    .compare-remove-btn i {
        font-size: 14px;
    }

    /* Reduce padding */
    .westface-compare-table td:not(.compare-attribute),
    .westface-compare-table thead th {
        padding: 10px 8px;
        min-width: 0;
        max-width: 250px;
        width: 100%;
    }

    /* Reduce image size */
    .compare-row-images .compare-value img {
        max-width: 120px;
    }

    /* Reduce font sizes */
    .compare-row-prices .compare-value {
        font-size: 16px;
    }

    .compare-row-descriptions .compare-value {
        font-size: 12px;
    }

    /* Buttons full cell width */
    .compare-row-addtocart .button {
        width: 100%;
        padding: 10px 12px;
        font-size: 13px;
    }
}

@media screen and (max-width: 480px) {

    /* Further compression on very small screens */
    .compare-attribute {
        font-size: 12px;
    }

    .westface-compare-table td:not(.compare-attribute),
    .westface-compare-table thead th {
        max-width: 180px;
    }

    .compare-value {
        font-size: 12px;
    }

    .compare-product-image {
        width: 180px;
    }

    .compare-product-title a {
        font-size: 13px;
    }

    .compare-remove-btn {
        width: 26px;
        height: 26px;
        padding: 5px;
    }

    .compare-remove-btn i {
        font-size: 12px;
    }
}

/* ==========================================================================
   Additional Effects
   ========================================================================== */

/* Fade in animation on load */
.westface-compare-table-wrapper {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Plugin integration styles */
.westface-compare-table .thwwac-bin,
.westface-compare-table .thwwac-remove-icon {
    /* Trash icon from plugin */
    display: inline-block;
}

/* Fade out animation for removed columns */
@keyframes fadeOutColumn {
    from {
        opacity: 1;
        transform: scale(1);
    }

    to {
        opacity: 0;
        transform: scale(0.8);
    }
}

.flex-title {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 20px;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color);
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.wpcf7-form {
    margin-top: 20px;
}

.wpcf7-form p {
    margin-bottom: 15px;
}

.wpcf7-form label,
.wpcf7-form label span {
    display: inline-block;
    width: 100%;
}

.wpcf7-form input:not([type="checkbox"]),
.wpcf7-form input:not([type="radio"]) {
    width: 100%;
}

input[type="number"] {
    border: 2px solid #e9ecef;
    border-radius: 0;
    font-size: 1rem;
    padding: 12px 15px;
    transition: border-color .3s ease;
}

.wpcf7-not-valid-tip {
    font-size: 12px;
}