/* ==========================================================
   Geoff Kottmeier: site styles
   Light theme is the default. Dark theme applies when
   <html data-theme="dark"> is set (by theme.js) or, with JS
   off, when the system prefers dark.
   ========================================================== */

:root {
  --bg: #fbf7f2;
  --surface: #ffffff;
  --surface-2: #f4ebe0;
  --text: #2b2724;
  --muted: #6b625a;
  --border: #e7dccf;
  --accent: #e2711d;        /* fills, borders */
  --accent-ink: #b0540c;    /* orange text on light ground */
  --accent-bright: #f7931e;
  --amber: #fdb94a;
  --charcoal: #4a4a4a;
  --on-accent: #1a1714;     /* dark text on orange buttons (white was too low contrast) */
  --band-bg: #2f2b28;       /* the question band */
  --band-text: #f6efe7;
  --shadow: 0 1px 2px rgba(43, 39, 36, .06), 0 8px 24px rgba(43, 39, 36, .08);

  --font-display: "Montserrat", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --font-body: "Source Serif 4", ui-serif, Georgia, "Times New Roman", serif;

  --radius: 14px;
  --wrap: 1120px;
  --prose: 68ch;
  --gutter: clamp(1rem, 4vw, 2rem);
  --display-size: clamp(1.9rem, 3.4vw, 2.6rem); /* every large headline */
  --space-section: clamp(3rem, 6vw, 4.5rem);      /* vertical rhythm between sections */

  color-scheme: light;
}

:root[data-theme="dark"] {
  --bg: #161412;
  --surface: #201d1a;
  --surface-2: #2a2521;
  --text: #e6e0d8;  /* warm off-white: less glare than near-white */
  --muted: #b5aaa0;
  --border: #3a332d;
  --accent: #f7931e;
  --accent-ink: #ffa94d;
  --accent-bright: #ffa94d;
  --on-accent: #1a1714;
  --band-bg: #0f0d0c;
  --band-text: #f6efe7;
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
  color-scheme: dark;
}

/* No-JS fallback: follow the system setting */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    --bg: #161412;
    --surface: #201d1a;
    --surface-2: #2a2521;
    --text: #e6e0d8;  /* warm off-white: less glare than near-white */
    --muted: #b5aaa0;
    --border: #3a332d;
    --accent: #f7931e;
    --accent-ink: #ffa94d;
    --accent-bright: #ffa94d;
    --on-accent: #1a1714;
    --band-bg: #0f0d0c;
    --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 8px 24px rgba(0, 0, 0, .35);
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 5.5rem; }  /* anchor jumps clear the sticky header */
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.125rem;
  line-height: 1.65;
  transition: background-color .2s ease, color .2s ease;
}

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

a { color: var(--accent-ink); text-underline-offset: .18em; text-decoration-thickness: .08em; }
a:hover { color: var(--accent); }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -.01em;
  margin: 0 0 .6em;
}
h1 { font-size: var(--display-size); font-weight: 800; }
h2 { font-size: clamp(1.6rem, 3.4vw, 2.3rem); font-weight: 800; }
h3 { font-size: 1.25rem; font-weight: 700; }

p { margin: 0 0 1.1em; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gutter); }

.eyebrow {
  font-family: var(--font-display);
  font-size: .8rem;
  font-weight: 700;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: var(--accent-ink);
  margin: 0 0 .9rem;
}

.skip-link {
  position: absolute; left: -999px; top: .5rem;
  background: var(--accent); color: var(--on-accent);
  padding: .5rem 1rem; border-radius: 8px; z-index: 100;
}
.skip-link:focus { left: .5rem; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; gap: .5em;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: .95rem;
  padding: .75em 1.3em;
  border-radius: 999px;
  border: 2px solid var(--accent);
  background: var(--accent);
  color: var(--on-accent);
  text-decoration: none;
  cursor: pointer;
  transition: transform .15s ease, background-color .15s ease;
}
.btn:hover { color: var(--on-accent); background: var(--accent-bright); border-color: var(--accent-bright); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--accent-ink); }
.btn--ghost:hover { background: var(--accent); color: var(--on-accent); }
.btn--sm { font-size: .85rem; padding: .5em 1em; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1rem; min-height: 68px;
}

