/* =========================================================
   base.css — shared foundation for every Arkhelion page.
   Variables, reset, typography defaults, the grain overlay,
   the cosmic canvas positioning, and the corner frame marks.
   ========================================================= */

:root {
  --bg: #0d0b13;
  --ink: #ece7f2;
  --ink-dim: #8b8398;
  --ink-faint: #57516a;
  --line: #26212f;
  --accent: #c8ac72;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Fraunces', serif;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  position: relative;
}

/* Subtle grain — the one texture on every page */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 2;
  opacity: 0.035;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='120' height='120'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

#cosmicCanvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  background: var(--bg);
  display: block;
}

/* Corner marks — appear only once there's room to breathe */
.frame-corner {
  position: fixed;
  width: 22px;
  height: 22px;
  border: 1px solid var(--ink-faint);
  opacity: 0;
  z-index: 1;
}
@media (min-width: 900px) {
  .frame-corner { opacity: 0.45; }
  .frame-corner.tl { top: 28px; left: 28px; border-right: none; border-bottom: none; }
  .frame-corner.tr { top: 28px; right: 28px; border-left: none; border-bottom: none; }
  .frame-corner.bl { bottom: 28px; left: 28px; border-right: none; border-top: none; }
  .frame-corner.br { bottom: 28px; right: 28px; border-left: none; border-top: none; }
}

footer {
  font-size: 0.78rem;
  color: var(--ink-faint);
}
