/* ============================================================
   who-am-i — Sameer Rawat
   Single-page personal hub. No build step, no dependencies.
   ============================================================ */

/* ---------- Tokens ---------- */
:root {
  --paper:        #fbfaf8;
  --paper-alt:    #f4f1ec;
  --card:         #ffffff;
  --ink:          #16120f;
  --ink-soft:     #4a423c;
  --ink-muted:    #7d736b;
  --line:         #e6e0d8;
  --accent:       #c2410c;
  --accent-soft:  #fff1e8;
  --accent-ink:   #ffffff;

  --radius:       18px;
  --radius-sm:    10px;
  --shell:        1180px;
  --gutter:       clamp(20px, 5vw, 48px);

  --shadow-sm:    0 1px 2px rgba(22,18,15,.05), 0 4px 12px rgba(22,18,15,.04);
  --shadow-md:    0 2px 6px rgba(22,18,15,.06), 0 18px 40px rgba(22,18,15,.08);

  --sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Roboto, "Helvetica Neue", Arial, sans-serif;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia, "Times New Roman", serif;

  --ease: cubic-bezier(.22, 1, .36, 1);
}

:root[data-theme="dark"] {
  --paper:        #100d0b;
  --paper-alt:    #171310;
  --card:         #1b1613;
  --ink:          #f6f2ee;
  --ink-soft:     #c7bcb2;
  --ink-muted:    #8e8177;
  --line:         #2c2521;
  --accent:       #fb923c;
  --accent-soft:  #2a1a10;
  --accent-ink:   #1a1109;

  --shadow-sm:    0 1px 2px rgba(0,0,0,.4);
  --shadow-md:    0 2px 8px rgba(0,0,0,.4), 0 24px 48px rgba(0,0,0,.35);
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  transition: background-color .3s var(--ease), color .3s var(--ease);
}
img { max-width: 100%; display: block; }
a { color: inherit; }
h1, h2, h3 { margin: 0; line-height: 1.1; letter-spacing: -.02em; font-weight: 600; }
p  { margin: 0 0 1.1em; }
ul, ol, dl, dd { margin: 0; padding: 0; }
li { list-style: none; }
svg { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }

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

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

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--ink); color: var(--paper);
  padding: 12px 20px; border-radius: 0 0 var(--radius-sm) 0;
  text-decoration: none;
}
.skip-link:focus { left: 0; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in srgb, var(--paper) 82%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease), background-color .3s var(--ease);
}
.site-header.is-stuck { border-bottom-color: var(--line); }

.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; height: 72px;
}

.wordmark {
  display: inline-flex; align-items: center; gap: 11px;
  text-decoration: none; font-weight: 600; letter-spacing: -.01em;
}
.wordmark-initials {
  display: grid; place-items: center;
  width: 34px; height: 34px; border-radius: 9px;
  background: var(--ink); color: var(--paper);
  font-size: 13px; letter-spacing: .04em;
}
.wordmark-name { font-size: 16px; }

.site-nav { display: flex; gap: 30px; margin-left: auto; }
.site-nav a {
  position: relative;
  text-decoration: none;
  font-size: 15px;
  color: var(--ink-soft);
  transition: color .2s var(--ease);
}
.site-nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -5px; height: 1.5px;
  background: var(--accent); transform: scaleX(0); transform-origin: left;
  transition: transform .3s var(--ease);
}
.site-nav a:hover { color: var(--ink); }
.site-nav a:hover::after,
.site-nav a.is-active::after { transform: scaleX(1); }
.site-nav a.is-active { color: var(--ink); }

