/* One stylesheet for the whole site. Small enough that splitting it would cost
   more requests than it saves bytes. */

:root {
  --bg: #f7f6fc;
  --card: #ffffff;
  --text: #1a1a2e;
  --muted: #5c5c72;
  --faint: #8a8aa0;
  --brand: #7c6bf5;
  --line: rgba(0, 0, 0, 0.08);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #120c1f;
    --card: #1a1229;
    --text: #ffffff;
    --muted: rgba(255, 255, 255, 0.72);
    --faint: rgba(255, 255, 255, 0.45);
    --line: rgba(255, 255, 255, 0.12);
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto,
    "Noto Sans", "Noto Sans Devanagari", sans-serif;
  line-height: 1.6;
  -webkit-text-size-adjust: 100%;
}

.wrap {
  max-width: 640px;
  margin: 0 auto;
  padding: 32px 20px 8px;
}

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 24px;
}

.center { text-align: center; }

h1 { font-size: 26px; line-height: 1.3; margin: 0 0 12px; }
h2 { font-size: 18px; margin: 28px 0 8px; }

p { margin: 0 0 14px; }

.muted { color: var(--muted); }
.small { font-size: 14px; }

a { color: var(--brand); }

/* --- a shared post --- */

.byline {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.avatar {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  font-size: 20px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex: none;
}

.name { font-weight: 700; }

.content {
  /* Posts arrive with their own line breaks and those carry the meaning in a
     shayari, so they are preserved rather than collapsed. */
  white-space: pre-wrap;
  font-size: 19px;
  line-height: 1.75;
  margin: 4px 0 22px;
}

.shot {
  width: 100%;
  height: auto;
  border-radius: 12px;
  margin-bottom: 18px;
  display: block;

  /* Posts carry no stored dimensions, so the real ratio is unknown until the
     image arrives. Reserving a plausible portrait box keeps the text below it
     from jumping down the page mid-read, and the tinted background means the
     space reads as "loading" rather than as a rendering fault. */
  aspect-ratio: 4 / 5;
  object-fit: cover;
  background: color-mix(in srgb, var(--brand) 12%, transparent);
}

.btn {
  display: block;
  text-align: center;
  background: var(--brand);
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: 14px 20px;
  border-radius: 999px;
  margin-bottom: 14px;
}

/* --- long-form pages --- */

.doc h2:first-of-type { margin-top: 8px; }
.doc ul { padding-left: 20px; margin: 0 0 14px; }
.doc li { margin-bottom: 6px; }

.foot {
  max-width: 640px;
  margin: 0 auto;
  padding: 24px 20px 40px;
  text-align: center;
  color: var(--faint);
  font-size: 14px;
}

.foot a { color: var(--faint); }

/* --- landing --- */

.hero { text-align: center; padding: 24px 0 8px; }
.hero img { width: min(320px, 78%); height: auto; }
.hero p { color: var(--muted); font-size: 17px; }
