*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg:        #0f0c09;
  --bg-2:      #161109;
  --bg-3:      #1c1510;
  --surface:   #231a12;
  --surface-2: #2d2218;
  --gold:      #b8965a;
  --gold-dim:  #7a6035;
  --gold-pale: #e8d5a8;
  --cream:     #f0e8d5;
  --cream-dim: #b8a888;
  --border:    rgba(184,150,90,0.22);
  --border-hi: rgba(184,150,90,0.48);
  --serif:     'Playfair Display', Georgia, serif;
  --body:      'Libre Baskerville', Georgia, serif;
  --mono:      'Inconsolata', monospace;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--cream);
  font-family: var(--body);
  font-size: 17px;
  line-height: 1.75;
  font-weight: 400;
  overflow-x: hidden;
}

/* GRAIN */
body::after {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: overlay;
}


/* NAV */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 500;
  display: flex; align-items: center; justify-content: space-between;
  padding: 1.75rem 5rem;
  background: linear-gradient(to bottom, rgba(15,12,9,0.97) 0%, transparent 100%);
}

.nav-mark {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  text-decoration: none;
}

.nav-links { display: flex; gap: 3rem; list-style: none; }

.nav-links a {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cream-dim);
  text-decoration: none;
  transition: color 0.25s;
}
.nav-links a:hover { color: var(--gold); }

/* HERO */
.hero {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 55% 45%;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  left: 55%; top: 15%; bottom: 15%;
  width: 1px;
  background: linear-gradient(to bottom, transparent, var(--gold-dim) 40%, var(--gold-dim) 60%, transparent);
}

.hero-left {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 10rem 5rem 8rem;
}

.hero-eyebrow {
  display: flex; align-items: center; gap: 1rem;
  margin-bottom: 2.5rem;
  opacity: 0;
  animation: rise 0.8s cubic-bezier(0.16,1,0.3,1) forwards 0.1s;
}

.eyebrow-line { width: 32px; height: 1px; background: var(--gold); }

.hero-eyebrow span {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold);
}

h1 {
  font-family: var(--serif);
  font-size: clamp(3.2rem, 5.5vw, 6rem);
  font-weight: 400;
  line-height: 1.0;
  letter-spacing: -0.015em;
  color: var(--cream);
  margin-bottom: 2.5rem;
  opacity: 0;
  animation: rise 0.9s cubic-bezier(0.16,1,0.3,1) forwards 0.25s;
}

h1 .ital { font-style: italic; color: var(--gold-pale); }
h1 .dim  { color: var(--cream-dim); }

.hero-role {
  font-family: var(--mono);
  font-size: 0.8rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cream-dim);
  margin-bottom: 2rem;
  opacity: 0;
  animation: rise 0.9s cubic-bezier(0.16,1,0.3,1) forwards 0.4s;
}
.hero-role strong { color: var(--cream); font-weight: 400; }

.hero-desc {
  font-size: 1rem;
  line-height: 1.95;
  color: rgba(185,165,135,0.9);
  max-width: 480px;
  margin-bottom: 3.5rem;
  opacity: 0;
  animation: rise 0.9s cubic-bezier(0.16,1,0.3,1) forwards 0.55s;
}
.hero-desc em { color: var(--cream); font-style: italic; font-family: var(--serif); font-size: 1.05rem; }

.hero-cta {
  display: flex; gap: 1.5rem; align-items: center;
  opacity: 0;
  animation: rise 0.9s cubic-bezier(0.16,1,0.3,1) forwards 0.7s;
}

.cta-main {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--bg);
  background: var(--gold);
  text-decoration: none;
  padding: 1rem 2.25rem;
  transition: background 0.25s, transform 0.2s;
}
.cta-main:hover { background: var(--gold-pale); transform: translateY(-2px); }

.cta-ghost {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cream-dim);
  text-decoration: none;
  border-bottom: 1px solid var(--border-hi);
  padding-bottom: 2px;
  transition: color 0.25s, border-color 0.25s;
}
.cta-ghost:hover { color: var(--gold); border-color: var(--gold); }

/* HERO PHOTO */
.hero-right {
  display: flex; align-items: flex-end; justify-content: center;
  opacity: 0;
  animation: fadeIn 1.2s ease forwards 0.5s;
}

.photo-wrap {
  position: relative;
  width: 78%;
  height: 88%;
}

.photo-wrap img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: top center;
  display: block;
  filter: sepia(25%) contrast(1.05) brightness(0.88);
  transition: filter 0.5s;
}
.photo-wrap img:hover { filter: sepia(8%) contrast(1.05) brightness(0.95); }


.photo-vignette {
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 45%;
  background: linear-gradient(to top, var(--bg) 0%, transparent 100%);
  z-index: 1;
}


/* SECTIONS */
.section { padding: 8rem 5rem; border-top: 1px solid var(--border); }

.s-label {
  display: flex; align-items: baseline; gap: 1.2rem;
  margin-bottom: 5rem;
}

.s-num {
  font-family: var(--mono);
  font-size: 1rem;
  color: var(--gold);
  letter-spacing: 0.15em;
}

