/* nikhilkale.ai v12: a conviction's own page. The desk's palette and type, set for reading.
   Everything served from this origin. */

@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces-latin.woff2') format('woff2'); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces-latin-italic.woff2') format('woff2'); font-weight: 300 700; font-style: italic; font-display: swap; }
@font-face { font-family: 'Geist'; src: url('../fonts/geist-latin.woff2') format('woff2'); font-weight: 300 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Geist Mono'; src: url('../fonts/geist-mono-latin.woff2') format('woff2'); font-weight: 400 600; font-style: normal; font-display: swap; }

:root {
  --bg: #ECE5D6; --ink: #1C1812; --soft: rgba(28, 24, 18, 0.74); --faint: rgba(28, 24, 18, 0.62); /* was .62 / .38: faint now 4.5:1 */
  --card: #F4EEE2; --rule: rgba(28, 24, 18, 0.22); --bronze: #84612E; --bronze-hi: #A07A43;
  --serif: 'Fraunces', 'Iowan Old Style', Georgia, serif;
  --sans: 'Geist', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --mono: 'Geist Mono', ui-monospace, 'SF Mono', Menlo, monospace;
  color-scheme: light;
}
[data-theme="dark"] {
  --bg: #0B0A08; --ink: #E9E1D0; --soft: rgba(233, 225, 208, 0.66); --faint: rgba(233, 225, 208, 0.52); /* was .4: faint now 4.5:1 */
  --card: #13110D; --rule: rgba(233, 225, 208, 0.18); --bronze: #C9A46A; --bronze-hi: #DDBE8C;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 17px/1.65 var(--sans); -webkit-font-smoothing: antialiased; }
a { color: inherit; }
:focus-visible { outline: 1px solid var(--bronze); outline-offset: 3px; }
.skip { position: absolute; left: -999px; top: 8px; z-index: 10; background: var(--card); padding: 8px 12px; font: 12px var(--mono); }
.skip:focus { left: 8px; }

.label { font: 500 12px var(--sans); letter-spacing: .08em; text-transform: uppercase; }

.cv-head, .cv-foot { max-width: 760px; margin: 0 auto; padding: 22px 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.cv-head { border-bottom: 1px solid var(--rule); }
.cv-mark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; font: 500 13px var(--sans); letter-spacing: .06em; text-transform: uppercase; }
.cv-mark .sun { width: 12px; height: 12px; border-radius: 50%; box-shadow: inset 0 0 0 1px var(--bronze); position: relative; }
.cv-mark .sun::after { content: ''; position: absolute; inset: 4px; border-radius: 50%; background: var(--bronze); }
.cv-mark .dim { color: var(--faint); font: 11px var(--mono); letter-spacing: .04em; text-transform: none; }
.cv-back, .cv-foot a { color: var(--soft); text-decoration: none; }
.cv-back:hover, .cv-foot a:hover { color: var(--ink); }

.cv { max-width: 760px; margin: 0 auto; padding: 40px 24px 56px; }
.cv-crumbs { color: var(--faint); margin-bottom: 36px; }
.cv-crumbs ol { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 8px; }
.cv-crumbs li + li::before { content: '/'; margin-right: 8px; }
.cv-crumbs a { text-decoration: none; color: var(--soft); }
.cv-crumbs a:hover { color: var(--ink); }

.cv-kind { display: flex; align-items: center; gap: 12px; margin: 0 0 18px; color: var(--soft); }
.cv-seal { width: 30px; height: 30px; color: var(--bronze); display: grid; place-items: center; box-shadow: inset 0 0 0 1px var(--bronze); border-radius: 50%; }
.cv-seal svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.2; overflow: visible; }
.cv-num { font: 400 italic 20px var(--serif); color: var(--bronze); letter-spacing: 0; text-transform: none; }

.cv-thesis { font: 340 clamp(38px, 6.4vw, 68px)/1.02 var(--serif); letter-spacing: -.03em; margin: 0 0 36px; text-wrap: balance; }
.cv-thesis em, .cv-body em { font-style: italic; color: var(--bronze); }

.cv-figure { margin: 0 0 36px; }
.cv-figure img { display: block; width: auto; max-width: 100%; max-height: 72vh; height: auto; background: var(--card); box-shadow: 0 0 0 1px var(--rule); }
.cv-more { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; margin-top: 12px; }
.cv-ornament { margin: 0 0 36px; padding: 48px 0; display: grid; place-items: center; background: var(--card); box-shadow: 0 0 0 1px var(--rule); color: var(--bronze); }
.cv-ornament svg { width: 96px; height: 96px; fill: none; stroke: currentColor; stroke-width: .6; overflow: visible; }

.cv-proof { font: 340 clamp(21px, 2.4vw, 26px)/1.4 var(--serif); margin: 0 0 24px; max-width: 34em; }
.cv-body { color: var(--soft); max-width: 36em; }
.cv-body p { margin: 0 0 1em; }

.cv-links { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin: 32px 0 0; }
.cv-links a, .cv-links span { display: inline-flex; align-items: center; min-height: 40px; padding: 0 16px; font: 500 12.5px var(--sans); letter-spacing: .02em; text-transform: uppercase; text-decoration: none; border-radius: 20px; }
.cv-links a.primary { background: var(--bronze); color: var(--card); }
.cv-links a.quiet { box-shadow: inset 0 0 0 1px var(--bronze); }
.cv-links a:hover { filter: brightness(1.08); }
.cv-links span { color: var(--faint); font: 11px var(--mono); padding: 0; }

.cv-nav { display: flex; justify-content: space-between; gap: 16px; margin-top: 56px; padding-top: 18px; border-top: 1px solid var(--rule); }
.cv-nav a { text-decoration: none; color: var(--soft); display: flex; flex-direction: column; gap: 4px; }
.cv-nav a:last-child { text-align: right; }
.cv-nav a b { font: 340 21px/1.2 var(--serif); letter-spacing: -.01em; color: var(--ink); text-transform: none; }
.cv-nav a:hover b { color: var(--bronze); }

.cv-foot { border-top: 1px solid var(--rule); color: var(--faint); font: 11px/1.5 var(--mono); text-transform: uppercase; letter-spacing: .04em; }
.cv-foot p { margin: 0; }

@media (max-width: 560px) {
  body { font-size: 16px; }
  .cv-head, .cv-foot { padding: 16px 18px; }
  .cv-mark .dim { display: none; }
  .cv { padding: 28px 18px 44px; }
  .cv-foot { flex-direction: column; align-items: flex-start; }
}

/* privacy and 404 (2026-10-06) */
.cv-prose { color: var(--ink); }
.cv-prose p { margin: 0 0 1.1em; }
.cv-foot p a { color: inherit; }
.cv-lost { padding-top: 24px; }
