/* Scorecard Coach / BetterBudget: shared styles. Light + dark, mobile-first. */
:root {
  --bg: #ffffff; --fg: #1f2328; --muted: #59636e; --line: #d8dee4;
  --accent: #1a7f37; --link: #0b62c4; --code-bg: #f3f5f7; --header-bg: #f7f9fa;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #111416; --fg: #e6edf3; --muted: #9da7b1; --line: #30363d;
    --accent: #3fb950; --link: #6cb6ff; --code-bg: #1c2128; --header-bg: #161b20;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--fg);
  font: 17px/1.6 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
.wrap { max-width: 46rem; margin: 0 auto; padding: 0 1.25rem; }
a { color: var(--link); text-underline-offset: 2px; }
a:hover { text-decoration-thickness: 2px; }
.site-header { background: var(--header-bg); border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: .5rem 1.25rem; padding-top: .8rem; padding-bottom: .8rem; }
.brand { font-weight: 700; color: var(--fg); text-decoration: none; }
nav { display: flex; flex-wrap: wrap; gap: .25rem 1rem; }
nav a { color: var(--muted); text-decoration: none; }
nav a:hover, nav a[aria-current="page"] { color: var(--fg); text-decoration: underline; }
main { padding-top: 1.5rem; padding-bottom: 3rem; }
h1 { font-size: 2rem; line-height: 1.2; margin: .5rem 0 1rem; }
h2 { font-size: 1.35rem; margin: 2.2rem 0 .6rem; padding-top: .4rem; }
h3 { font-size: 1.1rem; margin: 1.6rem 0 .4rem; }
hr { border: 0; border-top: 1px solid var(--line); margin: 2rem 0; }
ul, ol { padding-left: 1.4rem; }
li + li { margin-top: .25rem; }
code { background: var(--code-bg); padding: .1em .35em; border-radius: 4px; font-size: .9em; }
table { display: block; overflow-x: auto; border-collapse: collapse; width: 100%; margin: 1rem 0; font-size: .95rem; }
th, td { border: 1px solid var(--line); padding: .5rem .65rem; text-align: left; vertical-align: top; }
th { background: var(--code-bg); }
.site-footer { border-top: 1px solid var(--line); color: var(--muted); font-size: .9rem; }
.site-footer .wrap { padding-top: 1rem; padding-bottom: 2rem; }
.site-footer p { margin: .3rem 0; }
@media (max-width: 480px) { body { font-size: 16px; } h1 { font-size: 1.65rem; } }
