/* Reuse the viewers' actual loading states; keep their posters visible. */
[data-ounce-model][aria-busy="true"]::after,
[data-model-host][data-state="loading"]::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 3;
    width: 22px;
    height: 22px;
    margin-top: -11px;
    margin-left: -11px;
    box-sizing: border-box;
    border: 2px solid rgba(128,128,128,.28);
    border-top-color: var(--coin-gold, var(--gold-dark, #846226));
    border-radius: 50%;
    background: var(--model-loader-background, rgba(255,255,255,.9));
    box-shadow: 0 0 0 4px var(--model-loader-background, rgba(255,255,255,.9));
    pointer-events: none;
    animation: model-loading-spin .8s linear infinite;
}

html[data-theme="night"],
html[data-theme="dark"] { --model-loader-background: rgba(36,39,44,.9); }

@keyframes model-loading-spin {
    to { transform: rotate(360deg); }
}

@media (prefers-reduced-motion: reduce) {
    [data-ounce-model][aria-busy="true"]::after,
    [data-model-host][data-state="loading"]::after { animation: none; }
}

/* Compact AI disclosure shared by price and historical-coin viewers. */
.ounce-price-ai-badge,
.coin-ai-badge { position: absolute; top: 8px; right: 8px; z-index: 4; display: inline-flex; align-items: center; justify-content: center; width: 18px; height: 18px; border: 1px solid rgba(128,128,128,.2); border-radius: 50%; background: rgba(239,240,242,.8); color: #747880; font-family: CoinMono, 'IBM Plex Mono', monospace; font-size: 7.5px; font-weight: 500; line-height: 1; pointer-events: none; }
html[data-theme="night"] .ounce-price-ai-badge,
html[data-theme="dark"] .coin-ai-badge { background: rgba(56,59,64,.8); border-color: rgba(168,171,177,.2); color: #b0b3b8; }