.brand {
  display: inline-flex; align-items: center; gap: .65rem;
  text-decoration: none; color: var(--text);
  font-family: var(--font-display); font-weight: 800; font-size: 1.05rem;
  letter-spacing: .02em; text-transform: uppercase;
}
.brand:hover { color: var(--text); }
.brand img { width: 40px; height: 40px; flex: none; }

.site-nav { display: flex; align-items: center; gap: .25rem; }
.site-nav a {
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  color: var(--text); text-decoration: none;
  padding: .45rem .75rem; border-radius: 999px;
}
.site-nav a:hover { background: var(--surface-2); color: var(--text); }
.site-nav a[aria-current="page"] { color: var(--accent-ink); }
.site-nav .btn { margin-left: .5rem; color: var(--on-accent); }
.site-nav .btn:hover { background: var(--accent-bright); }

.theme-toggle {
  display: inline-grid; place-items: center;
  width: 40px; height: 40px; margin-left: .25rem;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
}
.theme-toggle:hover { border-color: var(--accent); color: var(--accent-ink); }
.theme-toggle svg { width: 20px; height: 20px; }
.theme-toggle .icon-sun { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun { display: block; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: none; }

/* Theme-swapped images */
.only-dark { display: none !important; }
:root[data-theme="dark"] .only-dark { display: block !important; }
:root[data-theme="dark"] .only-light { display: none !important; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) .only-dark { display: block !important; }
  :root:not([data-theme]) .only-light { display: none !important; }
}

@media (max-width: 760px) {
  .brand span { display: none; }
  .site-nav .btn { padding: .45em .85em; margin-left: .25rem; }  /* keep the Join button on phones */
  .join-more { display: none; }  /* phones: just "Join" */
  .site-nav a { padding: .45rem .55rem; }
}
@media (max-width: 420px) {
  /* small phones: the logo already links home, so drop the Home text link to fit Subscribe */
  .site-nav a:first-child { display: none; }
  .brand { flex: none; }
  .site-nav { gap: .1rem; }
  .site-nav a { padding: .4rem .45rem; font-size: .9rem; }
  .site-nav .btn { padding: .4em .75em; }
  .brand img { width: 34px; height: 34px; }
}

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: clamp(1.25rem, 3vw, 2rem) calc(var(--space-section) + 1rem);
}
.hero::before {
  /* soft sun glow */
  content: ""; position: absolute; right: -8%; top: 50%; transform: translateY(-55%);
  width: 60vw; max-width: 760px; aspect-ratio: 1;
  background: radial-gradient(circle, color-mix(in srgb, var(--amber) 30%, transparent) 0%, transparent 62%);
  pointer-events: none;
}
.hero .wrap {
  position: relative;
  display: grid; gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: 2fr 1fr; align-items: center;
}
.hero h1 { margin-bottom: .45em; }
.hero h1 em { font-style: normal; color: var(--accent-ink); }
.hero .lede { font-size: 1.2rem; color: var(--muted); max-width: 52ch; text-wrap: pretty; }
.lede em {  /* the vision line: italic, with a dashed orange "trail" underline */
  font-style: italic; color: var(--text);
  text-decoration: underline dashed color-mix(in srgb, var(--accent) 75%, transparent);
  text-decoration-thickness: 1.5px; text-underline-offset: .32em; text-decoration-skip-ink: none;
}
.hero-photo { position: relative; justify-self: center; width: min(360px, 100%); margin-right: 1.1rem; }
.hero .hero-photo .photo-frame img { aspect-ratio: 4 / 5; }
/* the logo mark, large, overlapping the photo's lower-left corner */
.hero-badge { position: absolute; left: -3.25rem; bottom: -2.5rem; width: clamp(110px, 12vw, 150px); z-index: 2; }
.hero-badge img { width: 100%; filter: drop-shadow(0 12px 22px rgba(0, 0, 0, .3)); }

@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .hero-photo { display: none; }  /* phones: keep the signup near the top */
}

