:root {
  --bg: #0d1117;
  --fg: #c9d1d9;
  --host: #3fb950;   /* green hostname */
  --sep: #8b949e;    /* :~$ separator + welcome/colophon text */
  --link: #58a6ff;   /* blue links */
  --comment: #6e7681;/* # inline comments */
  --border: #21262d;
  --mono: ui-monospace, "SF Mono", Menlo, Consolas, "Liberation Mono", monospace;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: #010409;
  color: var(--fg);
  font-family: var(--mono);
  font-size: 15px;
  line-height: 1.85;
  display: grid;
  place-items: center;
  padding: 2rem 1rem;
}

.term {
  width: 100%;
  max-width: 680px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1.75rem 1.5rem;
}

/* page title rendered as a shell prompt header */
.prompt-host {
  font-size: 1rem;
  font-weight: 600;
  color: var(--host);
  margin: 0 0 1.25rem;
}
.prompt-host::after {
  content: ":~$";
  color: var(--sep);
  font-weight: 400;
}

/* spacing for every prompt line and category block.
   The prompt text itself (psfo.com:~$ ...) is added below. */
.line,
.dir {
  margin: 0 0 0.9rem;
  color: var(--fg);
}

/* welcome + colophon comment text sits in grey under their prompt line */
.welcome,
.colophon {
  color: var(--sep);
}

/* --- prompt lines, rendered from data attributes ---
   One ::before per element, so each prompt line is a single color (host green).
   This closely matches the approved mockup; a pixel-exact green-host +
   default-command + grey-note split would need extra inline spans (YAGNI). */

/* category blocks: `psfo.com:~$ ls following/  # security people worth following` */
.dir::before {
  content: "psfo.com:~$ " attr(data-cmd);
  display: block;
  color: var(--host);
}
.dir[data-note]::before {
  content: "psfo.com:~$ " attr(data-cmd) "   # " attr(data-note);
}

/* welcome / colophon: prompt+command line above their grey comment text */
.welcome::before,
.colophon::before {
  content: "psfo.com:~$ " attr(data-cmd);
  display: block;
  color: var(--host);
}

/* --- link rows --- */
.dir ul {
  list-style: none;
  margin: 0.1rem 0 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1.25rem;
}
.dir li { margin: 0; }

.dir a {
  color: var(--link);
  text-decoration: none;
}
.dir a:hover,
.dir a:focus-visible {
  text-decoration: underline;
}

/* --- books: `ls -l` long-listing with an aligned status column --- */
.books ul {
  flex-direction: column;
  gap: 0.15rem 0;
}
.books li {
  display: flex;
  gap: 1.1rem;
}
.books .status {
  flex: 0 0 auto;
  width: 5.5em;
  color: var(--sep);
}
.books .status.reading {
  color: var(--host);
}

/* visually-hidden headings for screen readers */
.sr-only {
  position: absolute;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

/* final prompt line ends in a blinking block cursor */
.cursor::before {
  content: "psfo.com:~$ ";
  color: var(--host);
}
.cursor::after {
  content: "";
  display: inline-block;
  width: 0.55em;
  height: 1.05em;
  vertical-align: text-bottom;
  background: var(--fg);
  animation: blink 1.1s step-end infinite;
}

@keyframes blink {
  0%, 50% { opacity: 1; }
  50.01%, 100% { opacity: 0; }
}

/* respect users who ask for less motion: show a steady cursor, no blink */
@media (prefers-reduced-motion: reduce) {
  .cursor::after { animation: none; }
}

/* --- world cup page (/worldcup) --- */

/* reusable prompt line: `psfo.com:~$ <cmd>` rendered from data-cmd */
.cmdline::before {
  content: "psfo.com:~$ " attr(data-cmd);
  display: block;
  color: var(--host);
}
.cmdline a {
  color: var(--link);
  text-decoration: none;
}
.cmdline a:hover,
.cmdline a:focus-visible {
  text-decoration: underline;
}

.wc-date { color: var(--sep); }

.wc ul {
  list-style: none;
  margin: 0.3rem 0 0.9rem;
  padding: 0;
}

.wc-match {
  display: flex;
  flex-wrap: wrap;
  gap: 0.1rem 1.1rem;
  padding: 0.4rem 0;
  border-bottom: 1px solid var(--border);
}
.wc-time     { color: var(--host); min-width: 9em; }
.wc-teams    { color: var(--fg); }
.wc-venue    { color: var(--sep); }
.wc-channels { color: var(--comment); }

.wc-empty { color: var(--sep); }
