/* ==========================================================================
   Journal — "What's Happening in Riverchase"
   Extends site.css. Every colour and face below is an existing token; this
   file adds no new palette, only the reading layout the dashboard lacks.
   ========================================================================== */

.jbody {
  background: var(--cream);
  color: var(--ink);
}

/* The dashboard's fixed green panel is a dashboard device. A long read wants
   the full measure, so journal pages use a horizontal bar instead. */
.jtop {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.5rem;
  flex-wrap: wrap;
  background: var(--forest);
  color: var(--cream);
  padding: 1rem clamp(1.1rem, 4vw, 2.75rem);
}

.jtop__brand {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  color: var(--cream);
  text-decoration: none;
}

.jtop__brand .mark {
  width: 48px;
  height: 48px;
  flex: none;
}

.jtop__txt {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.jtop__txt .wordmark {
  font-size: 1.32rem;
  color: var(--cream);
}

.jtop__sub {
  font-size: 0.72rem;
  letter-spacing: 0.11em;
  text-transform: uppercase;
  color: var(--sage);
  margin-top: 0.22rem;
}

.jtop__nav {
  display: flex;
  gap: 1.4rem;
  font-size: 0.83rem;
  letter-spacing: 0.055em;
  text-transform: uppercase;
}

.jtop__nav a {
  color: var(--cream);
  text-decoration: none;
  padding-bottom: 0.18rem;
  border-bottom: 1.5px solid transparent;
}

.jtop__nav a:hover,
.jtop__nav a:focus-visible {
  border-bottom-color: var(--sage);
}

.jmain {
  max-width: 78rem;
  margin: 0 auto;
  padding: clamp(2rem, 5vw, 3.75rem) clamp(1.1rem, 4vw, 2.75rem) 4rem;
}

/* ---------- Draft banner ---------- */

.jdraft {
  background: var(--brass);
  color: #fff;
  padding: 0.8rem clamp(1.1rem, 4vw, 2.75rem);
  font-size: 0.9rem;
  line-height: 1.5;
}

.jdraft strong { letter-spacing: 0.02em; }

/* ---------- Index hero ---------- */

.jhero {
  max-width: 44rem;
  margin-bottom: clamp(2.25rem, 5vw, 3.5rem);
}

.jhero h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 72, 'SOFT' 0, 'WONK' 0;
  font-size: clamp(2.1rem, 6vw, 3.4rem);
  line-height: 1.04;
  letter-spacing: -0.02em;
  margin: 0.5rem 0 1rem;
}

.jhero__dek {
  font-size: 1.08rem;
  line-height: 1.65;
  color: var(--muted);
  margin: 0 0 1.1rem;
  max-width: 38rem;
}

.jhero__sub {
  font-size: 0.85rem;
  color: var(--muted);
  margin: 0;
}

.jempty,
.jnone {
  color: var(--muted);
  font-size: 1rem;
  padding: 2rem 0;
}

/* ---------- Category chips ---------- */

.chip {
  display: inline-block;
  font-size: 0.66rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.26rem 0.6rem;
  border-radius: 2px;
  background: var(--offset);
  color: var(--forest);
  white-space: nowrap;
}