/* ---------- Signup ---------- */
.signup {
  margin-top: 1.6rem;
  padding: 1.25rem 1.25rem .75rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  max-width: 560px;
}
.signup-label {
  font-family: var(--font-display); font-weight: 700; font-size: .95rem;
  margin: 0 0 .25rem;
}
.signup-note { font-size: .95rem; color: var(--muted); margin: 0 0 .5rem; }

/* Short laptop windows: tighten the hero so the signup button stays above the fold */
@media (min-width: 861px) and (max-height: 760px) {
  .hero h1 { font-size: clamp(1.8rem, 2.9vw, 2.25rem); }
  .hero .lede { font-size: 1.1rem; margin-bottom: 0; }
  .signup--hero { margin-top: .9rem; padding-top: 1rem; }
}

/* Hero signup: compact Lighter Line header (matches the full box below), fields side by side */
.signup--hero { margin-top: 1.2rem; }
.signup-mini { display: flex; align-items: center; gap: .8rem; margin-bottom: .55rem; }
.signup-mini img { flex: none; width: 52px; height: auto; filter: drop-shadow(0 4px 8px rgba(0, 0, 0, .15)); }
.signup-mini p { margin: 0; }
.signup-mini .signup-name { font-size: 1.1rem; }
.signup-mini .signup-note { font-size: .9rem; margin-top: .1rem; }
@media (min-width: 561px) {
  .signup--hero .formkit-fields { display: grid !important; grid-template-columns: 1fr 1fr; gap: .6rem; }
  .signup--hero .formkit-field { margin: 0 !important; min-width: 0; }
  .signup--hero .formkit-submit { grid-column: 1 / -1; margin: 0 !important; }
}

/* Tame the Kit form so it follows the theme */
.formkit-form { max-width: 100% !important; background: transparent !important; }
.formkit-form [data-style="clean"] { padding: .5rem 0 0 !important; }
.formkit-form .formkit-input {
  background: var(--bg) !important;
  color: var(--text) !important;
  border-color: var(--border) !important;
  font-family: var(--font-display) !important;
}
.formkit-form .formkit-submit {
  background-color: var(--accent) !important;
  color: var(--on-accent) !important;
  border-radius: 999px !important;
  font-family: var(--font-display) !important;
  font-weight: 700 !important;
}
.formkit-form .formkit-guarantee,
.formkit-form .formkit-powered-by-convertkit-container { color: var(--muted) !important; }
.formkit-form .formkit-powered-by-convertkit { opacity: .6; }  /* visible, but quieter */
:root[data-theme="dark"] .formkit-form .formkit-powered-by-convertkit { filter: invert(1); opacity: .6; }

/* ---------- Section rhythm ---------- */
.section { padding-block: var(--space-section); }
.section-head { max-width: 46rem; margin-bottom: 2.5rem; }
.section-head p { color: var(--muted); }