.s-rule { flex: 1; height: 1px; background: var(--border); }

.s-title {
  font-family: var(--serif);
  font-size: clamp(1.8rem, 3vw, 2.8rem);
  font-weight: 400;
  color: var(--cream);
}

/* ABOUT */
.about { background: var(--bg); }

.about-inner {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7rem;
}

.about-text p {
  font-size: 1rem;
  line-height: 1.95;
  color: rgba(185,165,135,0.9);
  margin-bottom: 1.75rem;
}
.about-text p em { font-style: italic; font-family: var(--serif); color: var(--cream); font-size: 1.05rem; }
.about-text p strong { color: var(--cream); font-weight: 700; }

.aside-row {
  display: grid;
  grid-template-columns: 110px 1fr;
  gap: 1.5rem;
  padding: 1.4rem 0;
  border-bottom: 1px solid var(--border);
}
.aside-row:first-child { border-top: 1px solid var(--border); }

.aside-key {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold-dim);
  padding-top: 0.15rem;
}

.aside-val { font-size: 0.95rem; color: var(--cream-dim); line-height: 1.65; }
.aside-val a { color: var(--cream-dim); text-decoration: none; border-bottom: 1px solid var(--border); transition: color 0.2s, border-color 0.2s; }
.aside-val a:hover { color: var(--gold); border-color: var(--gold); }

/* EXPERIENCE */
.experience { background: var(--bg-2); }

.exp-item {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 3rem;
  padding: 3rem 0;
  transition: background 0.25s;
}
.exp-item:hover { background: rgba(160,130,80,0.07); }


.exp-period {
  font-family: var(--mono);
  font-size: 0.88rem;
  letter-spacing: 0.12em;
  color: var(--gold-dim);
  display: block;
  margin-bottom: 0.6rem;
  padding-top: 0.3rem;
}

.exp-loc {
  font-family: var(--mono);
  font-size: 0.78rem;
  letter-spacing: 0.1em;
  color: rgba(160,130,80,0.75);
  display: block;
}

.exp-role { font-family: var(--serif); font-size: 1.55rem; font-weight: 400; color: var(--cream); margin-bottom: 0.4rem; }
.exp-company { font-family: var(--mono); font-size: 0.72rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--gold); margin-bottom: 1.25rem; }

.exp-desc { font-size: 0.95rem; line-height: 1.95; color: rgba(185,165,135,0.85); max-width: 580px; margin-bottom: 1.5rem; }

.exp-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.chip {
  font-family: var(--mono);
  font-size: 0.66rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold-dim);
  border: 1px solid rgba(184,150,90,0.2);
  padding: 0.35rem 0.9rem;
  transition: border-color 0.2s, color 0.2s;
}
.chip:hover { border-color: var(--gold); color: var(--gold); }

/* TIMELINE */
.exp-item > div:first-child {
  position: relative;
  padding-left: 1.5rem;
}

/* Dot marker — hollow for all entries, transitions for hover */
.exp-item > div:first-child::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.8rem;
  width: 9px; height: 9px;
  border-radius: 50%;
  border: 1px solid var(--gold-dim);
  background: var(--bg-2);
  z-index: 1;
  transition: background 0.25s, border-color 0.25s, box-shadow 0.25s;
}

/* Connecting line — 2px, bridges the 3rem bottom padding + 1px border + 3rem top padding gap */
.exp-item > div:first-child::after {
  content: '';
  position: absolute;
  left: 3.5px;
  top: calc(0.8rem + 9px);
  bottom: calc(-6rem - 1px);
  width: 2px;
  background: var(--border);
  z-index: 0;
}

/* Hover — fill dot with the location text colour */
.exp-item:not(:first-child):hover > div:first-child::before {
  background: rgba(160,130,80,0.75);
  border-color: rgba(160,130,80,0.75);
  box-shadow: 0 0 6px rgba(160,130,80,0.25);
}

/* No line below the final entry */
.exp-item:last-child > div:first-child::after {
  display: none;
}

/* Current role — filled gold dot with slow pulse */
.exp-item:first-child > div:first-child::before {
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(184,150,90,0.12), 0 0 10px rgba(184,150,90,0.25);
  animation: pulse-dot 2.8s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 3px rgba(184,150,90,0.12), 0 0 10px rgba(184,150,90,0.25); }
  50%       { box-shadow: 0 0 0 6px rgba(184,150,90,0.05), 0 0 18px rgba(184,150,90,0.10); }
}

/* SKILLS */
.skills { background: var(--bg-3); }

.skills-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border: 1px solid var(--border);
}

.skill-cell {
  padding: 2.75rem;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transition: background 0.3s;
}
.skill-cell:hover { background: rgba(184,150,90,0.04); }
.skill-cell:nth-child(3n) { border-right: none; }
.skill-cell:nth-child(n+4) { border-bottom: none; }

.skill-heading {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.5rem;
  display: flex; align-items: center; gap: 0.75rem;
}
.skill-heading::after { content: ''; flex: 1; height: 1px; background: var(--border); }

.skill-items { list-style: none; display: flex; flex-direction: column; gap: 0.7rem; }

