:root {
  --paper: #f3f0e9;
  --ink: #141414;
  --soft: #8a867d;
  --rule: rgba(20, 20, 20, 0.14);
  --pad: clamp(16px, 4vw, 56px);
  --serif: 'Instrument Serif', Georgia, serif;
  --sans: 'Inter Tight', system-ui, sans-serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
h1, h2, h3, p { margin: 0; font-weight: 400; }
em { font-family: var(--serif); font-style: italic; font-weight: 400; letter-spacing: -0.01em; }

.tag {
  display: inline-block;
  font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--soft);
}

/* Masked line reveals */
.line { display: block; overflow: hidden; padding-bottom: 0.08em; }
.line > span { display: inline-block; }

/* Cursor (mouse only) */
.cursor {
  position: fixed; top: 0; left: 0; z-index: 80;
  width: 10px; height: 10px; margin: -5px 0 0 -5px;
  border-radius: 50%; background: #fff; mix-blend-mode: difference;
  pointer-events: none; display: none; opacity: 0;
  transition: width .3s, height .3s, margin .3s, opacity .3s;
}
.cursor.on { opacity: 1; }
.cursor.big { width: 56px; height: 56px; margin: -28px 0 0 -28px; }
@media (hover: hover) and (pointer: fine) { .cursor { display: block; } }

/* Nav: always visible, wraps on phones */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 50;
  display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center;
  gap: 6px 20px;
  padding: 18px var(--pad);
  color: #fff; mix-blend-mode: difference;
  font-size: 15px;
}
.brand { font-weight: 500; }
.nav-links { display: flex; gap: 22px; }
.nav-links a { padding: 6px 0; background: linear-gradient(currentColor, currentColor) 0 100% / 0 1px no-repeat; transition: background-size .35s; }
.nav-links a:hover { background-size: 100% 1px; }

/* 1. Hero */
.hero {
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; justify-content: flex-end;
  padding: 120px var(--pad) 40px;
  position: relative;
}
.hero > .headline, .hero > .hero-foot { position: relative; z-index: 1; }
.field {
  position: absolute; inset: 0; width: 100%; height: 100%;
  -webkit-mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 72%);
          mask-image: linear-gradient(to bottom, #000 0%, #000 45%, transparent 72%);
}
.headline {
  font-size: clamp(52px, 11.5vw, 190px);
  line-height: 0.92;
  letter-spacing: -0.045em;
  font-weight: 500;
}
.headline em { font-size: 1.08em; letter-spacing: -0.02em; }
.hero-foot {
  display: flex; justify-content: space-between; align-items: flex-end; gap: 24px;
  margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--rule);
}
.hero-foot p { font-size: 15px; line-height: 1.5; color: var(--soft); }
.badge { width: clamp(96px, 11vw, 140px); height: auto; flex-shrink: 0; }
.badge text { font-size: 15.5px; letter-spacing: 0.18em; text-transform: uppercase; fill: var(--ink); font-family: var(--sans); }

/* "alive." scramble */
.alive { display: inline-block; }
.al { display: inline-block; text-align: center; }

/* 2. About */
.about {
  display: grid; grid-template-columns: 200px 1fr; gap: 24px;
  padding: 26vh var(--pad);
}
.about-text { display: contents; }
.reveal-words {
  font-size: clamp(26px, 3.8vw, 56px);
  line-height: 1.12; letter-spacing: -0.03em;
  max-width: 24ch;
}
.reveal-words .w { opacity: 0.16; }