/* ---------- The question band ---------- */
.question {
  position: relative;
  background:
    linear-gradient(color-mix(in srgb, var(--band-bg) 84%, transparent), color-mix(in srgb, var(--band-bg) 74%, transparent)),
    url("../img/forest-bw.jpg") center 55% / cover no-repeat,
    var(--band-bg);
  color: var(--band-text);
  padding-block: calc(var(--space-section) + 2rem) var(--space-section);  /* extra on top for the ridgeline */
}
.question::before {
  /* mountain ridge cut into the band's top edge */
  content: ""; position: absolute; left: 0; right: 0; top: -1px;
  height: clamp(40px, 6vw, 80px);
  background: var(--bg);
  clip-path: polygon(0 0, 100% 0, 100% 35%, 88% 70%, 80% 45%, 70% 85%, 58% 30%, 47% 75%, 38% 50%, 27% 92%, 16% 40%, 8% 70%, 0 45%);
}
.question .eyebrow { color: var(--amber); }
.question h2 {
  font-size: var(--display-size);
  max-width: 22ch;
  margin-bottom: 1.2em;
}
.question h2 .hl {
  background: linear-gradient(transparent 62%, color-mix(in srgb, var(--accent) 55%, transparent) 62%);
  padding-inline: .1em;
  -webkit-box-decoration-break: clone; box-decoration-break: clone;
}
.pillars {
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(3, 1fr);
}
.pillar {
  background: rgba(255, 255, 255, .05);
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: var(--radius);
  padding: 1.5rem 1.4rem;
}
.pillar .num {
  font-family: var(--font-display); font-weight: 800; font-size: .85rem;
  color: var(--amber); letter-spacing: .1em;
}
.pillar h3 { margin: .4rem 0 .5rem; color: #fff; }
.pillar p { margin: 0; color: #d9cfc5; font-size: 1.02rem; }
.question .kicker {
  margin: 2.5rem 0 0;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.1rem, 2.2vw, 1.35rem);
  color: var(--amber);
}
@media (max-width: 860px) { .pillars { grid-template-columns: 1fr; } }

/* ---------- Bio preview ---------- */
.bio-preview .wrap {
  display: grid; gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); align-items: center;
}
.photo-frame { position: relative; }
.photo-frame img {
  width: 100%; aspect-ratio: 1; object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.photo-frame::after {
  content: ""; position: absolute; z-index: -1;
  inset: 1.1rem -1.1rem -1.1rem 1.1rem;
  border: 3px solid var(--accent);
  border-radius: var(--radius);
}
.bio-preview .photo-frame { margin-right: 1.1rem; }
.chips { display: flex; flex-wrap: wrap; gap: .5rem; padding: 0; margin: 1.25rem 0 1.75rem; list-style: none; }
.chips li {
  font-family: var(--font-display); font-size: .8rem; font-weight: 600;
  padding: .35rem .8rem; border-radius: 999px;
  background: var(--surface-2); color: var(--text);
  border: 1px solid var(--border);
}
@media (max-width: 760px) {
  .bio-preview .wrap { grid-template-columns: 1fr; }
  .bio-preview .photo-frame { max-width: 320px; }
}

/* ---------- Photo breaks: full-width B&W landscapes between sections ---------- */
.photo-break { height: clamp(200px, 30vw, 420px); overflow: hidden; background: var(--band-bg); }
.photo-break img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* ---------- Welcome page (after confirming the newsletter) ---------- */
.page-welcome .site-nav .btn { display: none; }  /* already joined */
.welcome .wrap { display: grid; justify-items: center; text-align: center; max-width: 640px; }
.welcome-logo { width: 120px; margin-bottom: 1rem; filter: drop-shadow(0 10px 18px rgba(0, 0, 0, .18)); }
.welcome h1 { max-width: 20ch; text-wrap: balance; }
.welcome-lede { font-size: 1.2rem; color: var(--muted); margin: 0 0 1.75rem; }
.welcome-card {
  width: 100%; text-align: left;
  background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 1.4rem 1.5rem .6rem;
}
.welcome-card h2 { font-size: 1.15rem; margin: 0 0 .75rem; color: var(--accent-ink); }
.welcome-card ul { margin: 0; padding-left: 1.1rem; }
.welcome-card li { margin-bottom: .8rem; }
.welcome .social { margin-top: 1.75rem; }
@media (min-width: 800px) { .welcome .social { margin-inline: -5rem; } }
@media (min-width: 960px) { .welcome .social { margin-inline: -10rem; } }  /* all six on one row */
.welcome-sign { margin: 1.75rem 0 1.25rem; color: var(--muted); font-style: italic; }
.welcome-sign span { font-family: var(--font-display); font-style: normal; font-weight: 700; color: var(--text); }

/* ---------- Post cards ---------- */
.latest { background: var(--surface-2); }
.post-grid { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr)); }
.post-card {
  display: flex; flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem 1.4rem 1.2rem;
  text-decoration: none; color: var(--text);
  transition: transform .15s ease, border-color .15s ease, box-shadow .15s ease;
}
.post-card:hover { color: var(--text); transform: translateY(-2px); border-color: var(--accent); box-shadow: var(--shadow); }
.post-card h3 { margin-bottom: .45rem; }
.post-card p { color: var(--muted); font-size: 1rem; margin-bottom: 1rem; }
.post-card .more { margin-top: auto; font-family: var(--font-display); font-weight: 700; font-size: .9rem; color: var(--accent-ink); }
.post-meta { font-family: var(--font-display); font-size: .8rem; font-weight: 600; color: var(--muted); margin-bottom: .5rem; }
.tags { display: flex; flex-wrap: wrap; gap: .35rem; margin: 0 0 .9rem; padding: 0; list-style: none; }
.tags li { font-family: var(--font-display); font-size: .72rem; font-weight: 600; color: var(--accent-ink); background: color-mix(in srgb, var(--accent) 12%, transparent); padding: .15rem .55rem; border-radius: 999px; }
.empty-note { color: var(--muted); font-style: italic; }
.working-on { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.2rem 1.4rem; max-width: 34rem; }
.working-on h3 { margin: 0 0 .6rem; font-size: 1.1rem; }
.working-on ul { margin: 0; padding-left: 1.2rem; }
.working-on li { margin: .25rem 0; }
.working-on strong { font-family: var(--font-display); font-weight: 700; color: var(--accent-ink); }

