/* Palarid · The result surface · v4.52.0
   ==========================================================================
   223 result regions, styled 223 different ways. A tool's answer is the most
   important thing on its screen and had no shared treatment at all — it was
   whatever inline styles that particular tool happened to carry.

   This is deliberately restrained. Every one of those regions already has its
   own styling, much of it inline, and inline wins. Rather than fight that —
   which would mean editing thousands of attributes and would break layouts
   that currently work — this adds only what is almost never declared inline:
   a leading accent rule, breathing room, and a settled transition. The result
   starts to read as the answer without any tool being restyled out from under
   a design that was fine.

   Loaded BEFORE the premium layer, not after. Premium is the cascade-last
   override by design (D-001) and a build gate enforces it — the first attempt
   to load this file last was rejected by that gate, correctly. Nothing in
   premium targets .pal-result, so ordering costs this layer nothing.
   ========================================================================== */

/* The answer surface. `:empty` is excluded so a tool that has not produced
   anything yet does not show a decorative bar attached to nothing — an
   accent rule beside blank space reads as a rendering fault. */
.pal-result:not(:empty) {
  position: relative;
  padding-left: 14px;
  border-left: 3px solid var(--accent, #8B7CF6);
  border-radius: 2px;
  transition: border-color 180ms var(--ease, cubic-bezier(.2, .7, .3, 1));
}

/* When the figure lands, the rule warms for a moment. This is the only
   feedback a sighted user gets that the number they are looking at is the
   NEW number rather than the previous one — the same job the announcer does
   for a screen reader. */
@keyframes palResultSettle {
  from { border-left-color: var(--gold, #C9A24B); }
  to   { border-left-color: var(--accent, #8B7CF6); }
}
.pal-result:not(:empty) { animation: palResultSettle 900ms ease-out; }

/* Numbers must not jitter sideways as they recompute on each keystroke.
   Tabular figures keep every digit the same width. */
.pal-result .v,
.pal-result b,
.pal-result strong,
.pal-result .num {
  font-variant-numeric: tabular-nums;
}

/* Light theme: the same accent at a weight that survives a white background.
   The dark-theme purple at full strength vibrates against white. */
:root[data-theme="light"] .pal-result:not(:empty) {
  border-left-color: var(--accent, #6D5AE0);
}

/* Someone who has asked for less movement gets the surface without the
   flourish. The announcer still speaks; only the animation goes. */
@media (prefers-reduced-motion: reduce) {
  .pal-result:not(:empty) { animation: none; transition: none; }
}

/* Higher contrast preference: make the rule unmistakable rather than subtle. */
@media (prefers-contrast: more) {
  .pal-result:not(:empty) { border-left-width: 4px; }
}

/* The announcer must never be display:none — a hidden subtree is not
   announced, which would silently undo the entire point. This rule exists so
   a future blanket "hide offscreen things" sweep cannot break it without
   also deleting this comment. */
#pal-announcer {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
  clip: rect(0 0 0 0) !important;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}
