/* The page itself: the ground everything sits on, and the defaults text
   inherits into every component. Component styles live in their own files,
   inside their shadow roots; nothing here may style an fx-* element's
   insides. Every value is a token from generated/tokens.css. */

*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }

/* The wallpaper is the most prominent element on the screen, and --fx-bg
   behind it is what niri paints when there is none.

   It is a fixed layer of its own, not `background-attachment: fixed`: that
   makes the browser repaint the whole image under anything that moves, and
   everything here moves over it. As its own layer it is painted once and
   only composited after. */
body {
  overflow: hidden;
  background: var(--fx-bg);
  color: var(--fx-fg);
  font-family: var(--fx-mono);
  font-size: var(--fx-font-size);
  line-height: var(--fx-line-height);
  font-weight: var(--fx-weight-value);
  -webkit-font-smoothing: antialiased;
}
body::before {
  content: '';
  position: fixed;
  inset: 0;
  z-index: -1;
  background: url('assets/wallpaper.jpg') center / cover no-repeat;
  will-change: transform;
}

/* Undefined until their module loads: hidden rather than drawn unstyled. */
:not(:defined) { visibility: hidden; }

::selection { background: var(--fx-accent); color: var(--fx-bg); }
:focus-visible { outline: 1px solid var(--fx-accent); outline-offset: 2px; }

a { color: var(--fx-info); }

/* Placeholder apps inside windows. A real app brings its own look; these
   only have to read as "something is running here". */
.app { padding: var(--fx-pad); }
.app h1 {
  margin: 0 0 var(--fx-space-3);
  font-size: inherit;
  font-weight: var(--fx-weight-heading);
  color: var(--fx-accent);
  text-transform: uppercase;
  letter-spacing: 0.08em;
}
.app p { margin: 0 0 var(--fx-space-2); }
.app .dim { color: var(--fx-dim); }