/* ---------- Opt-in reminder ---------- */
.reminder .wrap { display: grid; justify-items: center; text-align: center; }
.reminder h2 { max-width: 28ch; text-wrap: balance; }
.reminder p { color: var(--muted); max-width: 52ch; }
.reminder .signup { width: 100%; text-align: left; }

.social { display: flex; flex-wrap: wrap; gap: .75rem; justify-content: center; margin-top: 2.25rem; padding: 0; list-style: none; }
.social a {
  display: inline-flex; align-items: center; gap: .55rem;
  font-family: var(--font-display); font-weight: 600; font-size: .95rem;
  padding: .6rem 1.1rem; border-radius: 999px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); text-decoration: none;
}
.social a:hover { border-color: var(--accent); color: var(--accent-ink); }
.social svg { width: 20px; height: 20px; fill: currentColor; }

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--border);
  padding-block: 2rem;
  font-family: var(--font-display); font-size: .88rem; color: var(--muted);
}
.site-footer .wrap { display: flex; flex-wrap: wrap; gap: 1rem; align-items: center; justify-content: space-between; }
.site-footer nav { display: flex; gap: 1.1rem; flex-wrap: wrap; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--accent-ink); }
.footer-social { display: flex; gap: .5rem; }
.footer-social a { display: inline-grid; place-items: center; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--border); }
.footer-social svg { width: 18px; height: 18px; fill: currentColor; }

/* ---------- About page ---------- */
.page-head { padding-block: clamp(2.5rem, 6vw, 4.5rem) 1rem; }
.about-intro .wrap {
  display: grid; gap: clamp(2rem, 5vw, 4rem);
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); align-items: center;
}
.about-intro .photo-frame { margin-right: 1.1rem; }
.about-intro .lede { font-size: 1.2rem; color: var(--muted); max-width: 52ch; margin: .8rem 0 0; text-wrap: pretty; }
.statement {
  margin: 0;
  font-family: var(--font-display); font-weight: 700;
  font-size: clamp(1.35rem, 2.8vw, 1.85rem); line-height: 1.3;
  border-left: 5px solid var(--accent);
  padding-left: 1.1rem;
}
@media (max-width: 760px) {
  .about-intro .wrap { grid-template-columns: 1fr; }
  .about-intro .photo-frame { max-width: 320px; order: -1; }
}

