/* ==========================================================================
   Reset and element defaults.
   Authored with logical properties throughout — `left`/`right` never appear,
   so the RTL default and the LTR locale share one stylesheet.
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html,
body {
  height: 100%;
}

body {
  font-family: var(--font-sans);
  font-size: var(--fs-body);
  background: var(--ground-0);
  color: var(--fg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--signal-soft);
}

a {
  color: var(--accent-ink);
  text-decoration: none;
}

a:hover {
  color: var(--signal);
}

h1,
h2,
h3 {
  line-height: 1.35;
  text-wrap: pretty;
}

p {
  text-wrap: pretty;
}

button {
  font: inherit;
  color: inherit;
}

svg {
  display: block;
}

/* Visible focus is a requirement, not a preference — keyboard paths for
   approval and scheduling are covered by tests. */
:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 2px;
  border-radius: var(--r-chip);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-thumb {
  background: var(--line-strong);
  border-radius: var(--r-chip);
}

::-webkit-scrollbar-track {
  background: transparent;
}

@keyframes pulse-signal {
  0%,
  100% { opacity: 0.55; }
  50% { opacity: 1; }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ------------------------------ Utilities -------------------------------- */

.u-mono {
  font-family: var(--font-mono);
}

.u-dim { color: var(--fg-dim); }
.u-mute { color: var(--fg-mute); }

.u-label {
  font-size: 10.5px;
  font-weight: 700;
  letter-spacing: 0.4px;
  text-transform: uppercase;
  color: var(--fg-mute);
}

.u-truncate {
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}

.u-push-end {
  margin-inline-start: auto;
}

.u-sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
