/**
 * NASA Product Addons Styles
 * Стили для отображения добавок в quickview
 */

.product-addons-wrapper {
    width: 100%;
    margin: 20px 0;
    padding: 15px;
    background: none;
    border-radius: 4px;
    border: 1px solid #e5e5e5;
}

.product-addons-wrapper .addons-title {
    margin: 0 0 15px;
    padding: 0;
    font-size: 16px;
    font-weight: 600;
    color: white;
    border-bottom: 2px solid #ddd;
    padding-bottom: 10px;
}

.product-addons-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.product-addon-item {
    background: #EAEAEA;
    border: 2px solid #e5e5e5;
    border-radius: 4px;
    padding: 12px 15px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.product-addon-item:hover {
    border-color: #ccc;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.product-addon-item.addon-selected {
    border-color: #6ca300;
    background: #f0f9f4;
}

.product-addon-item.addon-pulse {
    animation: addonPulse 0.3s ease;
}
.product-addon-item img {
    display: none;
}
.product-addon-item.hidden-addon {
    display: none;
}
.product-addon-more {
    text-align: center;
    margin-top: 10px;
}
a.product-addon-more span {
    border-bottom: 1px solid;
    border-bottom-style: dashed;
}

@keyframes addonPulse {
    0% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.02);
    }
    100% {
        transform: scale(1);
    }
}

.addon-checkbox-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    margin: 0;
    width: 100%;
    user-select: none;
}

.addon-checkbox {
    width: 20px;
    height: 20px;
    margin-right: 10px;
    cursor: pointer;
    flex-shrink: 0;
}

.addon-name {
    flex: 1;
    font-size: 14px;
    color: #6ca300;
    font-weight: 500;
}

.addon-price {
    font-size: 14px;
    color: #28a745;
    font-weight: 600;
    margin-left: 10px;
    white-space: nowrap;
}

/* Стили для обновленной цены */
.price-updated {
    animation: priceUpdate 0.6s ease;
}

@keyframes priceUpdate {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
        color: #28a745;
    }
}

.addons-note {
    display: inline-block;
    margin-left: 8px;
    font-size: 12px;
    color: #666;
    font-weight: normal;
}

/* Стили для цены с добавками */
.product-lightbox .price del {
    opacity: 0.7;
    margin-right: 8px;
}

.product-lightbox .price ins {
    text-decoration: none;
    color: #28a745;
    font-weight: 600;
}

/* Мобильная адаптация */
@media screen and (max-width: 768px) {
    .product-addons-wrapper {
        margin: 15px 0;
        padding: 12px;
    }

    .product-addons-wrapper .addons-title {
        font-size: 14px;
        margin-bottom: 12px;
    }

    .product-addon-item {
        padding: 10px 12px;
    }

    .addon-checkbox-label {
        flex-wrap: wrap;
    }

    .addon-name {
        font-size: 13px;
    }

    .addon-price {
        font-size: 13px;
    }
}

/* Интеграция с темой Elessi */
.product-lightbox .product-addons-wrapper {
    margin-top: 15px;
}

.product-lightbox .summary .product-addons-wrapper {
    order: 3; /* Располагаем после описания */
}

/* Стили для чекбокса (кастомные) */
.addon-checkbox {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    width: 20px;
    height: 20px;
    border: 2px solid #ddd;
    border-radius: 3px;
    background: #fff;
    position: relative;
    cursor: pointer;
    transition: all 0.2s ease;
}

.addon-checkbox:hover {
    border-color: #28a745;
}

.addon-checkbox:checked {
    background: #28a745;
    border-color: #28a745;
}

.addon-checkbox:checked::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #fff;
    font-size: 14px;
    font-weight: bold;
}

.addon-checkbox:focus {
    outline: 2px solid rgba(40, 167, 69, 0.3);
    outline-offset: 2px;
}

/* Стили для загрузки */
.product-addons-wrapper.loading {
    opacity: 0.6;
    pointer-events: none;
}

.product-addons-wrapper.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 30px;
    height: 30px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #28a745;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}
/*change*/

