.ert-info-box {
    --ert-accent: #2563eb;
    --ert-radius: 8px;
    /* Solid fallbacks for browsers without color-mix; overridden below to adapt
       to the active theme (light or dark) by deriving from the inherited text color. */
    --ert-surface: #f5f7fa;
    --ert-chip: #e7ecf3;

    box-sizing: border-box;
    font-family: inherit;
    font-size: 0.9375rem;
    line-height: 1.5;
    color: inherit;
    background: var(--ert-surface);
    border-left: 4px solid var(--ert-accent);
    border-radius: var(--ert-radius);
    padding: 1rem 1.25rem;
    margin: 0 0 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 0.45rem;
}

/* Theme-adaptive surfaces: a faint tint of the current text color works on any
   background without forcing a light/dark guess. */
@supports (background: color-mix(in srgb, red, blue)) {
    .ert-info-box {
        --ert-surface: color-mix(in srgb, currentColor 5%, transparent);
        --ert-chip: color-mix(in srgb, currentColor 10%, transparent);
    }
}

.ert-read-time,
.ert-readability,
.ert-common-topics {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0;
}

.ert-info-box strong {
    font-weight: 600;
}

.ert-icon {
    line-height: 1;
    font-style: normal;
}

.ert-time {
    opacity: 0.85;
}

.ert-topics {
    display: inline-flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    font-style: normal;
}

.ert-topic {
    display: inline-block;
    padding: 0.12rem 0.6rem;
    background: var(--ert-chip);
    border-radius: 999px;
    font-size: 0.8125rem;
    line-height: 1.6;
}

.ert-readability-detail {
    opacity: 0.75;
    font-size: 0.8125rem;
    font-style: italic;
}

/* Readability badges keep fixed semantic colors (white text on a colored pill). */
.ert-readability-badge {
    display: inline-block;
    padding: 0.12rem 0.55rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    line-height: 1.6;
    color: #fff;
}
.ert-badge-standard {
    background-color: #0275d8;  /* Blue - Accessible */
}
.ert-badge-fairly-easy {
    background-color: #5bc0de;  /* Light blue - Moderate */
}
.ert-badge-fairly-difficult {
    background-color: #f0ad4e;  /* Orange - Advanced */
}
.ert-badge-difficult {
    background-color: #ee6002;  /* Dark orange - Difficult */
}
.ert-badge-very-difficult {
    background-color: #d9534f;  /* Red - Very Difficult */
}
.ert-badge-na {
    background-color: #888;     /* Gray - N/A */
}
