/* ---------- Design tokens ---------- */
:root {
  --cream: #faf5ee;
  --cream-deep: #f2e9dc;
  --ink: #2b241d;
  --ink-soft: #57493a;
  --terracotta: #b5563b;
  --terracotta-deep: #8f4028;
  --gold: #c99a4a;
  --line: rgba(43, 36, 29, 0.12);
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --max: 1080px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--cream);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 28px;
}

a { color: var(--terracotta-deep); }

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ---------- Header ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(250, 245, 238, 0.86);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 18px;
  padding-bottom: 18px;
}
.brand {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.25rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: 0.01em;
}
.nav {
  display: flex;
  gap: 28px;
}
.nav a {
  color: var(--ink-soft);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 500;
}
.nav a:hover { color: var(--terracotta-deep); }
.nav-cta {
  border: 1px solid var(--ink);
  padding: 8px 16px;
  border-radius: 999px;
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 500;
  color: var(--ink);
  white-space: nowrap;
}
.nav-cta:hover { background: var(--ink); color: var(--cream); }

@media (max-width: 720px) {
  .nav { display: none; }
}

/* ---------- Hero ---------- */
.hero { padding: 72px 0 90px; }
.hero-inner {
  display: grid;
  grid-template-columns: 1.3fr 0.9fr;
  gap: 56px;
  align-items: center;
}
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--terracotta-deep);
  margin: 0 0 18px;
}
.hero h1 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: clamp(2.2rem, 4.6vw, 3.4rem);
  line-height: 1.12;
  margin: 0 0 22px;
  color: var(--ink);
}
.lede {
  font-size: 1.08rem;
  color: var(--ink-soft);
  max-width: 46ch;
  margin: 0 0 32px;
}
.hero-actions { display: flex; gap: 14px; margin-bottom: 26px; flex-wrap: wrap; }
.hero-meta { font-size: 0.88rem; color: var(--ink-soft); opacity: 0.85; }

.hero-photo img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 50% 50% 48% 52% / 52% 48% 52% 48%;
  border: 1px solid var(--line);
  box-shadow: 0 30px 60px -30px rgba(43,36,29,0.35);
}

@media (max-width: 860px) {
  .hero-inner { grid-template-columns: 1fr; text-align: left; }
  .hero-photo { max-width: 240px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 13px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.92rem;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
}
.btn-primary {
  background: var(--terracotta);
  color: #fff9f2;
}
.btn-primary:hover { background: var(--terracotta-deep); }
.btn-ghost {
  border-color: var(--ink);
  color: var(--ink);
  background: transparent;
}
.btn-ghost:hover { background: var(--ink); color: var(--cream); }

/* ---------- Section scaffolding ---------- */
section { padding: 84px 0; }
.section-label {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.9rem;
  margin: 0 0 40px;
  color: var(--ink);
}
.subsection-label {
  font-family: var(--serif);
  font-size: 1.3rem;
  font-weight: 500;
  margin: 0 0 18px;
}

/* ---------- About ---------- */
.about { background: var(--cream-deep); border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.about-copy {
  font-size: 1.12rem;
  max-width: 68ch;
  color: var(--ink-soft);
}
.skill-row {
  list-style: none;
  padding: 0;
  margin: 32px 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px 12px;
}
.skill-row li {
  border: 1px solid var(--line);
  background: var(--cream);
  padding: 8px 16px;
  border-radius: 999px;
  font-size: 0.85rem;
  color: var(--ink-soft);
}

/* ---------- Work ---------- */
.work-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}
.work-card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 32px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.work-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 22px 44px -28px rgba(43,36,29,0.28);
}
.work-tag {
  text-transform: uppercase;
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  font-weight: 600;
  color: var(--gold);
  margin: 0 0 12px;
}
.work-card h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.28rem;
  margin: 0 0 12px;
  line-height: 1.32;
}
.work-card p { color: var(--ink-soft); margin: 0 0 10px; font-size: 0.98rem; }
.work-result {
  font-weight: 600;
  color: var(--terracotta-deep) !important;
}

@media (max-width: 780px) {
  .work-grid { grid-template-columns: 1fr; }
}

/* ---------- Experience ---------- */
.timeline {
  list-style: none;
  margin: 0 0 56px;
  padding: 0;
  border-top: 1px solid var(--line);
}
.timeline-item {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 32px;
  padding: 30px 0;
  border-bottom: 1px solid var(--line);
}
.timeline-when {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--ink);
}
.timeline-when span { display: block; font-weight: 400; color: var(--ink-soft); margin-top: 4px; }
.timeline-what h3 {
  font-family: var(--serif);
  font-weight: 500;
  font-size: 1.18rem;
  margin: 0 0 10px;
}
.timeline-what h3 span { font-family: var(--sans); font-weight: 400; font-size: 0.95rem; color: var(--ink-soft); }
.timeline-what p { color: var(--ink-soft); margin: 0; }

@media (max-width: 700px) {
  .timeline-item { grid-template-columns: 1fr; gap: 8px; }
}

.education-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
  margin-bottom: 44px;
}

.certifications { margin-bottom: 36px; }
.cert-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.cert-list li {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px 18px;
  font-size: 0.92rem;
  color: var(--ink-soft);
  background: #fff;
}
.cert-placeholder {
  font-style: italic;
  opacity: 0.75;
  border-style: dashed !important;
  background: transparent !important;
}
.ed-degree { font-weight: 600; margin: 0 0 4px; }
.ed-school { color: var(--ink-soft); margin: 0 0 6px; }
.ed-note { font-size: 0.85rem; color: var(--ink-soft); opacity: 0.85; margin: 0; }

@media (max-width: 700px) {
  .education-grid { grid-template-columns: 1fr; }
}

/* ---------- Contact ---------- */
.contact { background: var(--cream-deep); border-top: 1px solid var(--line); }
.contact-inner { max-width: 620px; }
.contact-lede { color: var(--ink-soft); margin: -16px 0 36px; }
.contact-form { display: flex; flex-direction: column; gap: 20px; margin-bottom: 36px; }
.form-row { display: flex; flex-direction: column; gap: 8px; }
.form-row label { font-size: 0.85rem; font-weight: 600; color: var(--ink); }
.form-row input, .form-row textarea {
  font-family: var(--sans);
  font-size: 1rem;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink);
  resize: vertical;
}
.form-row input:focus, .form-row textarea:focus {
  outline: none;
  border-color: var(--terracotta);
}
.hidden-field { position: absolute; left: -9999px; }
.contact-links { display: flex; flex-direction: column; gap: 6px; font-size: 0.95rem; }
.contact-links a { text-decoration: none; }
.contact-links a:hover { text-decoration: underline; }

.resume-btn { margin-top: 4px; }

/* ---------- Footer ---------- */
.site-footer {
  padding: 28px 0 40px;
  font-size: 0.82rem;
  color: var(--ink-soft);
  opacity: 0.8;
}
