/* shawnblanc.net redesign — direction C.1, set in H&Co type.
   Fonts load from the self-hosted H&Co kit at /fonts/hco-fonts.css (linked in each page's <head>).
   Sentinel SSm = reading text · Whitney SSm = UI, wordmark, subheads · Tungsten = display headlines */

:root {
  --serif: "Sentinel SSm A", "Sentinel SSm B", Georgia, serif;
  --sans: "Whitney SSm A", "Whitney SSm B", -apple-system, BlinkMacSystemFont, "Helvetica Neue", Arial, sans-serif;
  --display: "Tungsten A", "Tungsten B", "Arial Narrow", Impact, sans-serif;

  --bg: #FAF8F4;
  --fg: #1C1A17;
  --muted: #67625A;
  --rule: #E2DED5;
  --card: #EEEAE3;
  --input-bg: #FFFFFF;
  --input-line: #BDB7AC;
  --accent: #CC6E3B;
  --link: #8F4D29;

  --wrap: 1120px;
  --gutter: clamp(20px, 4vw, 56px);
  --read: 680px;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #151412;
    --fg: #ECE8E0;
    --muted: #A39E94;
    --rule: #2C2925;
    --card: #201E1B;
    --input-bg: #1C1A18;
    --input-line: #4A4640;
    --link: #CC6E3B;
  }
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a { color: inherit; text-decoration: none; }
a:hover { opacity: .75; }
img { max-width: 100%; display: block; }
h1, h2, h3, p, figure, blockquote { margin: 0; }

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.dot { color: var(--accent); }
.tap { min-height: 44px; display: inline-flex; align-items: center; }

/* ---------- Type roles ---------- */

.display {
  font-family: var(--display);
  font-weight: 700;
  line-height: .92;
  letter-spacing: .005em;
}
.h1 { font-size: clamp(56px, 8vw, 104px); }
.h-section {
  font-family: var(--sans);
  font-weight: 700;
  font-size: clamp(22px, 2.2vw, 26px);
  line-height: 1.15;
  letter-spacing: -.01em;
}
.kicker {
  font-size: 15px;
  font-style: italic;
  color: var(--link);
}
.kicker .when { color: var(--muted); }
.lede { font-size: clamp(19px, 2vw, 22px); line-height: 1.55; max-width: 30em; }
.muted { color: var(--muted); }
.more {
  font-family: var(--sans);
  font-size: 16px;
  font-weight: 600;
  color: var(--link);
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.inline-link { color: var(--link); text-decoration: underline; text-underline-offset: 3px; }

/* ---------- Header ---------- */

.site-header {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-top: 26px;
}
.wordmark {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 21px;
  letter-spacing: -.015em;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}
.site-nav { display: flex; flex-wrap: wrap; gap: 0 20px; font-family: var(--sans); font-size: 16px; }
.site-nav a { min-height: 44px; display: inline-flex; align-items: center; color: var(--muted); }
.site-nav a.cta { color: var(--link); font-weight: 600; }
.site-nav a[aria-current="page"] {
  color: var(--fg);
  text-decoration: underline;
  text-underline-offset: 6px;
  text-decoration-color: var(--accent);
  text-decoration-thickness: 2px;
}
.site-nav a.cta[aria-current="page"] { color: var(--link); }

@media (min-width: 640px) {
  .site-header {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    gap: 4px 24px;
    padding-top: 32px;
  }
  .wordmark { font-size: 24px; }
  .site-nav { gap: 0 28px; font-size: 17px; }
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: auto;
  padding: 40px 0 44px;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: flex-end;
  gap: 12px 32px;
}
.footer-mark {
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(56px, 9vw, 112px);
  line-height: .85;
  letter-spacing: .005em;
}
.footer-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0 20px;
  font-family: var(--sans);
  font-size: 15px;
  color: var(--muted);
}
.footer-meta > * { min-height: 44px; display: inline-flex; align-items: center; }
.footer-gap { height: clamp(72px, 9vw, 120px); flex: none; }

/* ---------- Avatar ---------- */

.avatar { border-radius: 999px; object-fit: cover; flex: none; }