.skill-items li {
  font-size: 0.92rem;
  color: var(--cream-dim);
  display: flex; align-items: center; gap: 0.75rem;
  transition: color 0.2s;
}
.skill-items li:hover { color: var(--cream); }
.skill-items li::before { content: ''; width: 3px; height: 3px; background: var(--gold-dim); flex-shrink: 0; }

/* PROJECTS */
.projects { background: var(--bg-2); }

.projects-soon {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 5rem 0 2rem;
  max-width: 560px;
  margin: 0 auto;
}

.projects-eyebrow {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-dim);
  margin-bottom: 2rem;
  display: flex; align-items: center; gap: 1rem;
}
.projects-eyebrow::before,
.projects-eyebrow::after { content: ''; width: 40px; height: 1px; background: var(--border-hi); }

.projects-heading {
  font-family: var(--serif);
  font-size: clamp(2.2rem, 5vw, 3.8rem);
  font-weight: 400;
  font-style: italic;
  color: var(--cream);
  margin-bottom: 1.75rem;
}

.projects-body {
  font-size: 1rem;
  line-height: 1.95;
  color: rgba(185,165,135,0.85);
}

/* CONTACT */
.contact { background: var(--bg); text-align: center; padding: 9rem 5rem; }

.contact-super {
  font-family: var(--mono);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-dim);
  margin-bottom: 2rem;
  display: flex; align-items: center; justify-content: center; gap: 1rem;
}
.contact-super::before, .contact-super::after { content: ''; width: 40px; height: 1px; background: var(--border-hi); }

.contact-title {
  font-family: var(--serif);
  font-size: clamp(2.8rem, 6vw, 5.5rem);
  font-weight: 400;
  line-height: 1.05;
  color: var(--cream);
  margin-bottom: 1.75rem;
}
.contact-title em { font-style: italic; color: var(--gold-pale); }

.contact-body {
  font-size: 1rem;
  color: rgba(185,165,135,0.85);
  margin-bottom: 3.5rem;
  max-width: 460px;
  margin-left: auto; margin-right: auto;
  line-height: 1.9;
}

.contact-actions { display: flex; gap: 1.25rem; justify-content: center; flex-wrap: wrap; }

.c-btn {
  font-family: var(--mono);
  font-size: 0.74rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  text-decoration: none;
  padding: 1rem 2.5rem;
  transition: all 0.25s;
  display: inline-block;
}
.c-btn-fill { background: var(--gold); color: var(--bg); }
.c-btn-fill:hover { background: var(--gold-pale); transform: translateY(-2px); }
.c-btn-outline { border: 1px solid var(--border-hi); color: var(--cream-dim); }
.c-btn-outline:hover { border-color: var(--gold); color: var(--gold); }

/* FOOTER */
footer {
  padding: 2rem 5rem;
  border-top: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center;
  background: var(--bg);
}

.foot-copy, .foot-right {
  font-family: var(--mono);
  font-size: 0.68rem;
  letter-spacing: 0.14em;
  color: rgba(140,110,60,0.55);
}

/* REVEAL */
.reveal { opacity: 0; transform: translateY(22px); transition: opacity 0.75s ease, transform 0.75s ease; }
.reveal.in { opacity: 1; transform: none; }

/* KEYFRAMES */
@keyframes rise {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: none; }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

/* MOBILE */
@media (max-width: 960px) {
  nav { padding: 1.5rem 2rem; }
  .nav-links { gap: 1.75rem; }
  .hero { grid-template-columns: 1fr; }
  .hero::before { display: none; }
  .hero-left { padding: 9rem 2rem 4rem; }
  .hero-right { height: 72vw; }
  .photo-wrap { width: 88%; height: 100%; }
  .section { padding: 5rem 2rem; }
  .about-inner { grid-template-columns: 1fr; gap: 3.5rem; }
  .exp-item { grid-template-columns: 1fr; gap: 1rem; }
  .exp-item > div:first-child { padding-left: 0; }
  .exp-item > div:first-child::before,
  .exp-item > div:first-child::after { display: none; }
  .skills-grid { grid-template-columns: 1fr 1fr; }
  .skill-cell { padding: 1.75rem 1.5rem; }
  .skill-cell:nth-child(3n) { border-right: 1px solid var(--border); }
  .skill-cell:nth-child(2n) { border-right: none; }
  .skill-cell:nth-child(n+4) { border-bottom: 1px solid var(--border); }
  .skill-cell:nth-child(n+5) { border-bottom: none; }
  .contact { padding: 6rem 2rem; }
  footer { padding: 1.5rem 2rem; flex-direction: column; gap: 0.5rem; }
}

/* SMALL MOBILE */
@media (max-width: 480px) {
  nav { padding: 1.25rem 1.25rem; }
  .nav-links { gap: 1rem; }
  .nav-links a { font-size: 0.65rem; letter-spacing: 0.1em; }
  .skills-grid { grid-template-columns: 1fr; }
  .skill-cell { padding: 1.5rem 1.25rem; }
  .skill-cell:nth-child(n) { border-right: none; border-bottom: 1px solid var(--border); }
  .skill-cell:last-child { border-bottom: none; }
}