.prose { max-width: var(--prose); }
.prose h2 { font-size: clamp(1.35rem, 2.6vw, 1.7rem); margin-top: 2.2em; }
.prose h3 { margin-top: 1.8em; }
.prose blockquote {
  margin: 1.6em 0; padding: .2em 0 .2em 1.1em;
  border-left: 4px solid var(--accent); color: var(--muted); font-style: italic;
}
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.1em; }
.prose li { margin-bottom: .35em; }
.prose code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: .88em;
  background: var(--surface-2); border: 1px solid var(--border);
  padding: .1em .35em; border-radius: 6px;
}
.prose pre {
  overflow-x: auto; background: var(--surface-2); border: 1px solid var(--border);
  padding: 1rem 1.2rem; border-radius: 10px; font-size: .9rem; line-height: 1.5;
}
.prose pre code { background: none; border: 0; padding: 0; }
.prose img { border-radius: 10px; margin-block: 1.4em; }
.prose hr { border: 0; border-top: 1px solid var(--border); margin: 2.5em 0; }
.prose table { border-collapse: collapse; width: 100%; display: block; overflow-x: auto; margin-bottom: 1.2em; font-size: 1rem; }
.prose th, .prose td { border: 1px solid var(--border); padding: .5em .75em; text-align: left; }
.prose th { background: var(--surface-2); font-family: var(--font-display); font-size: .9rem; }
.where-they-meet {
  background: var(--surface-2); border-radius: var(--radius);
  padding: 1.5rem 1.6rem; margin: 2.2em 0; border: 1px solid var(--border);
}
.where-they-meet h2 { margin-top: 0; }
.where-they-meet p:last-child { margin-bottom: 0; }

/* ---------- Blog post ---------- */
.post-header { padding-block: clamp(2.5rem, 6vw, 4rem) 1.5rem; }
.post-header h1 { max-width: 24ch; }
.post-header .post-meta { font-size: .9rem; }
.post-updated { color: var(--accent-ink); }
.back-link { font-family: var(--font-display); font-weight: 600; font-size: .9rem; text-decoration: none; display: inline-block; margin-bottom: 1.4rem; }
.post-body { padding-bottom: 2rem; }
.post-nav {
  display: grid; gap: 1rem; grid-template-columns: 1fr 1fr;
  border-top: 1px solid var(--border); padding-top: 1.5rem; margin-top: 2.5rem;
  font-family: var(--font-display);
}
.post-nav a { text-decoration: none; font-weight: 700; }
.post-nav span { display: block; font-size: .78rem; font-weight: 600; color: var(--muted); text-transform: uppercase; letter-spacing: .1em; }
.post-nav .next { text-align: right; grid-column: 2; }
.post-end-signup { margin-top: 3rem; }
.post-end-signup .signup { max-width: none; }
@media (max-width: 560px) {
  .post-nav { grid-template-columns: 1fr; }
  .post-nav .next { grid-column: 1; text-align: left; }
}

