/* jereklovey.com — shared system
   rooted · clear · warm */

:root {
  --field: #F2EFE7;
  --field-deep: #EAE6DA;
  --ink: #211E18;
  --ink-soft: #4D4639;
  --meta: #8B8472;
  --hairline: #D9D3C4;
  --accent: #57684F;   /* juniper sage — central oregon */
  --accent2: #8A9181;  /* light sage — decorative */
  --juniper: #3E4937;  /* deep juniper — inverted bands */
  --cream-on: #EFEDE3; /* text on juniper */
  --serif: 'Spectral', Georgia, 'Times New Roman', serif;
  --mono: Menlo, 'IBM Plex Mono', 'SFMono-Regular', monospace;
  --script: 'Homemade Apple', cursive;
  --measure: 36rem;
  --max: 71rem;
  --pad: clamp(1.25rem, 4vw, 3rem);
}

* { box-sizing: border-box; }

html { font-size: 100%; }

body {
  margin: 0;
  background: var(--field);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 1.125rem;
  line-height: 1.65;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

::selection { background: var(--accent); color: var(--field); }

a { color: inherit; text-decoration-color: var(--hairline); text-underline-offset: 0.2em; transition: color .25s ease, text-decoration-color .25s ease; }
a:hover { color: var(--accent); text-decoration-color: var(--accent); }

img { max-width: 100%; height: auto; display: block; }

p { margin: 0 0 1.1em 0; text-wrap: pretty; }
p:last-child { margin-bottom: 0; }

.wrap { max-width: var(--max); margin: 0 auto; padding-left: var(--pad); padding-right: var(--pad); }

/* ---------- nav ---------- */
.site-nav {
  display: flex; align-items: baseline; justify-content: space-between; gap: 1rem 2rem; flex-wrap: wrap;
  max-width: var(--max); margin: 0 auto;
  padding: 1.6rem var(--pad) 1.5rem;
  border-bottom: 1px solid var(--hairline);
}
.wordmark {
  font-family: var(--serif); font-size: 1.15rem; letter-spacing: .01em;
  text-decoration: none; color: var(--ink);
}
.wordmark:hover { color: var(--ink); }
.site-nav nav { display: flex; gap: clamp(.9rem, 2.5vw, 1.8rem); flex-wrap: wrap; }
.site-nav nav a {
  font-family: var(--mono); font-size: .66rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--meta); text-decoration: none; padding-bottom: .2rem; border-bottom: 1px solid transparent;
}
.site-nav nav a:hover { color: var(--ink); }
.site-nav nav a[aria-current="page"] { color: var(--ink); border-bottom-color: var(--accent); }

/* ---------- type ---------- */
.eyebrow {
  font-family: var(--mono); font-size: .66rem; font-weight: 500;
  letter-spacing: .35em; text-transform: uppercase; color: var(--meta);
  margin: 0 0 1.6rem 0;
}
.eyebrow .n { color: var(--accent2); }

h1, h2, h3 { font-weight: 400; letter-spacing: -0.015em; margin: 0; text-wrap: balance; }

.display {
  font-size: clamp(2.3rem, 5.4vw, 4.1rem);
  line-height: 1.12;
  font-weight: 300;
  letter-spacing: -0.02em;
}
.display em, .title em { font-style: italic; font-weight: 300; }
.display em { color: var(--accent); }

.title {
  font-size: clamp(1.7rem, 3.4vw, 2.5rem);
  line-height: 1.2;
  font-weight: 300;
  letter-spacing: -0.015em;
  margin-bottom: 2.4rem;
}
.title em { font-style: italic; }

.lede { font-size: clamp(1.2rem, 2vw, 1.4rem); line-height: 1.5; font-weight: 400; }

.measure { max-width: var(--measure); }

.meta-line { font-family: var(--mono); font-size: .66rem; letter-spacing: .18em; text-transform: uppercase; color: var(--meta); }

/* ---------- sections ---------- */
section.band { padding: clamp(4rem, 9vw, 7.5rem) 0; border-top: 1px solid var(--hairline); }
section.band:first-of-type { border-top: 0; }
section.band.deep { background: var(--field-deep); }

