/* EchoNet current restore stylesheet, 2026-07-08. */

:root {
  /* One ambient surface. Cards and panels are gone; only code blocks retain a tint. */
  --bg: #161922;
  --bg-code: #1f2535;
  --fg: #e8e9ee;
  --fg-dim: #9ba0ac;
  --fg-faint: #6b7080;
  --accent: #7dd3fc;
  --accent-strong: #38bdf8;
  --accent-warm: #fbbf24;
  --hairline: #2a3040;
  --reading-width: 38rem;
  --frame-width: 56rem;
  --mono: ui-monospace, "Cascadia Mono", "Roboto Mono", Menlo, Consolas, monospace;
  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Charter", "Georgia", "Times New Roman", serif;
}

* { box-sizing: border-box; }

html {
  -webkit-text-size-adjust: 100%;
  font-size: 17px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--serif);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.wrap {
  width: 100%;
  max-width: var(--reading-width);
  margin: 0 auto;
  padding: 0 1.2rem;
}

/* Privacy disclosure now lives in the footer — see .footer-privacy */

/* Header — not sticky. Reader leaves the chrome behind on scroll */
.site-header {
  padding: 1.4rem 0 0.8rem;
}
.site-header .wrap {
  max-width: var(--frame-width);
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
}
.brand {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: -0.005em;
  text-decoration: none;
  color: var(--fg);
}
.brand-echo, .brand-net, .brand-ai { color: inherit; }
.site-nav {
  display: flex;
  gap: 1.4rem;
  font-family: var(--sans);
  font-size: 0.92rem;
}
.site-nav a {
  color: var(--fg-dim);
  text-decoration: none;
  transition: color 0.15s;
}
.site-nav a:hover { color: var(--fg); }

/* Main */
.site-main { flex: 1; padding: 3rem 0 5rem; }
.site-main .wrap { max-width: var(--reading-width); }
body.home-page .site-main .wrap { max-width: var(--frame-width); }

/* Hero — type alone, no enclosed box, no border-bottom */
.hero {
  padding: 1rem 0 2.5rem;
}
.hero-title {
  font-family: var(--sans);
  font-size: clamp(1.8rem, 4.5vw, 2.6rem);
  line-height: 1.15;
  margin: 0 0 1rem;
  letter-spacing: -0.015em;
  max-width: 22ch;
}
.hero-sub {
  color: var(--fg-dim);
  font-size: 1.05rem;
  margin: 0.5rem 0;
  max-width: 36rem;
  line-height: 1.55;
}

/* Microtype section labels — the kept craft signal */
.section-heading {
  font-family: var(--sans);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-faint);
  margin: 3.5rem 0 1.2rem;
  font-weight: 600;
}

/* Archive: list rhythm, hairlines, no panels */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
  border-top: 1px solid var(--hairline);
}
.post-card {
  border-bottom: 1px solid var(--hairline);
}
.post-card-link {
  display: block;
  padding: 1.4rem 0;
  text-decoration: none;
  color: inherit;
  transition: opacity 0.15s;
}
.post-card-link:hover .post-card-title { color: var(--accent); }
.post-card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  font-family: var(--sans);
  font-size: 0.76rem;
  color: var(--fg-faint);
  margin-bottom: 0.4rem;
  align-items: baseline;
  letter-spacing: 0.02em;
}
.post-card-category {
  color: var(--fg-dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.7rem;
  font-weight: 600;
}
.post-card-title {
  font-family: var(--sans);
  font-size: 1.3rem;
  line-height: 1.3;
  margin: 0.2rem 0 0.4rem;
  color: var(--fg);
  letter-spacing: -0.01em;
  font-weight: 600;
  transition: color 0.15s;
}
.post-card-desc {
  color: var(--fg-dim);
  margin: 0;
  font-size: 0.97rem;
  line-height: 1.55;
  max-width: 42rem;
}

.category-section { margin-bottom: 0; }
.category-heading {
  font-family: var(--sans);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-faint);
  margin: 3.5rem 0 1.2rem;
  font-weight: 600;
}