.theme-toggle {
  display: grid; place-items: center;
  width: 38px; height: 38px; padding: 0;
  border: 1px solid var(--line); border-radius: 10px;
  background: transparent; color: var(--ink-soft);
  cursor: pointer;
  transition: border-color .2s var(--ease), color .2s var(--ease), background-color .2s var(--ease);
}
.theme-toggle:hover { color: var(--ink); border-color: var(--ink-muted); }
.theme-toggle svg { width: 17px; height: 17px; }
.theme-toggle .icon-moon { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-sun  { display: none; }
:root[data-theme="dark"] .theme-toggle .icon-moon { display: block; }

/* ---------- Hero ---------- */
.hero { position: relative; padding-top: clamp(48px, 8vw, 92px); overflow: hidden; }
.hero::before {
  content: ""; position: absolute; z-index: -1;
  top: -280px; right: -180px; width: 720px; height: 720px;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 16%, transparent) 0%, transparent 65%);
  pointer-events: none;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.32fr) minmax(0, .78fr);
  gap: clamp(32px, 5vw, 72px);
  align-items: center;
  padding-bottom: clamp(48px, 7vw, 84px);
}

.eyebrow {
  display: inline-flex; align-items: center; gap: 9px;
  margin: 0 0 24px;
  font-size: 13px; letter-spacing: .04em;
  color: var(--ink-muted);
  border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 14px 6px 12px;
}
.pulse {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 0 color-mix(in srgb, var(--accent) 60%, transparent);
  animation: pulse 2.4s infinite;
}
@keyframes pulse {
  70%  { box-shadow: 0 0 0 9px transparent; }
  100% { box-shadow: 0 0 0 0 transparent; }
}

.display {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(34px, 4.6vw, 58px);
  line-height: 1.08;
  letter-spacing: -.025em;
  margin-bottom: 26px;
}
.display em {
  font-style: italic;
  color: var(--accent);
}

.lede {
  max-width: 56ch;
  font-size: clamp(16px, 1.3vw, 18.5px);
  color: var(--ink-soft);
  margin-bottom: 32px;
}
.lede strong { color: var(--ink); font-weight: 600; }

/* ---------- Hero manifesto ---------- */
.hero-welcome {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(20px, 2vw, 26px);
  color: var(--accent);
  margin-bottom: 12px;
}

.hero-lines { margin-bottom: 30px; }
.hero-lines li {
  position: relative;
  padding-left: 30px;
  font-size: clamp(17px, 1.5vw, 20px);
  line-height: 2;
  color: var(--ink-soft);
}
/* Short rule instead of a bullet — keeps the list reading as statements. */
.hero-lines li::before {
  content: "";
  position: absolute; left: 0; top: 1em;
  width: 14px; height: 1.5px;
  background: var(--accent);
  opacity: .7;
}
.hero-lines b { font-weight: 600; color: var(--ink); }

/* Each statement arrives just after the one above it. */
.js [data-reveal] .hero-lines li {
  opacity: 0;
  transform: translateY(8px);
  transition: opacity .55s var(--ease), transform .55s var(--ease);
}
.js [data-reveal].is-visible .hero-lines li { opacity: 1; transform: none; }
.js [data-reveal].is-visible .hero-lines li:nth-child(1) { transition-delay: .10s; }
.js [data-reveal].is-visible .hero-lines li:nth-child(2) { transition-delay: .22s; }
.js [data-reveal].is-visible .hero-lines li:nth-child(3) { transition-delay: .34s; }
.js [data-reveal].is-visible .hero-lines li:nth-child(4) { transition-delay: .46s; }

.hero-close {
  max-width: 44ch;
  font-size: clamp(15px, 1.2vw, 17px);
  color: var(--ink-muted);
  margin-bottom: 34px;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-bottom: 48px; }

.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 13px 22px;
  border-radius: 999px;
  font-size: 15px; font-weight: 500;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: transform .2s var(--ease), background-color .2s var(--ease),
              border-color .2s var(--ease), color .2s var(--ease), box-shadow .2s var(--ease);
}
.btn svg { width: 16px; height: 16px; transition: transform .25s var(--ease); }
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--accent); color: var(--accent-ink); box-shadow: var(--shadow-sm); }
.btn-primary:hover { box-shadow: var(--shadow-md); }
.btn-primary:hover svg { transform: translateX(3px); }
.btn-ghost { border-color: var(--line); color: var(--ink); }
.btn-ghost:hover { border-color: var(--ink); }