/* ---------- Photo banner (blog index) ---------- */
.photo-banner {
  position: relative;
  color: #fff;
  background:
    linear-gradient(90deg, rgba(22, 18, 14, .82) 0%, rgba(22, 18, 14, .55) 55%, rgba(22, 18, 14, .2) 100%),
    url("../img/snow-trees.jpg") center 40% / cover no-repeat,
    var(--band-bg);
  padding-block: clamp(4rem, 10vw, 7.5rem);
}
.photo-banner .eyebrow { color: var(--amber); }
.photo-banner h1 { color: #fff; }
.photo-banner .lede { color: #efe6dc; max-width: 52ch; margin: 0; font-size: 1.2rem; }

/* ---------- Wide photo in prose (about) ---------- */
.wide-photo { margin: 2.4em 0; }
.wide-photo img { width: 100%; aspect-ratio: 3 / 2; object-fit: cover; border-radius: var(--radius); box-shadow: var(--shadow); }
.wide-photo figcaption { margin-top: .7rem; font-family: var(--font-display); font-size: .85rem; font-weight: 600; color: var(--muted); }

/* ---------- Post media ---------- */
.post-hero { max-width: 880px; margin: 0 0 2.2rem; }
.post-hero:empty { display: none; }
.post-cover, .post-figure, .video { margin: 0; }
.post-cover img, .post-figure img {
  width: 100%; border-radius: var(--radius); box-shadow: var(--shadow); margin: 0;
}
.post-cover figcaption, .post-figure figcaption, .video figcaption {
  margin-top: .65rem; font-family: var(--font-display); font-size: .85rem; font-weight: 600; color: var(--muted);
}
.prose .post-figure, .prose .video { margin: 2em 0; }
/* Tall photos: crop covers to a sensible height, show inline photos whole. */
.post-cover img { max-height: min(75vh, 640px); object-fit: cover; }
.post-figure img { width: auto; max-width: 100%; max-height: 80vh; margin-inline: auto; }

.video .yt, .video iframe {
  position: relative; display: block; width: 100%; aspect-ratio: 16 / 9;
  border: 0; border-radius: var(--radius); overflow: hidden;
  background: #000; box-shadow: var(--shadow);
}
.video .yt img { width: 100%; height: 100%; object-fit: cover; margin: 0; border-radius: 0; transition: transform .3s ease, opacity .2s ease; }
.video .yt:hover img { transform: scale(1.02); opacity: .9; }
.yt-play {
  position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%);
  width: 76px; filter: drop-shadow(0 4px 12px rgba(0, 0, 0, .35)); transition: transform .15s ease;
}
.yt-play svg { display: block; width: 100%; height: auto; }
.video .yt:hover .yt-play { transform: translate(-50%, -50%) scale(1.08); }

/* Card thumbnails */
.post-card { overflow: hidden; }
.card-media {
  position: relative; margin: -1.4rem -1.4rem 1.1rem;
  aspect-ratio: 16 / 9; background: var(--surface-2); overflow: hidden;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .3s ease; }
.post-card:hover .card-media img { transform: scale(1.03); }
.card-media .yt-play { width: 56px; }

/* Only one post: a wide card with the image on the left */
.post-grid--single { grid-template-columns: 1fr; max-width: 900px; }
@media (min-width: 700px) {
  .post-grid--single .post-card {
    display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr);
    column-gap: 2rem; align-content: center; padding: 1.75rem 2rem 1.75rem 0;
  }
  .post-grid--single .post-card > :not(.card-media) { grid-column: 2; }
  .post-grid--single .card-media {
    grid-column: 1; grid-row: 1 / span 6; align-self: stretch;
    margin: -1.75rem 0; aspect-ratio: auto; min-height: 280px;
  }
  .post-grid--single .card-media img { position: absolute; inset: 0; }  /* the photo fills, the text sets the height */
}

/* ---------- PATH method ---------- */
.path-steps {
  position: relative;
  display: grid; gap: 1.25rem;
  grid-template-columns: repeat(4, 1fr);
  margin: 0; padding: 0; list-style: none;
}
/* small arrow in the gap between steps, level with the letters (one-row layout only) */
.path-steps li:not(:last-child)::after {
  content: ""; position: absolute; z-index: 2;
  top: 2.75rem; right: -1rem;
  width: .6rem; height: .6rem;
  border-top: 3px solid var(--accent); border-right: 3px solid var(--accent);
  transform: rotate(45deg);
}
.path-steps li {
  position: relative; z-index: 1;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem 1.4rem 1.5rem;
  text-align: center;
}
.path-letter {
  display: grid; place-items: center;
  width: 3.6rem; height: 3.6rem; margin: 0 auto 1rem;
  border-radius: 50%;
  background: var(--accent); color: var(--on-accent);
  font-family: var(--font-display); font-weight: 800; font-size: 1.8rem; line-height: 1;
  box-shadow: 0 0 0 6px var(--surface);
}
.path-steps h3 { font-size: 1.12rem; margin-bottom: .5rem; }
.path-steps h3 b { color: var(--accent-ink); font-weight: 800; }
.path-cta { margin: 2rem 0 0; text-align: center; color: var(--muted); }
.path-cta a { font-family: var(--font-display); font-weight: 700; white-space: nowrap; }
.path-steps p { margin: 0; color: var(--muted); font-size: 1rem; text-align: left; text-wrap: pretty; }

@media (max-width: 960px) {
  .path-steps { grid-template-columns: repeat(2, 1fr); }
  .path-steps li::after { display: none; }
}
@media (max-width: 560px) {
  .path-steps { grid-template-columns: 1fr; }
  .path-steps li { display: grid; grid-template-columns: auto 1fr; column-gap: 1rem; text-align: left; padding: 1.2rem; }
  .path-letter { grid-row: span 2; margin: 0; width: 3rem; height: 3rem; font-size: 1.5rem; }
  .path-steps h3 { margin-top: .2rem; }
}

