/*
 * gawshinde.com
 * Warm paper, near-black ink, one forest accent. Newsreader for display and reading, Schibsted Grotesk for interface text.
 */
:root {
  --paper: #FFFFFF;
  --paper-deep: #F2F2F2;
  --surface: #FFFFFF;
  --ink: #111111;
  --body: #333333;
  --muted: #666666;
  --line: #E5E5E5;
  --accent: #111111;
  --accent-hover: #666666;
  --accent-tint: #F2F2F2;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Schibsted Grotesk", system-ui, -apple-system, "Segoe UI", sans-serif;
  --gutter: max(16px, 4vw, env(safe-area-inset-left, 0px));
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 24px; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 17px; line-height: 1.6; overflow-x: clip; }
h1, h2, h3 { margin: 0; text-wrap: balance; }
p { margin: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--ink); text-decoration-thickness: 1px; text-underline-offset: 5px; }
a:hover { color: var(--muted); }
:focus-visible { outline: 2px solid var(--ink); outline-offset: 4px; }
[hidden] { display: none !important; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 10; background: var(--ink); color: #fff; padding: 10px 14px; }
.skip:focus { top: 10px; color: #fff; }

.wrap { max-width: 1200px; margin: 0 auto; padding-left: var(--gutter); padding-right: var(--gutter); }
@media (min-width: 1200px) { .wrap { padding-left: 48px; padding-right: 48px; } }
.label { font-size: 15px; color: var(--muted); }

/* ---------- Header and footer (centered) ---------- */
.site-header { border-bottom: 1px solid var(--line); }
.site-header .wrap { display: flex; justify-content: center; padding-block: 26px; }
.brand { text-decoration: none; color: var(--ink); }
.brand-name { font-family: var(--serif); font-size: 26px; letter-spacing: -0.01em; }
.site-footer { margin-top: clamp(56px, 8vw, 96px); border-top: 1px solid var(--line); font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 8px 28px; padding-block: 32px; }
.site-footer a { color: var(--muted); }

/* ---------- Shared pieces ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 26px; border: 0; border-radius: 2px; font: inherit; font-size: 16px; font-weight: 500; text-decoration: none; cursor: pointer; }
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); color: #fff; }
.link-strong { font-size: 16px; padding: 12px 0; }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 28px; }
.display { font-family: var(--serif); font-weight: 340; font-size: clamp(38px, 5.4vw, 72px); line-height: 1.05; letter-spacing: -0.024em; }
.h2 { font-family: var(--serif); font-weight: 360; font-size: clamp(32px, 3.8vw, 48px); line-height: 1.1; letter-spacing: -0.02em; }
.h2-sm { font-family: var(--serif); font-weight: 380; font-size: clamp(26px, 2.8vw, 34px); line-height: 1.15; letter-spacing: -0.012em; }
.h3 { font-family: var(--serif); font-weight: 400; font-size: 26px; line-height: 1.2; }
.lede { font-size: clamp(18px, 1.6vw, 20px); line-height: 1.55; color: var(--body); }
.empty { color: var(--muted); }

/* Post list */
.post-list { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--ink); }
.post-item { padding: 26px 0; border-bottom: 1px solid var(--line); display: grid; gap: 6px; }
.post-meta { display: flex; flex-wrap: wrap; gap: 4px 10px; font-size: 14px; color: var(--muted); }
.post-meta a { color: var(--muted); text-decoration: none; }
.post-meta a:hover { text-decoration: underline; }
.post-item-title { font-family: var(--serif); font-weight: 400; font-size: clamp(22px, 2.2vw, 27px); line-height: 1.25; }
.post-item-title a { text-decoration: none; }
.post-item-title a:hover { text-decoration: underline; color: var(--ink); }
.post-item-desc { max-width: 720px; color: var(--body); font-size: 16px; }

/* ---------- Home and category pages: one centered column ---------- */
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.wrap.column { max-width: calc(720px + 2 * var(--gutter)); padding-top: clamp(40px, 6vw, 72px); }
@media (min-width: 1200px) { .wrap.column { max-width: 816px; } }
.intro { font-family: var(--serif); font-size: clamp(20px, 2vw, 23px); line-height: 1.55; color: var(--ink); margin-bottom: clamp(36px, 5vw, 56px); }
.topic-nav { display: flex; flex-wrap: wrap; gap: 4px 22px; padding-bottom: 12px; border-bottom: 1px solid var(--ink); font-size: 15px; }
.topic-nav a { padding: 6px 0; color: var(--muted); text-decoration: none; }
.topic-nav a:hover { color: var(--ink); text-decoration: underline; }
.topic-nav a[aria-current="page"] { color: var(--ink); font-weight: 600; }
.column .post-list { border-top: 0; }
.category-header { padding: 28px 0 8px; display: grid; gap: 6px; }
.category-title { font-family: var(--serif); font-weight: 400; font-size: clamp(28px, 3vw, 34px); line-height: 1.2; }
.category-desc { color: var(--muted); font-size: 16px; }
.empty { padding-top: 24px; }

/* ---------- Simple pages ---------- */
.page { padding-top: clamp(40px, 6vw, 80px); }
.page-header { display: grid; gap: 12px; margin-bottom: clamp(28px, 4vw, 40px); max-width: 720px; }
.page-title { font-family: var(--serif); font-weight: 380; font-size: clamp(32px, 3.6vw, 44px); line-height: 1.12; letter-spacing: -0.015em; }

/* ---------- Post ---------- */
.post { padding-top: clamp(40px, 6vw, 80px); }
.post-header { max-width: 680px; margin: 0 auto clamp(32px, 4vw, 48px); display: grid; gap: 18px; }
.post-title { font-family: var(--serif); font-weight: 360; font-size: clamp(36px, 4.8vw, 58px); line-height: 1.08; letter-spacing: -0.02em; }
.post-dek { font-size: clamp(18px, 1.6vw, 21px); line-height: 1.5; color: var(--body); }
.post-updated { font-size: 14px; color: var(--muted); }

.prose { max-width: 680px; margin: 0 auto; font-family: var(--serif); font-size: 20px; line-height: 1.65; color: #222222; }
.prose > * + * { margin-top: 1.1em; }
.prose h2 { margin-top: 1.9em; font-weight: 500; font-size: 28px; line-height: 1.25; letter-spacing: -0.01em; }
.prose h3 { margin-top: 1.6em; font-weight: 500; font-size: 23px; line-height: 1.3; }
.prose h2 + *, .prose h3 + * { margin-top: 0.6em; }
.prose a { color: var(--accent); }
.prose a:hover { color: var(--accent-hover); }
.prose strong { font-weight: 600; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 0.4em; }
.prose blockquote { margin-left: 0; margin-right: 0; padding: 4px 0 4px 22px; border-left: 2px solid var(--ink); font-style: italic; color: var(--body); }
.prose hr { border: 0; border-top: 1px solid var(--line); margin: 2.2em 0; }
.prose code { font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; font-size: 0.82em; background: var(--paper-deep); padding: 2px 5px; border-radius: 2px; }
.prose pre { overflow-x: auto; background: var(--ink); color: #EEEEEE; padding: 18px 20px; border-radius: 2px; font-size: 15px; line-height: 1.55; }
.prose pre code { background: none; padding: 0; font-size: inherit; }
.prose img, .prose figure { margin-left: auto; margin-right: auto; }
.prose figcaption { margin-top: 8px; font-family: var(--sans); font-size: 14px; color: var(--muted); }
.prose table { width: 100%; border-collapse: collapse; font-family: var(--sans); font-size: 15px; display: block; overflow-x: auto; }
.prose th, .prose td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.prose .note { font-family: var(--sans); font-size: 16px; background: var(--accent-tint); padding: 16px 18px; border-radius: 2px; }

.post-footer { max-width: 680px; margin: clamp(48px, 6vw, 72px) auto 0; display: grid; gap: 48px; }
.author-card { border-top: 1px solid var(--ink); padding-top: 20px; display: grid; gap: 6px; font-size: 16px; color: var(--body); }
.author-name { font-family: var(--serif); font-size: 22px; color: var(--ink); }
.related-title { font-family: var(--serif); font-weight: 400; font-size: 24px; margin-bottom: 14px; }

/* ---------- Free tools (same list as posts) ---------- */
.tool-list { border-top: 0; }
.tool-item.is-soon .post-item-title, .tool-item.is-soon .post-item-desc { color: var(--muted); }
.tool-arrow { font-size: 0.75em; margin-left: 2px; }
.tool-item .post-item-desc a { color: var(--body); text-decoration: none; }
.tool-item .post-item-desc a:hover { text-decoration: underline; }
.tools-note { margin-top: 24px; font-size: 14px; color: var(--muted); }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .prose { font-size: 19px; }
}
@media print {
  .site-header, .site-footer, .topic-nav, .related { display: none; }
  body { background: #fff; }
}