/* Single post — no enclosing border, just space */
.post-header {
  padding-bottom: 0;
  margin-bottom: 2.5rem;
}
.post-meta {
  display: flex;
  gap: 1rem;
  font-family: var(--sans);
  font-size: 0.78rem;
  color: var(--fg-faint);
  margin-bottom: 1rem;
  flex-wrap: wrap;
  align-items: baseline;
  letter-spacing: 0.02em;
}
.post-category {
  color: var(--fg-dim);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-size: 0.72rem;
  font-weight: 600;
}
.post-title {
  font-family: var(--sans);
  font-size: clamp(1.9rem, 4.5vw, 2.5rem);
  line-height: 1.15;
  margin: 0.5rem 0 1.2rem;
  letter-spacing: -0.015em;
}
.post-lede {
  font-size: 1.15rem;
  color: var(--fg-dim);
  line-height: 1.55;
  margin: 0;
}

/* Post body */
.post-body {
  font-size: 1.08rem;
  line-height: 1.78;
}
.post-body p, .post-body ul, .post-body ol, .post-body blockquote, .post-body pre {
  margin: 1.3rem 0;
}
.post-body h2 {
  font-family: var(--sans);
  font-size: 1.5rem;
  margin: 2.8rem 0 1rem;
  letter-spacing: -0.01em;
  line-height: 1.25;
}
.post-body h3 {
  font-family: var(--sans);
  font-size: 1.2rem;
  margin: 2.2rem 0 0.8rem;
  color: var(--fg);
}
.post-body a {
  color: var(--accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
.post-body a:hover { color: var(--accent-strong); }
.post-body strong { color: var(--fg); font-weight: 700; }
.post-body em { color: var(--fg); }
.post-body ul, .post-body ol { padding-left: 1.5rem; }
.post-body li { margin: 0.5rem 0; }
.post-body blockquote {
  border-left: 2px solid var(--hairline);
  padding: 0.2rem 0 0.2rem 1.2rem;
  margin-left: 0;
  color: var(--fg-dim);
  font-style: italic;
}
.post-body code {
  font-family: var(--mono);
  font-size: 0.92em;
  background: var(--bg-code);
  padding: 0.1rem 0.35rem;
  border-radius: 3px;
  color: var(--accent-warm);
}
.post-body pre {
  background: var(--bg-code);
  border: 1px solid var(--hairline);
  border-radius: 4px;
  padding: 1rem;
  overflow-x: auto;
  font-size: 0.9rem;
  line-height: 1.5;
}
.post-body pre code {
  background: transparent;
  padding: 0;
  color: var(--fg);
}
.post-body hr {
  border: 0;
  border-top: 1px solid var(--hairline);
  margin: 2.5rem 0;
}
.post-body figure {
  margin: 1.8rem 0 2rem;
}
.post-body img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--hairline);
}
.post-body figcaption {
  margin-top: 0.55rem;
  color: var(--fg-faint);
  font-family: var(--sans);
  font-size: 0.82rem;
  line-height: 1.45;
}
.post-body table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--sans);
  font-size: 0.93rem;
  margin: 1.5rem 0;
}
.post-body th, .post-body td {
  border-bottom: 1px solid var(--hairline);
  padding: 0.6rem 0.4rem;
  text-align: left;
  vertical-align: top;
}
.post-body th {
  font-weight: 600;
  color: var(--fg);
  border-bottom: 2px solid var(--hairline);
}

/* Related posts — flat list with hairlines, no panels */
.related-posts {
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--hairline);
}
.related-heading {
  font-family: var(--sans);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--fg-faint);
  margin: 0 0 1rem;
  font-weight: 600;
}
.related-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.related-list > li,
.related-item {
  border-bottom: 1px solid var(--hairline);
}
.related-list > li:first-child,
.related-item:first-child {
  border-top: 1px solid var(--hairline);
}
.related-list a,
.related-item a {
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
  padding: 0.9rem 0;
  text-decoration: none;
  color: var(--fg);
}
.related-list a:hover .related-title,
.related-item a:hover .related-title { color: var(--accent); }
.related-list a:visited,
.related-item a:visited { color: var(--fg); }
.related-date {
  font-family: var(--sans);
  font-size: 0.74rem;
  color: var(--fg-faint);
  letter-spacing: 0.02em;
}
.related-title {
  font-family: var(--sans);
  color: var(--fg);
  font-size: 1rem;
  line-height: 1.35;
  transition: color 0.15s;
}