.hero-stats {
  display: flex; flex-wrap: wrap; gap: clamp(24px, 4vw, 52px);
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.hero-stats dt { font-size: 13px; color: var(--ink-muted); margin-bottom: 4px; }
.hero-stats dd {
  font-family: var(--serif);
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1;
  letter-spacing: -.02em;
}
.hero-stats dd span { color: var(--accent); }

/* Portrait */
.hero-portrait { position: relative; }
.portrait-frame {
  position: relative;
  aspect-ratio: 4 / 5;
  border-radius: calc(var(--radius) + 6px);
  overflow: hidden;
  background: var(--paper-alt);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-md);
}
.portrait-frame img {
  position: relative; z-index: 1;
  width: 100%; height: 100%;
  object-fit: cover;
}
/* Shown only when the portrait image is missing or fails to load */
.portrait-fallback {
  position: absolute; inset: 0; z-index: 0;
  display: grid; place-items: center;
  font-family: var(--serif);
  font-size: 72px; letter-spacing: .05em;
  color: var(--ink-muted);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--accent) 10%, transparent), transparent 60%),
    var(--paper-alt);
}
.portrait-caption {
  margin-top: 14px;
  font-size: 13px;
  color: var(--ink-muted);
  text-align: right;
}

/* Marquee */
.marquee {
  border-block: 1px solid var(--line);
  padding: 16px 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}
.marquee-track {
  display: flex; align-items: center; gap: 28px;
  width: max-content;
  animation: scroll 34s linear infinite;
}
.marquee-track span {
  font-family: var(--serif);
  font-size: 19px;
  color: var(--ink-muted);
  white-space: nowrap;
}
.marquee-track .dot {
  width: 5px; height: 5px; border-radius: 50%;
  background: var(--accent); opacity: .6; flex: none;
}
@keyframes scroll { to { transform: translateX(-50%); } }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 118px); }
.section-alt { background: var(--paper-alt); }

.section-label {
  font-size: 12.5px;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 16px;
}
.section-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(30px, 4vw, 46px);
  letter-spacing: -.02em;
}
.section-sub {
  margin-top: 18px;
  max-width: 54ch;
  color: var(--ink-soft);
}
.section-head.wide { margin-bottom: clamp(40px, 5vw, 64px); }

/* About */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.about-lead {
  font-family: var(--serif);
  font-size: clamp(21px, 2.2vw, 26px);
  line-height: 1.4;
  letter-spacing: -.015em;
  margin-bottom: 24px;
}
.about-body p { color: var(--ink-soft); }
.about-body p strong { color: var(--ink); font-weight: 600; }

.capability-list { margin-top: 34px; border-top: 1px solid var(--line); }
.capability-list li {
  display: flex; align-items: baseline; justify-content: space-between;
  gap: 20px; padding: 15px 0;
  border-bottom: 1px solid var(--line);
}
.capability-list span { font-weight: 500; }
.capability-list em {
  font-style: normal; font-size: 14px; color: var(--ink-muted);
  text-align: right;
}

/* Ventures */
/* Four cards — a 2×2 block, so the last one never orphans on its own row. */
.venture-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 22px;
}
@media (min-width: 720px) {
  .venture-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.venture-card {
  display: flex; flex-direction: column;
  padding: 30px 28px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.venture-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}
.venture-top {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 26px;
}
.venture-index {
  font-family: var(--serif); font-size: 15px; color: var(--ink-muted);
}
.venture-status {
  font-size: 11.5px; letter-spacing: .08em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
}
.venture-status.is-live { background: var(--accent-soft); color: var(--accent); }
.venture-status.is-soon { background: var(--paper-alt); color: var(--ink-muted); border: 1px solid var(--line); }
:root[data-theme="dark"] .venture-status.is-soon { background: transparent; }

.venture-name {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 27px;
  margin-bottom: 4px;
}
.venture-role { font-size: 14px; color: var(--accent); margin-bottom: 16px; }
.venture-desc { font-size: 15.5px; color: var(--ink-soft); margin-bottom: 22px; }

.venture-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 26px; }
.venture-tags li {
  font-size: 12.5px; color: var(--ink-muted);
  border: 1px solid var(--line); border-radius: 6px;
  padding: 3px 9px;
}

