/**
 * Nxr_Advice — banner de asesoramiento en home.
 *
 * Cadena de color, de más específico a más general:
 *   --nxr-advice-bg   inyectada por home.tpl si se configuró en el BO
 *   --nxr-accent      paleta global de los módulos Nexir (la define el tema)
 *   #1f2937           neutro de respaldo
 *
 * Dejar los campos de color vacíos en el BO hace que el banner siga la paleta
 * global en vez de fijar la suya.
 */
.nxr_advice_home {
    overflow: hidden;
    margin: 1.5rem 0;
}

.nxr_advice_home_content {
    display: flex;
    align-items: stretch;
}

.nxr_advice_home_left {
    background: var(--nxr-advice-bg, var(--nxr-accent, #1f2937));
    color: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
    flex: 0.8;
    padding: 32px 64px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: flex-start;
    border-radius: 8px 0 0 8px;
}

/* Sin imagen: el panel ocupa todo el ancho y redondea las cuatro esquinas. */
.nxr_advice_home--no-image .nxr_advice_home_left {
    flex: 1 1 100%;
    border-radius: 8px;
}

.nxr_advice_home_title {
    width: 100%;
}

.nxr_advice_home_title .h3 {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin: 0;
}

.nxr_advice_home_title .h3,
.nxr_advice_home_title span {
    font-size: 24px;
    font-weight: 600;
    line-height: 28px;
    color: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
}

.nxr_advice_home_line {
    height: 2px;
    width: 64px;
    background: currentColor;
    opacity: 0.55;
    margin: 20px 0;
    border-radius: 2px;
}

.nxr_advice_home_subtitle {
    font-size: 16px;
    font-weight: 400;
    line-height: 24px;
    color: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
    margin-bottom: 32px;
}

.nxr_advice_home_btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: transparent;
    border: 1px solid var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
    color: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
    border-radius: 8px;
    padding: 10px 20px;
    text-decoration: none;
    font-size: 15px;
    font-weight: 600;
    line-height: 24px;
    white-space: nowrap;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.nxr_advice_home_btn span,
.nxr_advice_home_btn svg {
    color: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
}

/* Hover: se invierten fondo y texto, sin fijar ningún color de marca. */
.nxr_advice_home_btn:hover {
    background: var(--nxr-advice-fg, var(--nxr-accent-contrast, #ffffff));
}

.nxr_advice_home_btn:hover span,
.nxr_advice_home_btn:hover svg {
    color: var(--nxr-advice-bg, var(--nxr-accent, #1f2937));
}

.nxr_advice_home_right {
    flex: 1 1 0%;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    min-width: 280px;
    background: #fff;
    border-radius: 0 8px 8px 0;
}

.nxr_advice_home_right img {
    width: 100%;
    height: 400px;
    object-fit: cover;
    display: block;
}

@media (max-width: 991px) {
    .nxr_advice_home_content {
        flex-direction: column-reverse;
    }

    .nxr_advice_home_title .h3,
    .nxr_advice_home_title span {
        font-size: 20px;
    }

    .nxr_advice_home_left {
        padding: 32px 20px;
        border-radius: 0 0 8px 8px;
        min-width: 0;
    }

    .nxr_advice_home--no-image .nxr_advice_home_left {
        border-radius: 8px;
    }

    .nxr_advice_home_right {
        border-radius: 8px 8px 0 0;
        min-width: 0;
    }

    .nxr_advice_home_right img {
        height: 197px;
    }
}
