/* Roya icon set (public/media/brand/icons). Source: scripts/build-icons.mjs.
   Stroke icons drawn on a 24 px grid; stroke, colour and the active fill are set here. */
.ri {
  width: 1.15em; height: 1.15em; flex: none;
  overflow: visible;
  fill: none; stroke: currentColor; stroke-width: var(--ri-sw, 1.75);
  stroke-linecap: round; stroke-linejoin: round;
}
.ri use { pointer-events: none; }

/* Optical sizing: slightly heavier at 16 px and below, slightly lighter from 32 px up. */
.ri-sm, .badge .ri, .badge-lock .ri, .th-kicker .ri, .avatar-crown .ri, .mc-kicker .ri { --ri-sw: 2; }
.ri-lg, .empty .ri, .p-flash .ri, .rail-arrow .ri { --ri-sw: 1.5; }

/* Active / filled state: the silhouette fills with the current colour, inner details cut out in ink,
   and a soft red glow like the leaf logo. */
.ri.is-active,
.tabbar a[aria-current="page"] .ri,
[aria-pressed="true"] > .ri.ri-heart, [aria-pressed="true"] > .ri.ri-mylist {
  --ri-fill: currentColor;
  --ri-cut: var(--ink-1, #0a0c12);
}
.tabbar a[aria-current="page"] .ri,
.ri.is-active { filter: drop-shadow(0 0 6px var(--red-glow, rgba(225, 29, 42, 0.45))); }
.tabbar a .ri { transition: filter 0.25s var(--ease, ease), transform 0.25s var(--ease, ease); }

/* RTL: mirror icons that point along the reading direction. Chevrons and arrows are already
   swapped by name in the app, so only logical-direction icons carry .ri-flip. */
[dir="rtl"] .ri-flip { transform: scaleX(-1); }

/* Loader spins. */
.ri-loader { animation: ri-spin 0.9s linear infinite; }
@keyframes ri-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .ri-loader { animation-duration: 2.4s; } }

/* Live dot pulses gently. */
.ri-live-dot { color: var(--live, #ff2d3d); }