.venture-link {
  display: inline-flex; align-items: center; gap: 7px;
  margin-top: auto;
  font-size: 14.5px; font-weight: 500;
  text-decoration: none;
  color: var(--ink);
  border-bottom: 1px solid transparent;
  align-self: flex-start;
  transition: color .2s var(--ease), border-color .2s var(--ease);
}
.venture-link svg { width: 14px; height: 14px; transition: transform .25s var(--ease); }
.venture-link:hover { color: var(--accent); border-bottom-color: var(--accent); }
.venture-link:hover svg { transform: translate(2px, -2px); }

/* Writing */
.book-feature {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr);
  gap: clamp(28px, 4vw, 56px);
  padding: clamp(28px, 4vw, 46px);
  margin-bottom: 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}
.book-feature .venture-index { letter-spacing: .02em; }

.book-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(32px, 3.6vw, 44px);
  letter-spacing: -.025em;
  margin-bottom: 4px;
}
.book-sub {
  font-family: var(--serif);
  font-style: italic;
  font-size: 19px;
  color: var(--accent);
  margin-bottom: 26px;
}

.pull-quote {
  margin: 0 0 24px;
  padding-left: 22px;
  border-left: 2px solid color-mix(in srgb, var(--accent) 55%, transparent);
}
.pull-quote p {
  font-family: var(--serif);
  font-size: clamp(17px, 1.5vw, 19.5px);
  line-height: 1.5;
  color: var(--ink);
  margin-bottom: .7em;
}
.pull-quote p:last-child { margin-bottom: 0; color: var(--ink-soft); }

.book-desc { color: var(--ink-soft); margin-bottom: 28px; }

.book-meta {
  display: flex; flex-wrap: wrap; gap: 12px 36px;
  padding-top: 22px;
  border-top: 1px solid var(--line);
}
.book-meta dt {
  font-size: 12px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--ink-muted); margin-bottom: 3px;
}
.book-meta dd { font-size: 15px; font-weight: 500; }

/* The arc */
.book-arc {
  padding: 28px;
  background: var(--paper-alt);
  border-radius: var(--radius-sm);
}
:root[data-theme="dark"] .book-arc { background: color-mix(in srgb, var(--paper) 60%, transparent); }

.arc-label {
  font-size: 12px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 20px;
}
.arc-list { counter-reset: arc; }
.arc-stage { position: relative; padding: 0 0 20px 22px; }
.arc-stage::before {
  content: ""; position: absolute; left: 3px; top: 9px;
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent);
}
.arc-stage::after {
  content: ""; position: absolute; left: 6px; top: 20px; bottom: 2px;
  width: 1px; background: var(--line);
}
.arc-stage:last-child { padding-bottom: 0; }
.arc-stage:last-child::after { display: none; }
.arc-stage:not(:first-child)::before { background: var(--ink-muted); }

.arc-name {
  font-family: var(--serif);
  font-size: 19px;
  letter-spacing: -.01em;
}
.arc-chapters { margin-top: 9px; }
.arc-chapters li {
  font-size: 14.5px;
  color: var(--ink-muted);
  padding: 2px 0;
}
.arc-note {
  margin: 22px 0 0;
  padding-top: 18px;
  border-top: 1px solid var(--line);
  font-family: var(--serif);
  font-style: italic;
  font-size: 15.5px;
  color: var(--ink-soft);
}

.writing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  align-items: start;   /* cards size to their content instead of stretching */
  gap: 22px;
}
.writing-card {
  display: flex; flex-direction: column;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.writing-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}