/* ---------- Lighter Line branded signup (end of posts) ---------- */
.signup-brand { display: flex; align-items: center; gap: 1.1rem; margin-bottom: .25rem; }
.signup-brand img { flex: none; width: 112px; height: auto; filter: drop-shadow(0 6px 12px rgba(0, 0, 0, .15)); }
.signup-brand p { margin: 0; }
.signup-name {
  font-family: var(--font-display); font-weight: 800; font-size: 1.3rem; line-height: 1.2;
  letter-spacing: .01em; color: var(--accent-ink);
}
.signup-brand .signup-label { margin-top: .2rem; }
.signup-brand .signup-note { margin-top: .15rem; }
@media (max-width: 480px) {
  .signup-brand { align-items: flex-start; }
  .signup-brand img { width: 84px; }
}

/* Orange "free seasonal" line under the newsletter description in reminders */
.signup-when, .reminder .signup-when {
  font-family: var(--font-display); font-weight: 700; font-size: .9rem;
  color: var(--accent-ink); margin-top: -.4rem;
}

/* Full newsletter box (home page reminder): brand row, description, seasonal line, form */
.reminder .signup--full { max-width: 640px; margin-top: 1.4rem; padding: 1.5rem 1.5rem .9rem; }
.reminder .signup--full .signup-brand { margin-bottom: .9rem; }
.reminder .signup--full .signup-name { color: var(--accent-ink); }
.reminder .signup--full .signup-label { color: var(--text); font-family: var(--font-display); font-weight: 700; }
.reminder .signup--full .signup-desc { max-width: none; margin: 0 0 .6rem; color: var(--muted); font-size: 1rem; }
.reminder .signup--full .signup-when { max-width: none; margin: 0 0 .4rem; }

/* ---------- Signup thank-you (replaces the form after a successful signup) ---------- */
.signup-thanks { animation: thanks-in .35s ease both; }
.signup-thanks .signup-brand { margin-bottom: .9rem; }
.signup-thanks-title {
  font-family: var(--font-display); font-weight: 800; font-size: 1.15rem; line-height: 1.3;
  color: var(--text); outline: none;
}
.signup-thanks > p { font-size: 1rem; color: var(--muted); margin: 0 0 .7rem; }
.signup-thanks .signup-thanks-next { color: var(--text); font-weight: 600; margin-bottom: .4rem; }
.reminder .signup-thanks { text-align: left; }
@keyframes thanks-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
@media (prefers-reduced-motion: reduce) { .signup-thanks { animation: none; } }

/* Kit badge: smaller (about 70%), still clearly visible */
.formkit-form .formkit-powered-by-convertkit-container { margin: .35rem 0 0 !important; }
.formkit-form .formkit-powered-by-convertkit {
  width: 96px !important; height: 26px !important;
  background-size: contain !important; background-position: right center !important;
  margin: 0 0 0 auto !important;  /* right-aligned */
}

/* Sample topics near each signup */
.topics { margin: .6rem 0 .9rem; }
.topics-label { margin: 0 0 .4rem; font-family: var(--font-display); font-size: .8rem; font-weight: 700; color: var(--muted); }
.topics .chips { margin: 0; }
.topics .chips li { background: var(--surface); }
.reminder .topics { width: 100%; max-width: 640px; }
.reminder .topics:not(.signup .topics) p { max-width: 52ch; margin-inline: auto; }  /* loose topics: centered under the description */
.reminder .signup .topics p { max-width: none; margin-inline: 0; }  /* inside the box: left-aligned with everything else */
.reminder .topics:not(.signup .topics) .chips { justify-content: center; }
.topics-format { margin: .55rem 0 0; font-size: .95rem; color: var(--muted); }

@media (max-width: 340px) {
  /* the smallest phones */
  .site-header .wrap { gap: .5rem; }
  .site-nav a { padding: .35rem .3rem; font-size: .85rem; }
  .site-nav .btn { padding: .4em .6em; }
}