/* Post footer — italic single line, no panel */
.post-footer {
  margin-top: 3.5rem;
  padding-top: 2rem;
  border-top: 1px solid var(--hairline);
}
.post-footer-cta {
  font-family: var(--serif);
  color: var(--fg-dim);
  font-size: 1rem;
  font-style: italic;
  margin: 0;
}
.post-footer-cta a { color: var(--accent); }
.post-footer-back {
  margin-top: 1.5rem;
  font-family: var(--sans);
  font-size: 0.92rem;
}
.post-footer-back a {
  color: var(--fg-dim);
  text-decoration: none;
}
.post-footer-back a:hover { color: var(--accent); }

/* Static pages */
.page-content h1 {
  font-family: var(--sans);
  font-size: clamp(1.8rem, 4vw, 2.4rem);
  letter-spacing: -0.015em;
  margin: 0 0 1.5rem;
}
.page-content h2 {
  font-family: var(--sans);
  font-size: 1.35rem;
  margin: 2.5rem 0 0.8rem;
  letter-spacing: -0.01em;
}
.page-content h3 {
  font-family: var(--sans);
  font-size: 1.1rem;
  margin: 1.8rem 0 0.6rem;
  color: var(--fg);
}
.page-content p { margin: 1rem 0; line-height: 1.7; font-size: 1.02rem; }
.page-content a { color: var(--accent); }
.page-content ul, .page-content ol {
  padding-left: 1.5rem;
  margin: 1rem 0;
  line-height: 1.7;
  font-size: 1.0rem;
}
.page-content li { margin: 0.4rem 0; }
.page-content strong { color: var(--fg); font-weight: 600; }

/* Privacy-policy structured markup — flatten panels into hairline list */
.page-content ul.index {
  list-style: none;
  padding-left: 0;
  columns: 2;
  column-gap: 2rem;
}
.page-content ul.index li { margin: 0.3rem 0; }
.page-content .index-link { text-decoration: none; color: var(--accent); }
.page-content .index-link:hover { text-decoration: underline; }
.page-content ul.m-elements {
  list-style: none;
  padding-left: 0;
  border-top: 1px solid var(--hairline);
  margin-top: 1rem;
}
.page-content ul.m-elements > li {
  padding: 0.9rem 0;
  margin: 0;
  border-bottom: 1px solid var(--hairline);
}
.page-content ul.glossary { font-size: 0.95rem; }
.page-content ul.glossary > li { margin: 0.8rem 0; }
.page-content .seal {
  margin-top: 3rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--hairline);
  font-size: 0.85rem;
  color: var(--fg-faint);
}
.page-content .seal a { color: var(--fg-faint); }
.page-content .seal a:hover { color: var(--fg-dim); }

.dsg-license-content-blurred { display: none !important; }

@media (max-width: 560px) {
  .page-content ul.index { columns: 1; }
}

/* Footer — quiet, hairline above */
.site-footer {
  border-top: 1px solid var(--hairline);
  padding: 2rem 0 2.5rem;
  color: var(--fg-faint);
  font-size: 0.82rem;
  font-family: var(--sans);
}
.site-footer .wrap { max-width: var(--frame-width); }
.footer-text { margin: 0 0 0.3rem; color: var(--fg-faint); }
.footer-disclosure {
  margin: 0 0 0.5rem;
  font-size: 0.78rem;
  color: var(--fg-faint);
}
.footer-meta { margin: 0; }
.footer-meta a { color: var(--fg-dim); text-decoration: none; }
.footer-meta a:hover { color: var(--fg); }
.footer-privacy {
  margin: 1.2rem 0 0;
  font-size: 0.76rem;
  color: var(--fg-faint);
  letter-spacing: 0.01em;
}

/* Light-mode override — same Glass Box, lighter palette */
@media (prefers-color-scheme: light) {
  :root {
    --bg: #f8f7f2;
    --bg-code: #efece4;
    --fg: #1a1d24;
    --fg-dim: #4b5563;
    --fg-faint: #6b7280;
    --accent: #0284c7;
    --accent-strong: #0369a1;
    --accent-warm: #b45309;
    --hairline: #d8d4ca;
  }
}

/* Small screens */
@media (max-width: 560px) {
  html { font-size: 16px; }
  .site-header .wrap { flex-direction: row; }
  .site-nav { gap: 1rem; font-size: 0.88rem; }
  .post-card-link { padding: 1.2rem 0; }
  .post-card-title { font-size: 1.15rem; }
}