.writing-media { display: block; overflow: hidden; background: var(--paper-alt); }
.writing-media img {
  width: 100%; height: auto;
  transition: transform .5s var(--ease);
}
.writing-card:hover .writing-media img { transform: scale(1.03); }

.writing-body { padding: 26px 28px 30px; }
.writing-kicker {
  font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 10px;
}
.writing-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 25px;
  margin-bottom: 12px;
}
.writing-body p { font-size: 15.5px; color: var(--ink-soft); }
.writing-tease {
  margin-top: 16px; padding-top: 16px;
  border-top: 1px solid var(--line);
  font-size: 14.5px;
}
.writing-tease strong { color: var(--accent); font-weight: 600; }
.writing-card.is-plain .writing-body { padding-top: 30px; }
.writing-card .venture-tags { margin: 18px 0 0; }
/* .venture-link relies on margin-top:auto inside the flex venture cards; the
   writing card body is a plain block, so give it an explicit gap. */
.writing-body .venture-link { margin-top: 18px; }

/* Experience */
.exp-grid {
  display: grid;
  grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr);
  gap: clamp(32px, 5vw, 80px);
  align-items: start;
}
.timeline { border-left: 1px solid var(--line); }
.timeline-item {
  position: relative;
  padding: 0 0 40px 32px;
}
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  content: ""; position: absolute; left: -5px; top: 7px;
  width: 9px; height: 9px; border-radius: 50%;
  background: var(--paper); border: 2px solid var(--ink-muted);
  transition: border-color .25s var(--ease), background-color .25s var(--ease);
}
.timeline-item:first-child::before { border-color: var(--accent); background: var(--accent); }
.timeline-when {
  font-size: 13px; letter-spacing: .04em;
  color: var(--ink-muted);
  margin-bottom: 8px;
}
.timeline-what h3 { font-size: 20px; margin-bottom: 2px; }
.timeline-org { font-size: 15px; color: var(--accent); margin-bottom: 10px; }
.timeline-what p:last-child { font-size: 15.5px; color: var(--ink-soft); margin-bottom: 0; }

/* Companies where several roles stacked up over the years. */
.timeline-roles { margin: 10px 0 14px; }
.timeline-roles li {
  display: flex; align-items: baseline; gap: 12px;
  font-size: 14.5px;
  padding: 3px 0;
}
.timeline-roles span { color: var(--accent); }
.timeline-roles em {
  font-style: normal;
  color: var(--ink-muted);
  font-size: 13px;
  white-space: nowrap;
}
/* Hairline connecting role to its dates, so the eye tracks across the gap. */
.timeline-roles li::after {
  content: "";
  order: 1;
  flex: 1 1 auto;
  height: 1px;
  margin-bottom: 4px;
  background: var(--line);
}
.timeline-roles em { order: 2; }

/* Contact */
.contact { padding-bottom: clamp(64px, 8vw, 100px); }
.contact-card {
  position: relative;
  overflow: hidden;
  padding: clamp(40px, 6vw, 76px);
  border-radius: calc(var(--radius) + 8px);
  background: var(--ink);
  color: var(--paper);
  text-align: center;
}
:root[data-theme="dark"] .contact-card { border: 1px solid var(--line); }
.contact-card::after {
  content: ""; position: absolute;
  bottom: -320px; left: 50%; transform: translateX(-50%);
  width: 780px; height: 620px;
  background: radial-gradient(circle, color-mix(in srgb, var(--accent) 34%, transparent) 0%, transparent 68%);
  pointer-events: none;
}
.contact-card > * { position: relative; z-index: 1; }
/* The card inverts against the page, so tint the label toward --paper
   (light text on the dark card, darker text on the light one). */
