/* MIRAI — Base
   Minimal element defaults so raw HTML inherits the brand. Consumers linking styles.css
   get sensible typography, link colours (never browser-default blue), and focus rings. */

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--text-body);
  line-height: var(--leading-normal);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  font-variant-ligatures: contextual;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-display);
  font-weight: var(--weight-semibold);
  line-height: var(--leading-snug);
  letter-spacing: var(--tracking-snug);
  color: var(--text);
  margin: 0 0 var(--space-4);
  text-wrap: balance;
}
h1 { font-size: var(--text-h1); }
h2 { font-size: var(--text-h2); }
h3 { font-size: var(--text-h3); font-weight: var(--weight-medium); }
h4 { font-size: var(--text-h4); font-weight: var(--weight-medium); }

p { margin: 0 0 var(--space-4); text-wrap: pretty; }

a { color: var(--link); text-decoration: none; transition: var(--transition-colors); }
a:hover { color: var(--link-hover); text-decoration: underline; text-underline-offset: 0.15em; text-decoration-thickness: 1px; }

small { font-size: var(--text-body-sm); }
code, kbd, samp, pre { font-family: var(--font-mono); font-size: 0.9em; }

hr { border: 0; border-top: var(--border-hairline); margin: var(--space-6) 0; }

::selection { background: color-mix(in srgb, var(--action) 22%, transparent); color: var(--text); }

:focus-visible { outline: 2px solid var(--border-focus); outline-offset: 2px; border-radius: var(--radius-xs); }

img, svg, video { max-width: 100%; height: auto; display: block; }

/* Layout helpers used across cards / kits. */
.mirai-container { max-width: var(--container-xl); margin-inline: auto; padding-inline: var(--gutter); }
