/* tegus.dev: one stylesheet, colour tokens for light and dark.
   Palette (Henry, 2026-11-08): black #000, deep teal #638475, dusk blue #4a5899, lavender #ccd6eb, ghost white #f4f4f9.
   Teal is an accent for marks and hover states only: as text on a light background it does not reach 4.5:1,
   so links and small meta text use dusk blue.
   Type: Work Sans for the page, Fraunces for the home headline, both from Google Fonts (Henry, 2026-11-08). */
:root {
  --bg: #f4f4f9; --surface: #ffffff; --ink: #000000; --muted: #565f73; --line: #ccd6eb;
  --accent: #638475; --link: #4a5899; --rail: #4a5899; --rail-hover: #638475;
  /* The bio panel keeps one gradient in both themes, so the brand reads the same on either background. */
  --panel: linear-gradient(170deg, #4a5899 0%, #313c69 100%);
  --panel-ink: #f4f4f9; --panel-muted: #d6ddee; --panel-mark: #ccd6eb; --panel-line: rgba(244, 244, 249, .45);
  --quote-bg: #e6ebf5; --heading-sub: #4a5899;
  --radius: 16px;
  --body-font: "Work Sans", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --display-font: "Fraunces", Georgia, "Iowan Old Style", "Times New Roman", serif;
  color-scheme: light dark;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000; --surface: #101320; --ink: #f4f4f9; --muted: #aab4cc; --line: #2b3348;
    --accent: #8aa89a; --link: #8e9bd0; --rail: #8e9bd0; --rail-hover: #8aa89a;
    --quote-bg: #161a2b; --heading-sub: #8e9bd0;
  }
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 17px/1.65 var(--body-font);
}
a { color: var(--link); text-underline-offset: 3px; }
img { max-width: 100%; height: auto; }
.wrap { max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.wrap.narrow { max-width: 760px; }
@media (max-width: 480px) { .wrap { padding: 0 16px; } body { font-size: 16px; } }
:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; }

/* Site bar: every page except the home page, which carries its mark inside the panel. */
.top { border-bottom: 1px solid var(--line); background: var(--bg); position: sticky; top: 0; z-index: 2; }
.bar { display: flex; align-items: center; justify-content: space-between; height: 64px; }
.mark { font-weight: 800; font-size: 21px; color: var(--ink); text-decoration: none; letter-spacing: -.01em; }
.mark span { color: var(--link); }   /* dusk, so the bar matches the panel under it */
nav a { color: var(--ink); text-decoration: none; margin-left: 22px; font-weight: 600; }
nav a:hover { color: var(--link); }

h1, h2, h3 { line-height: 1.2; letter-spacing: -.015em; }
h1 { font-size: clamp(30px, 5vw, 44px); margin: 0 0 12px; }
.muted { color: var(--muted); }

/* Home: bio panel pinned left, live sites listed right. */
.split { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: 48px; padding: 46px 0 0; }
.panel {
  position: sticky; top: 34px; align-self: start; min-width: 0;
  background: var(--panel); border-radius: var(--radius); overflow: hidden;
}
.panel-head { padding: 18px 26px 16px; }
.panel-mark { font-size: 17px; font-weight: 700; letter-spacing: .01em; color: var(--panel-mark); }
.panel-mark span { color: var(--panel-ink); }
.panel-body { padding: 20px 26px 28px; }
.panel-body h1 {
  font-family: var(--display-font); font-weight: 600; font-size: clamp(26px, 3.4vw, 34px);
  line-height: 1.16; letter-spacing: -.005em; text-wrap: balance; color: var(--panel-ink); margin: 0 0 14px;
}
.panel-body p { margin: 0 0 18px; color: var(--panel-muted); font-size: 15.5px; }
.panel-link {
  display: inline-block; font-size: 14.5px; font-weight: 650; color: var(--panel-ink); text-decoration: none;
  border-bottom: 1px solid var(--panel-line); padding-bottom: 3px;
}
.panel-link:hover { border-bottom-color: var(--panel-ink); }

.listing { min-width: 0; padding-bottom: 10px; }
.listing h2 {
  font-size: 12px; font-weight: 700; letter-spacing: .13em; text-transform: uppercase;
  color: var(--muted); margin: 6px 0 16px;
}
.entry {
  display: grid; gap: 8px; background: var(--surface); border: 1px solid var(--line);
  border-left: 3px solid var(--rail); border-radius: 0 12px 12px 0; padding: 19px 20px; margin-bottom: 12px;
  color: var(--ink); text-decoration: none; transition: border-left-color .15s ease, transform .15s ease;
}
.entry:hover { border-left-color: var(--rail-hover); transform: translateX(2px); }
.entry-top { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px 12px; }
.entry-name { font-size: 18.5px; font-weight: 650; letter-spacing: -.01em; }
.entry-host { font-size: 13px; font-weight: 600; color: var(--link); }
.entry-country {
  margin-left: auto; font-size: 11.5px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase;
  color: var(--muted); border: 1px solid var(--line); border-radius: 999px; padding: 3px 9px;
}
.entry-summary { color: var(--muted); font-size: 14.5px; line-height: 1.55; }
@media (max-width: 760px) {
  .split { grid-template-columns: 1fr; gap: 32px; padding-top: 28px; }
  .panel { position: static; }
}
@media (prefers-reduced-motion: reduce) {
  .entry { transition: none; }
  .entry:hover { transform: none; }
}

/* Long-form pages: /about-me/, the privacy pages, 404. */
.doc-head { background: var(--panel); border-radius: var(--radius); padding: 30px 28px 32px; margin: 28px 0 0; }
.doc-head h1 {
  font-family: var(--display-font); font-weight: 600; font-size: clamp(29px, 5vw, 40px);
  color: var(--panel-ink); margin: 0; text-wrap: balance;
}
.doc-head p { margin: 12px 0 0; color: var(--panel-mark); font-size: 16px; max-width: 52ch; }
.crumb { margin: 28px 0 0; font-size: 15px; }
.crumb a { text-decoration: none; }
.prose { padding: 20px 0 40px; }
.prose h1 { font-family: var(--display-font); font-weight: 600; margin-top: 28px; }
.prose h2 {
  font-family: var(--display-font); font-weight: 600; font-size: 1.5em;
  margin-top: 2em; padding-top: 1.1em; border-top: 1px solid var(--line);
}
/* No rule on the first heading: it would sit right under the title panel. */
.prose h2:first-child { margin-top: .6em; padding-top: 0; border-top: 0; }
.prose h3 { margin-top: 1.7em; font-size: 1.14em; font-weight: 650; color: var(--heading-sub); letter-spacing: -.01em; }
.prose blockquote {
  margin: 1.6em 0; padding: 16px 20px; background: var(--quote-bg);
  border-left: 4px solid var(--accent); border-radius: 0 12px 12px 0; color: var(--muted);
}
.prose blockquote p:last-child { margin-bottom: 0; }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.4em 0; }
/* The farewell under the rule: the cat sits on the quote surface, the sign-off takes the dusk tone. */
.prose hr + p.center img { background: var(--quote-bg); border-radius: 18px; padding: 14px; }
.prose p.center { color: var(--muted); }
.prose p.center em { font-style: normal; font-weight: 650; font-size: 1.1em; color: var(--heading-sub); }
.center { text-align: center; }
.center-block { text-align: center; padding-top: 60px; }

.foot {
  border-top: 1px solid var(--line); margin-top: 48px; padding-top: 18px; padding-bottom: 40px;
  color: var(--muted); font-size: 15px;
}
.foot a { color: var(--muted); }