.contact-card .section-label { color: color-mix(in srgb, var(--accent) 82%, var(--paper)); }
.contact-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(28px, 4vw, 46px);
  letter-spacing: -.02em;
  margin-bottom: 18px;
}
.contact-sub {
  max-width: 46ch; margin-inline: auto;
  color: color-mix(in srgb, var(--paper) 72%, transparent);
}
.contact-actions {
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: center;
  margin: 32px 0 40px;
}
.contact-card .btn-ghost {
  border-color: color-mix(in srgb, var(--paper) 30%, transparent);
  color: var(--paper);
}
.contact-card .btn-ghost:hover { border-color: var(--paper); }

.contact-links {
  display: flex; flex-wrap: wrap; gap: 10px 28px; justify-content: center;
  padding-top: 28px;
  border-top: 1px solid color-mix(in srgb, var(--paper) 16%, transparent);
}
.contact-links a {
  font-size: 14.5px;
  color: color-mix(in srgb, var(--paper) 72%, transparent);
  text-decoration: none;
  transition: color .2s var(--ease);
}
.contact-links a:hover { color: var(--paper); }

/* ============================================================
   LiveTo160 — hub + article pages
   ============================================================ */
.shell-narrow { max-width: 760px; }

/* Hub */
.hub-head { padding: clamp(52px, 7vw, 92px) 0 clamp(36px, 5vw, 56px); }
.hub-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(32px, 4.4vw, 52px);
  letter-spacing: -.025em;
  margin-bottom: 20px;
}
.hub-sub {
  max-width: 54ch;
  font-size: clamp(16px, 1.3vw, 18.5px);
  color: var(--ink-soft);
}
.hub-meta { font-size: 14.5px; color: var(--ink-muted); margin: 0; }
.hub-meta a { color: var(--accent); text-decoration: none; }
.hub-meta a:hover { text-decoration: underline; }

.post-list { display: grid; gap: 22px; }
@media (min-width: 720px) {
  .post-list { grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: start; }
}
.post-card {
  display: flex; flex-direction: column;
  overflow: hidden;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.post-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-md);
  border-color: color-mix(in srgb, var(--accent) 40%, var(--line));
}
.post-media { display: block; overflow: hidden; background: var(--paper-alt); }
.post-media img { width: 100%; height: auto; transition: transform .5s var(--ease); }
.post-card:hover .post-media img { transform: scale(1.03); }

.post-body { padding: 24px 26px 28px; }
.post-date {
  font-size: 12.5px; letter-spacing: .08em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 10px;
}
.post-title {
  font-family: var(--serif);
  font-weight: 500; font-size: 24px; line-height: 1.2;
  margin-bottom: 12px;
}
.post-title a { text-decoration: none; }
.post-title a:hover { color: var(--accent); }
.post-excerpt { font-size: 15.5px; color: var(--ink-soft); margin: 0; }

/* Article */
.article { padding: clamp(30px, 4vw, 52px) 0 clamp(56px, 7vw, 90px); }
.article-back { font-size: 14.5px; margin-bottom: 34px; }
.article-back a { color: var(--ink-muted); text-decoration: none; }
.article-back a:hover { color: var(--accent); }

.article-date {
  font-size: 12.5px; letter-spacing: .1em; text-transform: uppercase;
  color: var(--accent); margin-bottom: 14px;
}
.article-title {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(31px, 4.2vw, 50px);
  line-height: 1.08;
  letter-spacing: -.025em;
  margin-bottom: 18px;
}
.article-standfirst {
  font-family: var(--serif);
  font-style: italic;
  font-size: clamp(18px, 1.7vw, 21px);
  line-height: 1.5;
  color: var(--ink-soft);
  margin-bottom: 0;
}

.article-cover {
  margin: clamp(30px, 4vw, 46px) 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line);
}
.article-cover img { width: 100%; height: auto; }

/* Long-form body copy — wider measure and looser leading than the landing page. */
.prose { font-size: clamp(17px, 1.35vw, 18.5px); line-height: 1.75; }
.prose p { margin-bottom: 1.3em; color: var(--ink-soft); }
.prose p em { color: var(--ink); }
.prose h2 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(23px, 2.4vw, 29px);
  letter-spacing: -.02em;
  margin: 1.9em 0 .7em;
  color: var(--ink);
}
.prose .pull {
  font-family: var(--serif);
  font-size: clamp(20px, 2vw, 25px);
  line-height: 1.45;
  color: var(--ink);
  border-left: 2px solid var(--accent);
  padding-left: 22px;
  margin: 1.8em 0;
}

