/**
 * FO styles
 *
 * @author      Difadi.com <soporte@difadi.com>
 * @copyright   2026 Difadi.com
 * @license     Commercial
 */

.dfdproductcomplements {
    width: 100%;
    margin: 2rem 0;
}

.dfdproductcomplements__title {
    margin: 0 0 2rem;
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    text-transform: uppercase;
}

.dfdproductcomplements__products {
    border: 1px solid #e4e4e4;
    border-bottom: 0;
}

.dfdproductcomplements__product {
    position: relative;
    display: grid;
    grid-template-columns: minmax(180px, 300px) minmax(0, 1fr);
    gap: 2.25rem;
    padding: 0;
    border-bottom: 1px solid #e4e4e4;
    background: #fff;
}

.dfdproductcomplements__media {
    align-self: stretch;
    background: #f7f7f7;
}

.dfdproductcomplements__main-image-link {
    display: block;
    width: 100%;
    height: 100%;
}

.dfdproductcomplements__main-image {
    display: block;
    width: 100%;
    height: 100%;
    min-height: 300px;
    object-fit: cover;
}

.dfdproductcomplements__content {
    position: relative;
    min-width: 0;
    padding: 1.25rem 4rem 1.5rem 0;
}

.dfdproductcomplements__checkbox-wrap {
    position: absolute;
    top: 1.25rem;
    right: 1.25rem;
    display: block;
    width: 2rem;
    height: 2rem;
    margin: 0;
    cursor: pointer;
}

.dfdproductcomplements__checkbox {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
}

.dfdproductcomplements__checkbox-visual {
    display: block;
    width: 100%;
    height: 100%;
    border: 2px solid #b7b7b7;
    background: #fff;
    transition: border-color .2s ease, background-color .2s ease;
}

.dfdproductcomplements__checkbox:checked + .dfdproductcomplements__checkbox-visual {
    border-color: #222;
    background: #222;
}

.dfdproductcomplements__checkbox:checked + .dfdproductcomplements__checkbox-visual::after {
    content: '';
    position: absolute;
    top: .4rem;
    left: .65rem;
    width: .45rem;
    height: .8rem;
    border-right: 2px solid #fff;
    border-bottom: 2px solid #fff;
    transform: rotate(45deg);
}

.dfdproductcomplements__checkbox:disabled + .dfdproductcomplements__checkbox-visual {
    cursor: not-allowed;
    opacity: .4;
}

.dfdproductcomplements__manufacturer {
    margin-bottom: .25rem;
    color: #222;
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1.2;
    text-transform: uppercase;
}