/* ---------- Forms ---------- */

.signup { display: flex; flex-direction: column; gap: 10px; }
.signup label { font-size: 15px; font-style: italic; }
.signup .row { display: flex; gap: 8px; }
.signup input {
  flex: 1;
  min-width: 0;
  height: 50px;
  padding: 0 14px;
  border-radius: 10px;
  border: 1px solid var(--input-line);
  background: var(--input-bg);
  color: var(--fg);
  font-family: var(--serif);
  font-size: 17px;
}
.btn {
  height: 50px;
  padding: 0 20px;
  border: 0;
  border-radius: 10px;
  background: var(--fg);
  color: var(--bg);
  font-family: var(--sans);
  font-weight: 600;
  font-size: 16px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.btn:hover { opacity: .85; }
.btn-ghost {
  min-height: 52px;
  padding: 0 26px;
  border-radius: 999px;
  border: 1.5px solid var(--fg);
  font-family: var(--sans);
  font-weight: 600;
  font-size: 16px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}
.card { background: var(--card); border-radius: 16px; }
.fineprint { font-size: 14px; font-style: italic; color: var(--muted); }

/* ---------- Home ---------- */

.home-hero { margin-top: clamp(44px, 7vw, 88px); display: flex; flex-direction: column; gap: 18px; }
.home-hero .who { display: flex; align-items: center; gap: clamp(16px, 2.5vw, 28px); }
.home-hero .avatar { width: clamp(68px, 9vw, 104px); height: clamp(68px, 9vw, 104px); }

.home-grid { margin-top: clamp(44px, 6vw, 72px); display: grid; grid-template-columns: minmax(0, 1fr); gap: 52px; }
@media (min-width: 960px) {
  .home-grid { grid-template-columns: minmax(0, 1fr) 320px; gap: 72px; align-items: start; }
  .home-grid .side { position: sticky; top: 32px; }
}
.stream { display: flex; flex-direction: column; max-width: var(--read); }
.post { padding: 30px 0; border-top: 1px solid var(--rule); display: flex; flex-direction: column; gap: 10px; }
.post .title-essay { font-size: clamp(44px, 5vw, 56px); }
.post .title-link {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 22px;
  line-height: 1.22;
  letter-spacing: -.01em;
}
.post .note { font-size: 21px; line-height: 1.45; }
.post .caption { font-size: 17px; line-height: 1.5; font-style: italic; }
.permalink { font-family: var(--sans); font-size: 16px; color: var(--muted); }
.placeholder {
  width: 100%;
  aspect-ratio: 4 / 3;
  background: var(--card);
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 15px;
  font-style: italic;
  color: var(--muted);
}
.all-writing { padding-top: 18px; border-top: 1px solid var(--rule); }
.side .card { padding: 26px 22px; display: flex; flex-direction: column; gap: 12px; }
.side .card h2 { font-family: var(--sans); font-weight: 700; font-size: 22px; line-height: 1.2; letter-spacing: -.01em; }
.side .card p { font-size: 17px; line-height: 1.55; }
@media (min-width: 960px) { .side .signup .row { flex-direction: column; } }

/* ---------- Essay ---------- */

.essay { width: 100%; max-width: var(--read); margin: clamp(48px, 7vw, 88px) auto 0; }
.essay-head { display: flex; flex-direction: column; gap: 16px; }
.essay-head .h1 { font-size: clamp(64px, 9vw, 112px); }
.byline { display: flex; align-items: center; gap: 12px; margin-top: 6px; font-family: var(--sans); font-size: 15px; line-height: 1.4; color: var(--muted); }
.byline .avatar { width: 44px; height: 44px; }
.byline strong { color: var(--fg); font-weight: 600; }
.prose {
  margin-top: 36px;
  padding-top: 32px;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-direction: column;
  gap: 22px;
  font-size: clamp(19px, 1.6vw, 20.5px);
  line-height: 1.65;
}
.prose h2 { margin-top: 14px; font-family: var(--sans); font-weight: 700; font-size: 25px; line-height: 1.2; letter-spacing: -.01em; }
.pull { margin: 12px 0; display: flex; flex-direction: column; gap: 4px; }
.pull .mark { font-family: var(--display); font-weight: 700; font-size: 64px; line-height: .6; color: var(--accent); }
.pull blockquote { font-family: var(--sans); font-weight: 600; font-size: clamp(24px, 2.6vw, 28px); line-height: 1.28; letter-spacing: -.01em; }
.prose figure { display: flex; flex-direction: column; gap: 10px; }
.prose figcaption { font-size: 15px; line-height: 1.45; font-style: italic; color: var(--muted); }
.end-dot { font-family: var(--display); font-size: 32px; line-height: 1; color: var(--accent); }
.essay-signup { margin-top: 44px; padding: 28px 0; border-top: 1px solid var(--rule); border-bottom: 1px solid var(--rule); }
.essay-signup h2 { font-family: var(--sans); font-weight: 700; font-size: 22px; line-height: 1.2; }
.next { margin-top: 24px; display: flex; flex-direction: column; gap: 2px; }
.next a { font-family: var(--display); font-weight: 700; font-size: 40px; line-height: 1; min-height: 44px; display: inline-flex; align-items: center; gap: 10px; }

/* ---------- Inner pages (About, Freebies, Newsletter) ---------- */

.page-hero { margin-top: clamp(40px, 7vw, 88px); display: flex; flex-wrap: wrap; align-items: center; gap: 32px 64px; }
.page-hero .copy { flex: 999 1 440px; min-width: 0; display: flex; flex-direction: column; gap: 18px; }
.page-hero .media { flex: 1 1 340px; min-width: 0; }
.hero-photo { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; object-position: 60% 50%; border-radius: 14px; }
@media (min-width: 960px) { .hero-photo { aspect-ratio: 4 / 5; } }

.sections {
  margin-top: clamp(48px, 8vw, 104px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 44px 64px;
}
.sections > section { padding-top: 24px; border-top: 2px solid var(--fg); display: flex; flex-direction: column; gap: 12px; }
.sections p { font-size: 19px; line-height: 1.6; }
.values b { font-family: var(--sans); font-weight: 700; color: var(--link); }
.list-link {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--rule);
  font-size: 19px;
}
.list-link:last-child { border-bottom: 0; }
.list-link .dot { font-family: var(--sans); }

.freebies {
  margin-top: clamp(36px, 5vw, 56px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.freebie { padding: 18px; display: flex; flex-direction: column; gap: 12px; }
.freebie .placeholder { background: var(--bg); aspect-ratio: 4 / 3; }
.freebie h2 { font-family: var(--sans); font-weight: 700; font-size: 25px; line-height: 1.12; letter-spacing: -.01em; }
.freebie p { font-size: 17.5px; line-height: 1.55; }
.freebie .btn { margin-top: auto; height: 48px; }
.deeper {
  margin-top: 56px;
  padding-top: 28px;
  border-top: 1px solid var(--rule);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 16px 32px;
}
.deeper .name { font-family: var(--display); font-weight: 700; font-size: 44px; line-height: 1; }

.nl-card { padding: 24px 20px; display: flex; flex-direction: column; gap: 10px; }
.nl-card .card-title { font-family: var(--sans); font-weight: 700; font-size: 22px; }
.nl-card input { flex: none; height: 52px; font-size: 18px; }
.nl-card .btn { height: 52px; font-size: 17px; }
.gets p { font-size: 19px; line-height: 1.55; }
.gets .dot { font-family: var(--sans); font-weight: 700; }
.issue { padding: 14px 0; border-bottom: 1px solid var(--rule); display: flex; flex-direction: column; gap: 2px; }
.issue .date { font-size: 14px; font-style: italic; color: var(--muted); }
.issue .name { font-family: var(--sans); font-weight: 600; font-size: 20px; line-height: 1.2; }
.faq { display: flex; flex-direction: column; gap: 4px; }
.faq .q { font-family: var(--sans); font-weight: 600; font-size: 18px; }
.faq p { font-size: 18px; line-height: 1.55; color: var(--muted); }
