/* timothyverhaeghe.com: calm, warm, editorial. One accent (ochre, from the bridge in the photo). */

:root {
  --bg: #faf8f4;
  --surface: #ffffff;
  --ink: #1f1c18;
  --text: #3a3530;
  --muted: #7a7168;
  --line: #e9e3da;
  --accent: #a87a2a;
  --accent-soft: #f3ead9;
  --danger: #b4432f;
  --serif: "Newsreader", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --page: 1080px;
  --text-width: 640px;
  --radius: 14px;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--ink); text-decoration-color: var(--line); text-underline-offset: 3px; transition: text-decoration-color .2s, color .2s; }
a:hover { text-decoration-color: var(--accent); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 500; color: var(--ink); letter-spacing: -0.01em; line-height: 1.2; margin: 0 0 .6em; }
h1 { font-size: 40px; }
h1.hero { font-size: clamp(40px, 6vw, 60px); line-height: 1.08; }
h2 { font-size: 28px; }
h3 { font-size: 20px; }
p { margin: 0 0 1.1em; }
.lead { font-size: 19px; color: var(--text); line-height: 1.65; }
.muted { color: var(--muted); }

/* Layout */
.wrap { max-width: var(--page); margin: 0 auto; padding: 0 24px; }
.text { max-width: var(--text-width); }
main { padding: 56px 0 96px; }
section + section { margin-top: 88px; }

/* Header */
.site-header { padding: 28px 0; }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand { white-space: nowrap; font-family: var(--serif); font-size: 20px; color: var(--ink); text-decoration: none; font-weight: 500; }
.nav { display: flex; gap: 28px; }
.nav a { font-size: 15px; color: var(--muted); text-decoration: none; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 40px 0 48px; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 16px; }
.site-footer nav { display: flex; gap: 24px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--ink); }
.star { background: none; border: 0; padding: 0 2px; margin-left: 4px; color: var(--line); cursor: pointer; font-size: 13px; transition: color .3s; }
.star:hover { color: var(--accent); }

/* Home */
.intro { display: grid; grid-template-columns: 1.25fr 1fr; gap: 64px; align-items: center; }
.portrait { border-radius: 20px; aspect-ratio: 4 / 5; object-fit: cover; object-position: 50% 20%; width: 100%; box-shadow: 0 30px 60px -30px rgba(60, 40, 10, .35); }
.actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }

.cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.card { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; }
.card h3 { margin-bottom: .4em; }
.card p { margin: 0; font-size: 15px; color: var(--muted); }
.card a.more { display: inline-block; margin-top: 14px; font-size: 15px; }

.logos { display: flex; flex-wrap: wrap; gap: 12px 36px; font-family: var(--serif); font-size: 21px; color: var(--muted); }

/* Buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; font: 500 15px/1 var(--sans); padding: 14px 22px; border-radius: 999px; border: 1px solid var(--ink); background: var(--ink); color: var(--bg); text-decoration: none; cursor: pointer; transition: background .2s, color .2s, border-color .2s; }
.btn:hover { background: #000; }
.btn.secondary { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.secondary:hover { border-color: var(--ink); }
.btn[disabled] { opacity: .6; cursor: default; }

/* Timeline (About) */
.timeline { list-style: none; padding: 0; margin: 0; border-left: 1px solid var(--line); }
.timeline li { position: relative; padding: 0 0 36px 28px; }
.timeline li::before { content: ""; position: absolute; left: -5px; top: 9px; width: 9px; height: 9px; border-radius: 50%; background: var(--bg); border: 2px solid var(--accent); }
.timeline h3 { margin-bottom: .3em; }
.timeline p { margin: 0; }

/* Form */
.form { display: grid; gap: 22px; max-width: var(--text-width); }
.field label { display: block; font-weight: 500; color: var(--ink); font-size: 15px; }
.field .hint { display: block; font-size: 14px; color: var(--muted); margin: 2px 0 8px; }
.field input, .field select, .field textarea {
  width: 100%; font: 16px/1.5 var(--sans); color: var(--ink);
  background: var(--surface); border: 1px solid var(--line); border-radius: 10px; padding: 12px 14px;
  transition: border-color .2s, box-shadow .2s;
}
.field textarea { min-height: 160px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
.form .error { color: var(--danger); font-size: 15px; margin: 0; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Legal pages */
.legal h2 { font-size: 22px; margin-top: 2em; }
.legal ul { padding-left: 20px; margin: 0 0 1.1em; }
.legal li { margin-bottom: .4em; }

/* Modal */
.modal { position: fixed; inset: 0; display: none; align-items: center; justify-content: center; padding: 24px; background: rgba(31, 28, 24, .35); z-index: 50; }
.modal.open { display: flex; }
.modal-box { background: var(--surface); border-radius: 18px; max-width: 440px; width: 100%; padding: 32px; box-shadow: 0 30px 80px -20px rgba(0,0,0,.35); }
.modal-box h2 { font-size: 24px; }
.modal-box p { color: var(--muted); }

/* 404 */
.notfound { text-align: center; padding: 64px 0; }
.notfound .text { margin: 0 auto; }

/* Easter egg: the crawl */
.crawl { position: fixed; inset: 0; z-index: 100; background: #000; display: none; overflow: hidden; perspective: 380px; cursor: pointer; }
.crawl.open { display: block; }
.crawl::before { content: ""; position: absolute; inset: 0; background-image: radial-gradient(1px 1px at 20% 30%, #fff, transparent), radial-gradient(1px 1px at 70% 60%, #fff, transparent), radial-gradient(1px 1px at 40% 80%, #ddd, transparent), radial-gradient(1px 1px at 85% 20%, #fff, transparent), radial-gradient(1px 1px at 10% 70%, #ccc, transparent); background-size: 260px 260px; opacity: .7; }
.crawl-text { position: absolute; left: 50%; width: min(620px, 90vw); bottom: 0; transform-origin: 50% 100%; transform: translateX(-50%) rotateX(24deg); color: #f5c518; font-family: var(--sans); font-weight: 600; font-size: 22px; line-height: 1.5; text-align: justify; animation: crawl 60s linear forwards; }
.crawl-text h2 { color: #f5c518; font-family: var(--sans); text-align: center; font-weight: 700; letter-spacing: .08em; }
.crawl-hint { position: absolute; top: 16px; right: 20px; color: #888; font-size: 13px; z-index: 1; }
@keyframes crawl { from { transform: translateX(-50%) rotateX(24deg) translateY(20%); } to { transform: translateX(-50%) rotateX(24deg) translateY(-260%); } }

@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
  .crawl-text { animation: none; transform: translateX(-50%); position: relative; bottom: auto; top: 40px; margin: 0 auto; }
  .crawl { overflow: auto; perspective: none; }
}

@media (max-width: 860px) {
  .intro { grid-template-columns: 1fr; gap: 36px; }
  .portrait { max-width: 420px; aspect-ratio: 1 / 1; }
  .cards { grid-template-columns: 1fr; }
  main { padding: 32px 0 72px; }
  section + section { margin-top: 64px; }
  h1 { font-size: 34px; }
}
@media (max-width: 520px) {
  .wrap { padding: 0 16px; }
  .nav { gap: 16px; }
  .nav a { font-size: 14px; }
  .brand { font-size: 17px; }
  .lead { font-size: 18px; }
}
