/* Film grain overlay across the whole site */
body::after {
  content: "";
  position: fixed; inset: -50%;
  z-index: 200;
  pointer-events: none;
  opacity: .11;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='220' height='220'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .9 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Local grain for coloured blocks */
.grainy { position: relative; isolation: isolate; }
.grainy::before {
  content: "";
  position: absolute; inset: 0; z-index: -1;
  border-radius: inherit;
  opacity: .22;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.1' numOctaves='2'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* Dotted paper and graph paper backgrounds */
.paper-dots {
  background-image: radial-gradient(rgba(18, 19, 43, .16) 1.2px, transparent 1.3px);
  background-size: 22px 22px;
}
.paper-grid {
  background-image:
    linear-gradient(rgba(42, 52, 142, .09) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42, 52, 142, .09) 1px, transparent 1px);
  background-size: 32px 32px;
}