/* inverted juniper band — one per page, max */
section.band.juniper { background: var(--juniper); color: var(--cream-on); border-top: 1px solid var(--juniper); }
.band.juniper + .band { border-top: 0; }
.band.juniper .eyebrow { color: rgba(239, 237, 227, .55); }
.band.juniper .eyebrow .n { color: var(--accent2); }
.band.juniper .title em { color: var(--accent2); }
.band.juniper .prose { color: var(--cream-on); }
.band.juniper .prose h3 { color: var(--cream-on); }
.band.juniper a { color: var(--cream-on); text-decoration-color: rgba(239, 237, 227, .4); }
.band.juniper a:hover { color: var(--accent2); text-decoration-color: var(--accent2); }
.band.juniper .meta-line, .band.juniper .caption { color: rgba(239, 237, 227, .55); }
.band.juniper .pullquote { border-left-color: rgba(239, 237, 227, .45); }
.band.juniper .rows { border-top-color: rgba(239, 237, 227, .22); }
.band.juniper .row { border-bottom-color: rgba(239, 237, 227, .22); }
.band.juniper .row:hover { background: rgba(239, 237, 227, .05); }
.band.juniper .row .desc { color: rgba(239, 237, 227, .75); }
.band.juniper .row .go { color: rgba(239, 237, 227, .55); }
.band.juniper .row .go:hover { color: var(--accent2); }
.band.juniper .signature { color: rgba(239, 237, 227, .85); }
.band.juniper ::selection { background: var(--accent2); color: var(--juniper); }

/* ---------- hero ---------- */
.hero { padding: clamp(3.5rem, 8vw, 7rem) 0 clamp(3.5rem, 8vw, 6.5rem); }
.hero-sub { margin-top: 1.7rem; color: var(--ink-soft); max-width: 40ch; }
.section-lede { color: var(--ink-soft); max-width: 44ch; margin-top: -1rem; margin-bottom: 2.8rem; font-size: clamp(1.15rem, 1.9vw, 1.32rem); line-height: 1.5; }
.band.juniper .section-lede { color: rgba(239, 237, 227, .8); }
.hero-grid {
  display: grid; grid-template-columns: 1.05fr .9fr;
  gap: clamp(2rem, 5vw, 4.5rem); align-items: center;
}
@media (max-width: 760px) { .hero-grid { grid-template-columns: 1fr; } }

/* offset editorial frame for feature imagery */
.offset-frame { position: relative; }
.offset-frame::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  border: 1px solid var(--accent2);
  transform: translate(16px, 16px);
}

/* ---------- registration corners ---------- */
[data-corners] { position: relative; }
[data-corners] .reg {
  position: absolute; width: 13px; height: 13px; pointer-events: none; color: var(--meta);
}
[data-corners] .reg::before, [data-corners] .reg::after { content: ""; position: absolute; background: currentColor; }
[data-corners] .reg::before { left: 6px; top: 0; width: 1px; height: 13px; }
[data-corners] .reg::after { left: 0; top: 6px; width: 13px; height: 1px; }
.reg.tl { top: -7px; left: -7px; }
.reg.tr { top: -7px; right: -7px; }
.reg.bl { bottom: -7px; left: -7px; }
.reg.br { bottom: -7px; right: -7px; }

/* ---------- list rows (vehicles / work / press) ---------- */
.rows { border-top: 1px solid var(--hairline); margin: 0; padding: 0; list-style: none; }
.row {
  display: grid; grid-template-columns: minmax(9rem, 14rem) 1fr auto;
  gap: 1rem 2rem; align-items: baseline;
  padding: 1.6rem 1rem; margin: 0 -1rem;
  border-bottom: 1px solid var(--hairline);
  transition: background .35s ease;
}
.row:hover { background: rgba(87, 104, 79, .06); }
.row:hover .name { color: var(--accent); }
.row .name { transition: color .3s ease; }
@media (max-width: 640px) { .row { grid-template-columns: 1fr; gap: .35rem; padding: 1.3rem 0; } }
.row .name { font-size: 1.3rem; font-weight: 400; letter-spacing: -.01em; }
.row .desc { color: var(--ink-soft); font-size: 1.02rem; max-width: 34rem; }
.row .go {
  font-family: var(--mono); font-size: .66rem; letter-spacing: .18em; text-transform: uppercase;
  color: var(--meta); text-decoration: none; white-space: nowrap;
}
.row .go:hover { color: var(--accent); }
.row .go.soon { color: var(--hairline); cursor: default; }
.row .go.tag-soft { color: var(--accent2); }

