/*
 * Prior-year rollover notes.
 *
 * Two kinds, and they must not look alike: an informational note recording what we
 * calculated last year, and a divergence note pointing out that what the customer has
 * typed disagrees with it. Neither is an error — the divergence note in particular is
 * explicitly non-blocking and says so in its own copy — so neither uses the error red.
 *
 * Colours come from the design-system variables, with literal fallbacks only for the
 * pre-variable render. Coral (#F97066) is never used in application UI.
 */

.pyr-note {
    display: block;
    /* The host cell right-aligns its numeric input; prose inherits that and becomes hard
       to read in a narrow column, so the note sets its own alignment. */
    text-align: left;
    margin-top: 0.35rem;
    font-size: 0.8125rem;
    line-height: 1.4;
    max-width: 32rem;
}

.pyr-note--info {
    color: var(--text-secondary, #5a6472);
    border-left: 3px solid var(--primary-color, #12b76a);
    padding-left: 0.5rem;
}

/* Amber, not red: the customer may be right and we may be out of date. */
.pyr-note--divergence {
    color: var(--text-primary, #1d2939);
    background: var(--warning-bg, #fffaeb);
    border-left: 3px solid var(--warning, #f79009);
    padding: 0.4rem 0.5rem;
    border-radius: 3px;
}

/*
 * The "Use this figure" action.
 *
 * Deliberately a quiet inline action, not a .btn-primary. It sits inside an informational
 * note next to a tax input, and the design contract reserves primary emphasis for genuine
 * hero actions — re-skinning a primary button here is exactly the ancestor-scoped drift the
 * button contract forbids. It should read as "you may adopt this", never as "do this".
 */
.pyr-note__provenance {
    display: block;
}

.pyr-use-figure {
    display: inline-block;
    margin-top: 0.35rem;
    padding: 0.15rem 0.5rem;
    font: inherit;
    font-size: 0.8125rem;
    color: var(--primary-color, #12b76a);
    background: transparent;
    border: 1px solid var(--primary-color, #12b76a);
    border-radius: 3px;
    cursor: pointer;
}

.pyr-use-figure:hover,
.pyr-use-figure:focus-visible {
    color: #fff;
    background: var(--primary-color, #12b76a);
}

.pyr-note__applied {
    display: inline-block;
    margin-top: 0.35rem;
    font-size: 0.8125rem;
    color: var(--text-secondary, #5a6472);
}