/* About timeline */
.ab-extra { grid-column: 2; margin-top: 56px; }
.timeline { list-style: none; margin: 0; padding: 0 0 0 28px; position: relative; }
.timeline::before { content: ""; position: absolute; left: 5px; top: 6px; bottom: 6px; width: 1px; background: var(--rule); }
.timeline .bar { position: absolute; left: 5px; top: 6px; width: 1px; height: calc(100% - 12px); background: #0891b2; transform-origin: top; transform: scaleY(0); }
.timeline li { position: relative; padding: 0 0 34px; display: flex; flex-direction: column; gap: 6px; }
.timeline li::before { content: ""; position: absolute; left: -28px; top: 4px; width: 11px; height: 11px; border-radius: 50%; background: var(--paper); border: 1px solid var(--soft); transition: background .3s, border-color .3s; }
.timeline li.lit::before { background: #0891b2; border-color: #0891b2; }
.timeline b { font-weight: 500; font-size: clamp(20px, 2.2vw, 30px); letter-spacing: -0.02em; }

/* 3. Faith */
.faith {
  height: 100vh; height: 100svh;
  display: flex; align-items: center; justify-content: center;
  background: var(--ink); color: var(--paper);
  text-align: center; overflow: hidden;
  padding: 0 var(--pad);
}
.faith .tag { color: rgba(243, 240, 233, 0.5); }
.faith-big {
  font-size: clamp(72px, 17vw, 280px);
  line-height: 0.95;
  margin: 18px 0 22px;
}
.faith-sub { font-size: clamp(16px, 1.6vw, 21px); color: rgba(243, 240, 233, 0.7); }
.faith { position: relative; }
.faith-inner { position: relative; z-index: 2; }
.faith-verse { margin: 28px auto 0; max-width: 30ch; font-family: var(--serif); font-style: italic; font-size: clamp(20px, 2.4vw, 32px); color: rgba(243, 240, 233, 0.85); }
.faith-verse small { display: block; margin-top: 10px; font-family: var(--sans); font-style: normal; font-size: 12px; letter-spacing: .12em; text-transform: uppercase; color: rgba(243, 240, 233, 0.5); }
.faith-link {
  display: inline-flex; align-items: center; gap: 8px; margin-top: 30px;
  padding: 12px 20px; border: 1px solid rgba(243,240,233,.3); border-radius: 999px;
  font-size: 15px; color: var(--paper); transition: background .3s, color .3s;
}
.faith-link:hover { background: var(--paper); color: var(--ink); }

/* 4. Work */
.work { padding: 22vh var(--pad) 10vh; }
.work-head { display: flex; flex-direction: column; gap: 14px; margin-bottom: 8vh; }
.work-head h2 { font-size: clamp(38px, 6vw, 92px); letter-spacing: -0.04em; line-height: 1; font-weight: 500; }
.work-more { display: inline-flex; align-items: center; gap: 8px; margin-top: 7vh; font-size: 16px; border-bottom: 1px solid currentColor; padding-bottom: 4px; }

/* Work list */
.wk-list { list-style: none; margin: 0; padding: 0; border-bottom: 1px solid var(--rule); }
.wk-list li { border-top: 1px solid var(--rule); }
.wk-list a { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 16px; padding: 28px 0; transition: opacity .3s; }
.wk-list h3 { font-size: clamp(30px, 5vw, 76px); letter-spacing: -0.045em; line-height: 1; font-weight: 500; transition: transform .45s cubic-bezier(.2,.8,.2,1); }
.wk-list p { font-size: 14px; color: var(--soft); text-align: right; }
.wk-list .thumb { display: none; }
.wk-list:hover a { opacity: .3; }
.wk-list a:hover { opacity: 1; }
.wk-list a:hover h3 { transform: translateX(24px); }
.wk-float { position: fixed; top: 0; left: 0; z-index: 40; width: 380px; height: 250px; margin: -125px 0 0 -190px; pointer-events: none; border-radius: 10px; overflow: hidden; opacity: 0; transform: scale(.7); box-shadow: 0 30px 60px -20px rgba(20,20,20,.45); }
.wk-float img { width: 100%; display: block; }

/* Latest writing (home) */
.home-writing { padding: 16vh var(--pad) 6vh; }
.hw-head { display: flex; flex-direction: column; gap: 14px; margin-bottom: 6vh; }
.hw-head h2 { font-size: clamp(38px, 6vw, 92px); letter-spacing: -0.04em; line-height: 1; font-weight: 500; }

/* 5. Contact */
.contact { min-height: 100vh; display: flex; flex-direction: column; padding: 20vh var(--pad) 32px; position: relative; overflow: hidden; }
.ct-panel { flex: 1; }
.big-link { display: block; font-size: clamp(56px, 13vw, 210px); line-height: 0.92; letter-spacing: -0.05em; font-weight: 500; }
.big-link em { letter-spacing: -0.02em; }
.big-link .line:last-child > span { background: linear-gradient(currentColor, currentColor) 0 92% / 0 3px no-repeat; transition: background-size .6s cubic-bezier(.2,.8,.2,1); }
.big-link:hover .line:last-child > span { background-size: 100% 3px; }
.ct-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 44px; }
.pill { font: inherit; font-size: 16px; display: inline-flex; align-items: center; gap: 10px; padding: 15px 24px; min-height: 48px; border-radius: 999px; border: 1px solid var(--rule); background: none; color: var(--ink); cursor: pointer; transition: background .3s, color .3s, transform .3s; }
.pill:hover { transform: translateY(-2px); }
.pill.dark { background: var(--ink); color: var(--paper); border-color: var(--ink); }

.contact-foot { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px 32px; margin-top: 12vh; padding-top: 20px; border-top: 1px solid var(--rule); font-size: 15px; }
.socials { display: flex; flex-wrap: wrap; gap: 8px 26px; color: var(--soft); }
.socials a:hover { color: var(--ink); }
.foot { margin-top: 20px; font-size: 12px; color: var(--soft); }
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 90; transform: translate(-50%, 20px); opacity: 0; pointer-events: none; background: var(--ink); color: var(--paper); padding: 12px 20px; border-radius: 999px; font-size: 15px; transition: opacity .3s, transform .3s; }
.toast.on { opacity: 1; transform: translate(-50%, 0); }

/* Phones */
@media (max-width: 720px) {
  .about { grid-template-columns: 1fr; padding: 18vh var(--pad); }
  .ab-extra { grid-column: 1; }
  .wk-list p { text-align: left; }
  .wk-list a { grid-template-columns: 1fr 64px; }
  .wk-list .thumb { display: block; grid-row: span 2; width: 64px; height: 48px; border-radius: 6px; overflow: hidden; border: 1px solid var(--rule); }
  .wk-list .thumb img { width: 100%; display: block; }
  .wk-list:hover a { opacity: 1; }
  .wk-list a:hover h3 { transform: none; }
  .hero-foot p { font-size: 14px; }
}

@media (prefers-reduced-motion: reduce) {
  .reveal-words .w { opacity: 1; }
}