.chip--development { background: var(--forest); color: var(--cream); }
.chip--market      { background: var(--sage);   color: var(--forest-deep); }
.chip--business    { background: var(--brass);  color: #fff; }
.chip--community   { background: var(--offset); color: var(--forest-deep); }
.chip--waterways   { background: #2f4f57;       color: #e4f0f2; }

/* ---------- Filter ---------- */

.jfilter {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-bottom: 1.75rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--divider);
}

.jchip {
  font: inherit;
  font-size: 0.79rem;
  letter-spacing: 0.04em;
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.jchip:hover { border-color: var(--forest); color: var(--forest); }

.jchip.is-on {
  background: var(--forest);
  border-color: var(--forest);
  color: var(--cream);
}

/* ---------- Post list ---------- */

.jlist {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 2.25rem;
  grid-template-columns: repeat(auto-fill, minmax(19rem, 1fr));
}

.jcard {
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: 3px;
  overflow: hidden;
  transition: border-color 0.18s, transform 0.18s;
}

.jcard:hover {
  border-color: var(--border);
  transform: translateY(-2px);
}

.jcard[hidden] { display: none; }

/* The newest post takes the full row and shows its hero. */
.jcard--lead {
  grid-column: 1 / -1;
  flex-direction: row;
  align-items: stretch;
}

.jcard__img {
  flex: 0 0 46%;
  display: block;
  overflow: hidden;
  background: var(--offset);
}

.jcard__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.jcard__body {
  padding: clamp(1.3rem, 3vw, 2.1rem);
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  flex: 1;
}

.jcard__meta,
.jteaser__meta,
.post__meta {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
  margin: 0;
  font-size: 0.79rem;
  color: var(--muted);
}

.jcard__title {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 48, 'SOFT' 0, 'WONK' 0;
  font-size: 1.42rem;
  line-height: 1.16;
  letter-spacing: -0.014em;
  margin: 0;
}

.jcard--lead .jcard__title { font-size: clamp(1.6rem, 3.2vw, 2.2rem); }

.jcard__title a {
  color: var(--ink);
  text-decoration: none;
}

.jcard__title a:hover,
.jcard__title a:focus-visible { color: var(--forest); }

.jcard__dek {
  margin: 0;
  color: var(--muted);
  line-height: 1.6;
  font-size: 0.95rem;
}

.jcard__more {
  margin: auto 0 0;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--forest);
  display: flex;
  gap: 0.6rem;
  align-items: baseline;
  padding-top: 0.5rem;
}

.jcard__read { color: var(--muted); letter-spacing: 0.04em; text-transform: none; }

/* ---------- Article ---------- */

.post {
  max-width: 43rem;
  margin: 0 auto;
}

.post__crumbs {
  font-size: 0.78rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 1.6rem;
}

.post__crumbs a { color: var(--muted); text-decoration: none; }
.post__crumbs a:hover { color: var(--forest); }
.post__crumbs span { margin: 0 0.45rem; }

.post__head h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 72, 'SOFT' 0, 'WONK' 0;
  font-size: clamp(2rem, 5.4vw, 3.05rem);
  line-height: 1.06;
  letter-spacing: -0.021em;
  margin: 0.85rem 0 1rem;
  text-wrap: balance;
}

.post__dek {
  font-size: 1.14rem;
  line-height: 1.62;
  color: var(--muted);
  margin: 0;
}

.post__upd {
  font-size: 0.8rem;
  color: var(--muted);
  margin: 0.9rem 0 0;
  font-style: italic;
}

.post__read { letter-spacing: 0.04em; }

.post__hero {
  margin: clamp(1.75rem, 4vw, 2.5rem) 0;
}

.post__hero img {
  width: 100%;
  display: block;
  border-radius: 3px;
}

.post__hero figcaption {
  font-size: 0.76rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 0.65rem;
}

.post__body {
  font-size: 1.06rem;
  line-height: 1.72;
  margin-top: clamp(1.6rem, 4vw, 2.25rem);
}

.post__body > *:first-child { margin-top: 0; }

.post__body p { margin: 0 0 1.35rem; }

.post__body h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 48, 'SOFT' 0, 'WONK' 0;
  font-size: 1.72rem;
  line-height: 1.2;
  letter-spacing: -0.014em;
  margin: 2.6rem 0 0.9rem;
}

.post__body h3 {
  font-family: var(--sans);
  font-weight: 600;
  font-size: 1.08rem;
  letter-spacing: 0.005em;
  margin: 2rem 0 0.7rem;
}

.post__body a {
  color: var(--forest);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

.post__body a:hover { color: var(--brass); }

.post__body ul,
.post__body ol { margin: 0 0 1.35rem; padding-left: 1.35rem; }
.post__body li { margin-bottom: 0.5rem; }

.post__body blockquote {
  margin: 1.9rem 0;
  padding: 0.2rem 0 0.2rem 1.35rem;
  border-left: 3px solid var(--sage);
  color: var(--muted);
  font-style: italic;
}

.post__body blockquote p:last-child { margin-bottom: 0; }

.post__body hr {
  border: 0;
  border-top: 1px solid var(--divider);
  margin: 2.5rem 0;
}

.post__body strong { font-weight: 600; }

.post__body table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.8rem 0;
  font-size: 0.93rem;
}

