/* Minimal readable styles for Markdown-derived HTML */

:root {
  --text: #1f2937;          /* gray-800 */
  --muted: #6b7280;         /* gray-500 */
  --border: #e5e7eb;        /* gray-200 */
  --bg-soft: #f9fafb;       /* gray-50 */
  --link: #2563eb;          /* blue-600 */
  --link-hover: #1d4ed8;    /* blue-700 */
  --link-visited: #7c3aed;  /* purple-600 */
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  color: var(--text);
  background: #fff;
  font-family: Helvetica, Arial, "Noto Sans", "Liberation Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji";
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

main {
  max-width: 70ch;
  margin: 2rem auto 0;
  padding: 0 1rem 2rem;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 700;
  line-height: 1.25;
  margin: 1.5em 0 0.5em;
}

h1 { font-size: 2rem; }
h2 { font-size: 1.625rem; }
h3 { font-size: 1.375rem; }
h4 { font-size: 1.125rem; }
h5 { font-size: 1rem; }
h6 { font-size: 0.875rem; letter-spacing: 0.02em; text-transform: uppercase; color: var(--muted); }

p, ul, ol, blockquote, pre, table {
  margin: 1em 0;
}

ul, ol {
  padding-left: 1.25rem;
}

li + li {
  margin-top: 1.0em;
}

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

a + a {
  margin-left: 0.5rem;
}

a:visited {
  color: var(--link-visited);
}

a:hover {
  color: var(--link-hover);
}

a:focus-visible {
  outline: 2px solid color-mix(in oklab, var(--link) 35%, black);
  outline-offset: 2px;
  border-bottom-color: transparent;
}

/* Code */
code, kbd, samp, pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

code {
  background: #f6f8fa;
  padding: 0.15em 0.35em;
  border-radius: 4px;
}

pre {
  background: #f6f8fa;
  padding: 1rem;
  overflow: auto;
  border-radius: 6px;
}

pre code {
  background: transparent;
  padding: 0;
}

/* Blockquote */
blockquote {
  padding: 0.75em 1em;
  border-left: 4px solid var(--border);
  background: var(--bg-soft);
  color: #374151; /* gray-700 */
}

/* Images */
img, svg, video {
  max-width: 100%;
  height: auto;
}

img {
  display: block;
  margin: 1rem auto;
}

/* Horizontal rule */
hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 2rem 0;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
}

th, td {
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--border);
  vertical-align: top;
}

thead th {
  background: #f3f4f6; /* gray-100 */
}

/* Misc */
small { color: var(--muted); }

/* Make top of page breathe a bit when no <main> is used */
.container, .content, article {
  max-width: 70ch;
  margin: 2rem auto;
  padding: 0 1rem;
}

/* Print basics */
@media print {
  a { color: inherit; border: 0; }
  pre { white-space: pre-wrap; }
}