/* offering blocks — the work page */
.offer { padding: clamp(2.6rem, 5vw, 4rem) 0; border-bottom: 1px solid var(--hairline); display: grid; grid-template-columns: minmax(0, 7rem) 1fr; gap: 1rem 2.5rem; }
.offer:last-child { border-bottom: 0; }
@media (max-width: 680px) { .offer { grid-template-columns: 1fr; gap: 1rem; } }
.offer .o-num { font-family: var(--mono); font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--accent2); padding-top: .55rem; }
.offer .o-name { font-size: clamp(1.5rem, 2.6vw, 1.95rem); font-weight: 300; letter-spacing: -.015em; line-height: 1.15; margin-bottom: 1.1rem; }
.offer .o-name em { font-style: italic; }
.offer .o-body { max-width: 40rem; color: var(--ink-soft); }
.offer .o-body p { color: var(--ink-soft); }
.offer .o-meta { font-family: var(--mono); font-size: .64rem; letter-spacing: .16em; text-transform: uppercase; color: var(--meta); margin-top: 1.4rem; display: flex; flex-wrap: wrap; gap: .5rem 1.4rem; }
.offer .o-meta a { color: var(--accent); text-decoration: none; }
.offer .o-meta a:hover { color: var(--ink); }

.row.has-logo { grid-template-columns: 44px minmax(8rem, 13rem) 1fr auto; align-items: center; }
.logo-spacer { width: 44px; height: 44px; }
@media (max-width: 640px) {
  .row.has-logo { grid-template-columns: 44px 1fr; align-items: start; }
  .row.has-logo .desc, .row.has-logo .go { grid-column: 2; }
  .row.has-logo .logo-spacer { display: none; }
  .row.has-logo .name { grid-column: 2; }
}

/* ---------- proof strip ---------- */
.proof {
  display: flex; flex-wrap: wrap; gap: .8rem 2.4rem; align-items: baseline;
  font-family: var(--mono); font-size: .64rem; letter-spacing: .24em; text-transform: uppercase;
  color: var(--meta); opacity: .85;
}

/* ---------- pull quote ---------- */
.pullquote {
  border-left: 1px solid var(--accent2);
  padding-left: clamp(1.4rem, 3vw, 2.4rem);
  margin: 3rem 0;
}
.pullquote .q { font-size: clamp(1.35rem, 2.6vw, 1.8rem); line-height: 1.35; font-style: italic; font-weight: 300; }
.pullquote .who { margin-top: 1.1rem; }

/* ---------- footer ---------- */
footer.site-footer { border-top: 1px solid var(--hairline); padding: clamp(3.5rem, 7vw, 5.5rem) 0 2.5rem; }
.footer-cta { font-size: clamp(1.5rem, 3.2vw, 2.3rem); font-weight: 300; line-height: 1.25; max-width: 30ch; }
.footer-cta a { text-decoration-color: var(--accent); font-style: italic; }
.footer-meta {
  display: flex; flex-wrap: wrap; gap: 1rem 2.2rem; align-items: center;
  margin-top: 3rem;
  font-family: var(--mono); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--meta);
}
.footer-meta a { text-decoration: none; color: var(--meta); }
.footer-meta a:hover { color: var(--accent); }
.footer-meta .mark { margin-right: auto; display: flex; align-items: baseline; gap: 1rem; }
.sig-mark { font-family: var(--script); font-size: 1.15rem; letter-spacing: 0; text-transform: none; color: var(--ink-soft); }

/* ---------- reveal motion ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal-on [data-reveal] { opacity: 0; transform: translateY(14px); transition: opacity .9s ease, transform .9s ease; }
  .reveal-on [data-reveal].in { opacity: 1; transform: none; }
}

/* ---------- page-specific helpers ---------- */
.prose { max-width: var(--measure); }
.prose h3 { font-size: 1.45rem; font-weight: 400; margin: 2.6rem 0 .9rem; }
.prose h3 em { font-style: italic; }

