:root {
  --bg: #000;
  --fg: limegreen;
  --link: lightgreen;
  --gutter: 1em;
  --fs: 1.3em;
  --flow-space: 1.5em; 
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  background: var(--bg);
  color: var(--fg);
  font-family: monospace;
  margin: 0;
  padding: var(--gutter);
  display: grid;
  grid-template-rows: auto 1fr; 
  min-height: 100dvh;
  font-size: var(--fs);
  padding-bottom: calc(var(--gutter) + env(safe-area-inset-bottom));
  max-width: 140ch;
  margin-inline: auto;
}

main {
  max-width: 70ch;
  padding: 2ch;
  margin: auto;
  text-wrap: balance;
}

a {
  color: var(--link);
  text-decoration: underline;
}

p, ul, div {
  margin-bottom: var(--flow-space);
}

header {
  border-bottom: 1px solid var(--fg);
  margin-bottom: calc(var(--flow-space) * 1.2);
  padding-bottom: 0.5em;
}

.license-note {
  font-size: 0.8em;
  text-align: center;
  margin-top: calc(var(--flow-space) * 1.2);
  line-height: 1.4;
}

.license-note img {
  max-width: 1em;
  max-height: 1em;
  margin-left: 0.2em;
  vertical-align: middle;
}

/* responsive adjustments */
@media only screen and (max-width: 1200px) and (hover: none) {
  :root {
    --fs: 1.1em;
    --flow-space: 5em; 
  }
  main { padding: 3.5em; }
  body { padding: 4em; }
}

@media only screen and (max-width: 380px) and (hover: none) {
  header { display: none; }
  :root {
    --fs: 1em;
    --flow-space: 5.2em; 
  }
}

@media (prefers-reduced-motion: reduce) {
  * { scroll-behavior: auto !important; }
}