.dfdproductcomplements__name {
    display: block;
    margin-bottom: 1rem;
    overflow: hidden;
    color: inherit;
    font-size: 1.2rem;
    line-height: 1.35;
    text-decoration: none;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.dfdproductcomplements__name:hover {
    color: inherit;
    text-decoration: underline;
}

.dfdproductcomplements__price {
    margin-bottom: .15rem;
    font-size: 1.5rem;
    line-height: 1.2;
}

.dfdproductcomplements__availability {
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

.dfdproductcomplements__availability.is-available {
    color: #20b84b;
}

.dfdproductcomplements__availability.is-unavailable {
    color: #d53939;
}

.dfdproductcomplements__variant {
    width: 100%;
}

.dfdproductcomplements__variant-label {
    display: block;
    margin-bottom: .75rem;
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
}

.dfdproductcomplements__select {
    width: 100%;
    min-height: 3.5rem;
    padding: .75rem 3rem .75rem 1.25rem;
    border: 1px solid #555;
    border-radius: 2rem;
    background-color: #fff;
    color: inherit;
    font: inherit;
}

.dfdproductcomplements__notice {
    margin: 1rem 0 0;
    color: #8b5e00;
    font-size: .9rem;
}

.dfdproductcomplements__message {
    min-height: 0;
    padding: 0;
    font-size: .95rem;
}

.dfdproductcomplements__message.is-success,
.dfdproductcomplements__message.is-error {
    padding: .75rem 1rem;
}

.dfdproductcomplements__message.is-success {
    color: #176f32;
    background: #edf8f0;
}

.dfdproductcomplements__message.is-error {
    color: #9b2727;
    background: #fff0f0;
}

.dfdproductcomplements__footer {
    display: grid;
    grid-template-columns: minmax(0, 2fr) minmax(180px, 1fr);
    border: 1px solid #e4e4e4;
    background: #fff;
}

.dfdproductcomplements__add {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    min-height: 5.25rem;
    padding: 1rem 1.5rem;
    border: 0;
    border-right: 1px solid #e4e4e4;
    background: #fff;
    color: #222;
    font-size: 1.25rem;
    font-weight: 700;
    text-transform: uppercase;
    cursor: pointer;
    transition: opacity .2s ease;
}

.dfdproductcomplements__add:disabled {
    cursor: not-allowed;
    opacity: .45;
}

.dfdproductcomplements__add.is-loading {
    cursor: wait;
    opacity: .6;
}

.dfdproductcomplements__bag {
    position: relative;
    display: inline-block;
    width: 1.75rem;
    height: 1.55rem;
    border: 1.5px solid currentColor;
}

.dfdproductcomplements__bag::before {
    content: '';
    position: absolute;
    top: -.7rem;
    left: .4rem;
    width: .8rem;
    height: .75rem;
    border: 1.5px solid currentColor;
    border-bottom: 0;
    border-radius: .6rem .6rem 0 0;
}

.dfdproductcomplements__bag::after {
    content: '+';
    position: absolute;
    right: -.55rem;
    bottom: -.45rem;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 1rem;
    height: 1rem;
    background: #fff;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
}

.dfdproductcomplements__total {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 5.25rem;
    padding: 1rem 1.5rem;
    font-size: 2rem;
    line-height: 1;
}

@media (max-width: 991px) {
    .dfdproductcomplements__title {
        font-size: 1.4rem;
    }

    .dfdproductcomplements__product {
        grid-template-columns: minmax(130px, 38%) minmax(0, 1fr);
        gap: 1.25rem;
    }

    .dfdproductcomplements__main-image {
        min-height: 230px;
    }

    .dfdproductcomplements__content {
        padding: 1rem 3.25rem 1.25rem 0;
    }

    .dfdproductcomplements__manufacturer {
        font-size: 1.05rem;
    }

    .dfdproductcomplements__name {
        font-size: 1rem;
        white-space: normal;
    }

    .dfdproductcomplements__price {
        font-size: 1.25rem;
    }
}

@media (max-width: 575px) {
    .dfdproductcomplements__product {
        display: block;
    }

    .dfdproductcomplements__main-image {
        width: 100%;
        min-height: 0;
        aspect-ratio: 1 / 1;
    }

    .dfdproductcomplements__content {
        padding: 1rem 3.5rem 1.5rem 1rem;
    }

    .dfdproductcomplements__footer {
        grid-template-columns: 1fr;
    }

    .dfdproductcomplements__add {
        border-right: 0;
        border-bottom: 1px solid #e4e4e4;
    }

    .dfdproductcomplements__total {
        justify-content: center;
        min-height: 4rem;
    }
}

/* Category */
.dfdproductcomplements-category {
    width: 100%;
    margin: 2rem 0;
}

.dfdproductcomplements-category__title {
    margin: 0 0 2rem;
    font-size: 1.75rem;
    font-weight: 700;
    line-height: 1.2;
    text-transform: uppercase;
}

.dfdproductcomplements-category__products {
    display: grid;
    gap: 2rem;
}

.dfdproductcomplements-category__product {
    display: grid;
    grid-template-columns: minmax(160px, 260px) minmax(0, 1fr);
    gap: 2rem;
    align-items: start;
}

.dfdproductcomplements-category__image-link {
    display: block;
    background: #f7f7f7;
}

.dfdproductcomplements-category__image {
    display: block;
    width: 100%;
    aspect-ratio: 1 / 1;
    object-fit: cover;
}

.dfdproductcomplements-category__name {
    display: inline-block;
    margin-bottom: 1.5rem;
    color: inherit;
    font-size: 1.3rem;
    font-weight: 700;
    line-height: 1.25;
    text-decoration: none;
}

.dfdproductcomplements-category__name:hover {
    color: inherit;
    text-decoration: underline;
}

.dfdproductcomplements-category__complements {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1.5rem;
}

.dfdproductcomplements-category__miniature {
    min-width: 0;
}

@media (max-width: 767px) {
    .dfdproductcomplements-category__product {
        grid-template-columns: 1fr;
    }

    .dfdproductcomplements-category__complements {
        grid-template-columns: 1fr;
    }
}
