/*
  Emerald — a personal studio, September 2026.
  Owner-approved amendment to specification section 10: detailed pixel art
  anchors the homepage; ordinary typography and calm surfaces carry content.
  The studio is an imagined illustration, not a depiction of a real room.
  The design needs no browser JavaScript, webfonts, remote assets or decorative animation.
  Optional owner-approved analytics is configured separately.
  Previous cabinet design is preserved in lapidary.css.
*/
:root {
  color-scheme: dark;
  --ink: #f5efdc;
  --muted: #bdc9bb;
  --green: #102c27;
  --green-deep: #0c221e;
  --amber: #e9bb76;
  --paper: #f3efe3;
  --paper-ink: #21382f;
  --paper-muted: #59645a;
  --rule: #d5d8c9;
  --sans: system-ui, -apple-system, "Segoe UI", sans-serif;
  --serif: Georgia, "Times New Roman", serif;
  --mono: ui-monospace, "Cascadia Mono", Consolas, monospace;
  --pad: clamp(1.25rem, 4vw, 4rem);
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 2rem; }
body {
  margin: 0; min-height: 100vh; display: flex; flex-direction: column;
  background: var(--green); color: var(--ink);
  font: 1.0625rem/1.7 var(--sans); -webkit-font-smoothing: antialiased;
}
main { flex: 1; }
h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
h1, h2, h3, h4 { line-height: 1.16; text-wrap: balance; }
a { color: inherit; text-underline-offset: .25em; }
a:hover { text-decoration-thickness: 2px; }
img { max-width: 100%; height: auto; }
::selection { background: #e9bb76; color: #102c27; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 5px; }
.wrap { width: 100%; max-width: 88rem; margin-inline: auto; padding-inline: var(--pad); }
.skip-link {
  position: absolute; z-index: 10; top: .5rem; left: .5rem;
  padding: .75rem 1rem; background: var(--paper); color: var(--green);
  transform: translateY(-160%);
}
.skip-link:focus { transform: none; }
.site-header { background: var(--green); color: var(--ink); }
.site-header-inner {
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: .25rem 2rem; padding-block: 1.45rem;
}
.site-identity { font: 500 .9375rem/1.5 var(--mono); }
.site-identity a { display: inline-flex; align-items: center; gap: .85rem; }
.site-mark {
  display: block; flex: none; width: 2.75rem; height: 2.75rem;
  object-fit: contain;
}
.site-identity a, .nav-list a { padding-block: .6rem; text-decoration: none; }
.site-identity a:hover, .nav-list a:hover { text-decoration: underline; }
.nav-list { display: flex; gap: 2.5rem; list-style: none; padding: 0; font-size: .9375rem; }
.nav-list a { display: block; color: var(--muted); }
.nav-list a:hover { color: var(--ink); }
.hero { padding-block: 1.5rem 4.5rem; }
.hero-layout { display: grid; grid-template-columns: minmax(0, .78fr) minmax(0, 1.22fr); gap: clamp(2rem, 4vw, 4rem); align-items: center; }
.hero-copy { padding-block: 2rem; }
.eyebrow, .section-label, .related h2 {
  font: 500 .8125rem/1.6 var(--mono); text-transform: uppercase; letter-spacing: .12em;
}
.hero-eyebrow { color: var(--amber); margin-bottom: 2rem; }
.hero-name { max-width: 9ch; font: 400 clamp(3.5rem, 5.5vw, 5.25rem)/1.02 var(--serif); letter-spacing: -.045em; text-wrap: initial; }
.hero-statement { max-width: 31ch; margin-top: 2rem; font-size: clamp(1.0625rem, 1.45vw, 1.25rem); line-height: 1.7; color: var(--muted); }
.hero-copy::after { content: ""; display: block; margin-top: 2.5rem; width: 3rem; height: 2px; background: var(--amber); }
.studio-art { position: relative; }
.studio-art img { display: block; width: 100%; aspect-ratio: 1.28; object-fit: cover; object-position: 49% center; image-rendering: pixelated; }
.studio-art::after { content: ""; display: block; width: 3rem; height: 3px; margin-top: 1rem; background: var(--amber); }
.section { background: var(--paper); color: var(--paper-ink); padding-block: 3.5rem; }
.section + .section { padding-top: 0; }
.section-grid { display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: 3rem; }
.section + .section .section-grid { padding-top: 3.5rem; position: relative; }
.section + .section .section-grid::before { content: ""; position: absolute; top: 0; left: var(--pad); right: var(--pad); height: 1px; background: var(--rule); }
.section-label { color: var(--paper-muted); padding-top: .3rem; }
.section-label::before { content: ""; display: block; width: .5rem; height: .5rem; margin-bottom: 1.25rem; background: #5c8164; }
.entries { list-style: none; padding: 0; }
.entry { position: relative; padding-block: 1.6rem; border-top: 1px solid var(--rule); }
.entry:first-child { padding-top: 0; border: 0; }
.entry:last-child { padding-bottom: 0; }
.entry-title { font: 400 clamp(1.5rem, 2.3vw, 2rem)/1.2 var(--serif); letter-spacing: -.025em; }
.entry-title a { text-decoration: none; }
.entry-title a::after { content: "↗"; display: inline-block; margin-left: .65rem; font: 400 1rem var(--sans); color: #5c7465; }
.entry-title a:hover { text-decoration: underline; text-decoration-thickness: 1px; }
.entry-summary { margin-top: .75rem; max-width: 45rem; color: var(--paper-muted); }
.entry-meta, .page-meta { display: flex; flex-wrap: wrap; gap: .5rem 1rem; margin-top: 1rem; color: var(--paper-muted); font: .75rem/1.6 var(--mono); text-transform: uppercase; letter-spacing: .055em; }
.draft-flag { border: 1px solid #9ea58f; padding: 0 .35rem; }
.preview-notice { padding: .5rem var(--pad); background: #e9bb76; color: #20352a; text-align: center; font: .8125rem/1.6 var(--mono); }
.section :focus-visible, .page :focus-visible { outline-color: #32664e; }
/* A quiet reading surface; artwork stays above the text. */
body:has(.page) { background: var(--paper); color: var(--paper-ink); color-scheme: light; }
.page { padding-bottom: clamp(3rem, 8vw, 6rem); }
.page::before { content: ""; display: block; height: clamp(4rem, 10vw, 8rem); background: var(--green-deep) url("/assets/images/studio.png") center 39% / cover; image-rendering: pixelated; }
.page::before { background-image: image-set(url("/assets/images/studio-1536.webp") type("image/webp"), url("/assets/images/studio.png") type("image/png")); }
.page-wrap { max-width: 51rem; padding-top: clamp(2.5rem, 6vw, 4.5rem); }
.page .eyebrow { margin-bottom: 1rem; color: #47694f; }
.page-title { font: 400 clamp(2.5rem, 5vw, 3.75rem)/1.08 var(--serif); letter-spacing: -.035em; }
.lede { margin-top: 1.5rem; font-size: 1.25rem; line-height: 1.65; color: var(--paper-muted); }
.page-meta { margin-top: 1.5rem; }
.page-wrap > p:last-child:not(.lede):not(.page-meta) { margin-top: 1.5rem; }
.draft-notice { margin-bottom: 2rem; padding: .75rem 1rem; border-left: 3px solid #b18c4f; background: #e9e4d5; color: #59604f; font-size: .875rem; }
.prose { margin-top: 2.75rem; font-size: 1.125rem; line-height: 1.8; overflow-wrap: anywhere; }
.prose > * + * { margin-top: 1.4rem; }
.prose h2 { margin-top: 2.75rem; font: 400 1.875rem/1.25 var(--serif); letter-spacing: -.02em; }
.prose h3 { margin-top: 2rem; font-size: 1.25rem; }
.prose h4 { margin-top: 1.75rem; font-size: 1.125rem; }
.prose a { color: #286046; }
.prose ul, .prose ol { padding-left: 1.5rem; }
.prose li + li { margin-top: .5rem; }
.prose blockquote { margin-inline: 0; padding-left: 1.5rem; border-left: 2px solid #79947a; color: var(--paper-muted); }
.prose code { background: #e6e6d9; padding: .12em .3em; font: .875em var(--mono); }
.prose pre { padding: 1.25rem; overflow-x: auto; background: #e6e6d9; line-height: 1.6; }
.prose pre code { padding: 0; background: none; overflow-wrap: normal; }
.prose hr { margin-block: 2.5rem; border: 0; border-top: 1px solid var(--rule); }
.prose table { display: block; overflow-x: auto; max-width: 100%; border-collapse: collapse; font-size: .9375rem; }
.prose th, .prose td { padding: .6rem .75rem; border-bottom: 1px solid var(--rule); text-align: left; }
.prose figcaption { margin-top: .5rem; font-size: .875rem; color: var(--paper-muted); }
.related { margin-top: 3rem; padding-top: 2rem; border-top: 1px solid var(--rule); }
.related h2 { color: var(--paper-muted); }
.related ul { margin-top: 1rem; padding: 0; list-style: none; }
.related li + li { margin-top: .75rem; }
.site-footer { background: var(--green-deep); color: var(--muted); padding-block: 1.7rem; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem 2rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: .5rem 1.5rem; list-style: none; padding: 0; font-size: .8125rem; }
.footer-links a { display: inline-block; padding-block: .5rem; }
.site-footer p { font: .8125rem/1.6 var(--mono); }
.site-footer span { margin-inline: .45rem; color: var(--amber); }
@media (min-width: 100rem) { .hero { padding-block: 3rem 6rem; } }
@media (max-width: 60rem) {
  .hero-layout { grid-template-columns: minmax(0, .85fr) minmax(0, 1.15fr); gap: 2rem; }
  .hero-name { font-size: clamp(3rem, 6.4vw, 4rem); }
  .section-grid { grid-template-columns: 10rem minmax(0, 1fr); gap: 2rem; }
}
@media (max-width: 45rem) {
  .page::before { background-image: image-set(url("/assets/images/studio-768.webp") type("image/webp"), url("/assets/images/studio.png") type("image/png")); }
  .site-header-inner { padding-block: .8rem; }
  .nav-list { gap: 1.5rem; }
  .hero { padding-block: 1.75rem 2.5rem; }
  .hero-layout { grid-template-columns: minmax(0, 1fr); gap: 2.5rem; }
  .hero-copy { padding: 0; }
  .hero-eyebrow { margin-bottom: 1.25rem; }
  .hero-name { max-width: 12ch; font-size: clamp(3.25rem, 11vw, 4.75rem); }
  .hero-statement { max-width: 36ch; margin-top: 1.5rem; font-size: 1.125rem; }
  .hero-copy::after { display: none; }
  .studio-art img { aspect-ratio: 1.5; }
  .section { padding-block: 2.5rem; }
  .section-grid { grid-template-columns: minmax(0, 1fr); gap: 1.75rem; }
  .section + .section .section-grid { padding-top: 2.5rem; }
  .section-label { display: flex; align-items: center; gap: .75rem; }
  .section-label::before { margin: 0; }
  .page-wrap { padding-top: 2.5rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media print {
  :root { color-scheme: light; }
  body, .site-header, .site-footer, .section { background: white; color: black; }
  .hero-statement, .nav-list a, .site-footer { color: #333; }
  .page::before, .studio-art, .skip-link, .preview-notice { display: none; }
  .hero-layout { display: block; }
  .site-mark { filter: brightness(0); }
  .hero-name { max-width: none; }
  .page-wrap { max-width: none; }
  .prose { font-size: 11pt; }
  .entry, h2, h3 { break-inside: avoid; }
}