.signature { font-family: var(--script); font-size: 1.9rem; color: var(--ink-soft); transform: rotate(-2deg); display: inline-block; margin-top: 1.4rem; }

/* ---------- essay reading layout ---------- */
.reading { max-width: 40rem; margin: 0 auto; padding: clamp(2.6rem, 6vw, 4.5rem) var(--pad) clamp(3.5rem, 7vw, 5.5rem); }
.back-link { font-family: var(--mono); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--meta); text-decoration: none; display: inline-block; margin-bottom: 3rem; }
.back-link:hover { color: var(--accent); }
.back-link .arr { display: inline-block; transition: transform .25s ease; }
.back-link:hover .arr { transform: translateX(-4px); }
.article-head { margin-bottom: clamp(2.4rem, 5vw, 3.4rem); }
.article-meta { font-family: var(--mono); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--meta); margin: 0 0 1.4rem; display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; }
.article-title { font-size: clamp(2rem, 4.6vw, 3.1rem); font-weight: 300; line-height: 1.12; letter-spacing: -0.02em; }
.article-title em { font-style: italic; color: var(--accent); }
.article-body { font-size: 1.2rem; line-height: 1.72; color: var(--ink); }
.article-body p { margin: 0 0 1.35em; }
.article-body p.lead { font-size: 1.42rem; line-height: 1.5; color: var(--ink); font-weight: 380; margin-bottom: 1.5em; }
.article-body .break { text-align: center; color: var(--accent2); margin: 2.4em 0; font-size: 1rem; letter-spacing: .5em; }
.article-body em { font-style: italic; }
.article-body h2 { font-size: 1.5rem; font-weight: 400; letter-spacing: -.01em; margin: 2.4em 0 .7em; }
.article-body h2 em { font-style: italic; color: var(--accent); }
.article-body blockquote { margin: 1.8em 0; padding-left: 1.4rem; border-left: 1px solid var(--accent2); font-style: italic; font-size: 1.3rem; line-height: 1.4; color: var(--ink-soft); }
.article-foot { margin-top: clamp(3rem, 6vw, 4rem); padding-top: 2rem; border-top: 1px solid var(--hairline); }
.article-foot .sig-line { font-family: var(--script); font-size: 1.7rem; color: var(--ink-soft); transform: rotate(-2deg); display: inline-block; }
.article-foot .more { font-family: var(--mono); font-size: .64rem; letter-spacing: .2em; text-transform: uppercase; color: var(--meta); margin-top: 2.2rem; }
.article-foot .more a { color: var(--meta); text-decoration: none; }
.article-foot .more a:hover { color: var(--accent); }

.two-col { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: start; }
@media (max-width: 760px) { .two-col { grid-template-columns: 1fr; } }

.caption { font-family: var(--mono); font-size: .62rem; letter-spacing: .18em; text-transform: uppercase; color: var(--meta); margin-top: .9rem; }

/* essays */
.essay { display: grid; grid-template-columns: 7.5rem 1fr; gap: 1rem 2.5rem; padding: 2rem 0; border-bottom: 1px solid var(--hairline); align-items: baseline; }
@media (max-width: 640px) { .essay { grid-template-columns: 1fr; gap: .3rem; } }
.essay .date { font-family: var(--mono); font-size: .64rem; letter-spacing: .18em; text-transform: uppercase; color: var(--meta); }
.essay .e-title { font-size: 1.45rem; font-weight: 400; line-height: 1.25; }
.essay .e-title em { font-style: italic; }
.essay .summary { color: var(--ink-soft); font-size: 1.02rem; margin-top: .45rem; max-width: 36rem; }
a.essay { text-decoration: none; color: inherit; }
a.essay .e-title { transition: color .25s ease; }
a.essay:hover { background: rgba(87, 104, 79, .05); }
a.essay:hover .e-title { color: var(--accent); }
a.essay { padding-left: 1rem; padding-right: 1rem; margin-left: -1rem; margin-right: -1rem; transition: background .3s ease; }
.essay .tag { font-family: var(--mono); font-size: .58rem; letter-spacing: .18em; text-transform: uppercase; color: var(--accent2); border: 1px solid var(--hairline); border-radius: 2px; padding: .2rem .5rem; margin-left: .8rem; white-space: nowrap; vertical-align: middle; }