.principles, .weeks { counter-reset: item; margin: 1.6em 0 1.9em; }
.principles li, .weeks li {
  counter-increment: item;
  position: relative;
  padding: 0 0 20px 46px;
}
.principles li::before, .weeks li::before {
  content: counter(item);
  position: absolute; left: 0; top: 1px;
  width: 28px; height: 28px;
  display: grid; place-items: center;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 13px; font-weight: 600;
}
.principle-name, .week-name {
  font-weight: 600;
  color: var(--ink);
  margin-bottom: 4px !important;
  font-size: 1.02em;
}
.principles li p:last-child, .weeks li p:last-child { margin-bottom: 0; }
[lang="hi"] { font-weight: 500; }

/* Table — must scroll on its own rather than push the page sideways. */
.table-scroll {
  overflow-x: auto;
  margin: 1.7em 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  -webkit-overflow-scrolling: touch;
}
.frame-table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 15px;
  text-align: left;
}
.frame-table th, .frame-table td {
  padding: 14px 18px;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}
.frame-table thead th {
  font-size: 12.5px; letter-spacing: .07em; text-transform: uppercase;
  color: var(--ink-muted);
  background: var(--paper-alt);
  white-space: nowrap;
}
.frame-table tbody th {
  font-family: var(--serif);
  font-size: 20px;
  font-weight: 500;
  color: var(--accent);
  white-space: nowrap;
}
.frame-table td { color: var(--ink-soft); }
.frame-table tr:last-child th, .frame-table tr:last-child td { border-bottom: 0; }
.frame-table .dash { color: var(--ink-muted); }

.article-foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 18px;
  margin-top: clamp(40px, 5vw, 60px);
  padding-top: 28px;
  border-top: 1px solid var(--line);
}
.article-origin { font-size: 14.5px; color: var(--ink-muted); margin: 0; }
.article-origin a { color: var(--accent); text-decoration: none; }
.article-origin a:hover { text-decoration: underline; }

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--line); padding-block: 30px; }
.footer-inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 14px;
  font-size: 14px; color: var(--ink-muted);
}
.footer-inner p { margin: 0; }
.to-top {
  display: inline-flex; align-items: center; gap: 7px;
  text-decoration: none;
  transition: color .2s var(--ease);
}
.to-top svg { width: 15px; height: 15px; }
.to-top:hover { color: var(--ink); }

/* ---------- Reveal on scroll ----------
   Gated on .js (set by the inline head script) so content stays visible
   if JavaScript is disabled or fails to load. */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
}
.js [data-reveal].is-visible { opacity: 1; transform: none; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero-grid,
  .about-grid,
  .exp-grid,
  .book-feature { grid-template-columns: 1fr; }

  .hero-portrait { order: -1; max-width: 340px; }
  .portrait-caption { text-align: left; }
  .site-nav { display: none; }
  .capability-list li { flex-direction: column; gap: 2px; }
  .capability-list em { text-align: left; }
}

@media (max-width: 560px) {
  body { font-size: 16px; }
  .wordmark-name { display: none; }
  .display br, .contact-title br { display: none; }
  .hero-stats { gap: 22px; }
  .hero-stats > div { flex: 1 1 40%; }
  .btn { flex: 1 1 auto; justify-content: center; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .js [data-reveal],
  .js [data-reveal] .hero-lines li { opacity: 1; transform: none; }
}

/* ---------- Print ---------- */
@media print {
  .site-header, .marquee, .theme-toggle, .site-footer, .hero-actions { display: none; }
  body { background: #fff; color: #000; }
  .section { padding-block: 24px; }
}