.post__body th,
.post__body td {
  text-align: left;
  padding: 0.6rem 0.7rem;
  border-bottom: 1px solid var(--divider);
}

.post__body th {
  font-size: 0.72rem;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: var(--muted);
  font-weight: 600;
}

/* Sources block at the foot of a post. */
.post__body .sources {
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: 3px;
  padding: 1.25rem 1.4rem;
  font-size: 0.88rem;
  margin-top: 2.5rem;
}

.post__body .sources p { margin-bottom: 0.6rem; }
.post__body .sources ul { margin-bottom: 0; }
.post__body .sources li { margin-bottom: 0.4rem; }

/* ---------- Article CTA ---------- */

.post__cta {
  margin: clamp(2.5rem, 6vw, 3.5rem) 0 0;
  padding: clamp(1.5rem, 4vw, 2.25rem);
  background: var(--forest);
  color: var(--cream);
  border-radius: 3px;
}

.post__cta h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 48, 'SOFT' 0, 'WONK' 0;
  font-size: 1.5rem;
  line-height: 1.2;
  margin: 0 0 0.7rem;
  color: var(--cream);
}

.post__cta p { margin: 0 0 1rem; line-height: 1.62; color: #e7e9df; }

.post__ctarow {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin: 1.25rem 0 0;
}

/* .btn--outline is defined for light backgrounds; inside the forest CTA it
   needs cream borders to stay legible. */
.post__cta .btn--solid {
  background: var(--cream);
  color: var(--forest-deep);
  border-color: var(--cream);
}

.post__cta .btn--solid:hover { background: #fff; border-color: #fff; }

.post__cta .btn--outline {
  border-color: rgba(245, 241, 231, 0.5);
  color: var(--cream);
  background: transparent;
}

.post__cta .btn--outline:hover {
  border-color: var(--cream);
  background: rgba(245, 241, 231, 0.1);
  color: var(--cream);
}

/* ---------- Pager ---------- */

.post__pager {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  margin-top: 2.5rem;
  padding-top: 1.75rem;
  border-top: 1px solid var(--divider);
}

.post__pagerlink {
  flex: 1 1 14rem;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.06rem;
  line-height: 1.3;
}

.post__pagerlink span {
  display: block;
  font-family: var(--sans);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.post__pagerlink--next { text-align: right; }
.post__pagerlink:hover { color: var(--forest); }

/* ==========================================================================
   Homepage teaser (lives inside index.html's own shell)
   ========================================================================== */

.jteaser__list {
  list-style: none;
  margin: 1.75rem 0 0;
  padding: 0;
  display: grid;
  gap: 1.5rem;
  grid-template-columns: repeat(auto-fit, minmax(15.5rem, 1fr));
}

.jteaser__item {
  background: var(--surface);
  border: 1px solid var(--divider);
  border-radius: 3px;
  padding: 1.35rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.55rem;
}

.jteaser__title {
  font-family: var(--serif);
  font-weight: 500;
  font-variation-settings: 'opsz' 48, 'SOFT' 0, 'WONK' 0;
  font-size: 1.2rem;
  line-height: 1.2;
  letter-spacing: -0.012em;
  margin: 0;
}

.jteaser__title a { color: var(--ink); text-decoration: none; }
.jteaser__title a:hover { color: var(--forest); }

.jteaser__dek {
  margin: 0;
  font-size: 0.92rem;
  line-height: 1.58;
  color: var(--muted);
}

.journal__all {
  margin: 1.9rem 0 0;
}

/* ==========================================================================
   Mobile
   ========================================================================== */

@media (max-width: 760px) {
  .jcard--lead {
    flex-direction: column;
  }

  .jcard--lead .jcard__img {
    flex: none;
    aspect-ratio: 16 / 10;
  }

  .jtop {
    padding: 0.85rem 1.1rem;
  }

  .jtop__brand .mark { width: 40px; height: 40px; }
  .jtop__txt .wordmark { font-size: 1.12rem; }

  .jtop__nav { font-size: 0.76rem; gap: 1rem; }

  .post__pagerlink--next { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  .jcard { transition: none; }
  .jcard:hover { transform: none; }
}

@media print {
  .jtop__nav,
  .post__cta,
  .post__pager,
  .jfilter,
  .jdraft { display: none; }

  .post { max-width: none; }
}
