:root {
  --bg: #0d0d0f;
  --bg-soft: #16161a;
  --fg: #ece9e4;
  --muted: #9a968f;
  --line: #2a2a30;
  --accent: #d8a24a;
  --maxw: 1280px;
  --display: "Fraunces", Georgia, "Times New Roman", serif;
  --body: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--body);
  font-weight: 300;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}
h1, h2 { font-family: var(--display); font-weight: 500; letter-spacing: -0.01em; }
a { color: inherit; text-decoration: none; }

/* ---------- top bar ---------- */
.topbar {
  position: sticky; top: 0; z-index: 50;
  display: flex; align-items: center; justify-content: space-between;
  padding: 16px clamp(20px, 5vw, 64px);
  background: rgba(13, 13, 15, 0.72);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}
.brand { font-family: var(--display); font-size: 1.1rem; letter-spacing: 0.01em; }
.topnav a { margin-left: 28px; font-size: 0.88rem; color: var(--muted); transition: color .2s; }
.topnav a:hover { color: var(--fg); }

/* ---------- hero ---------- */
.hero {
  min-height: 78vh;
  display: flex; align-items: center;
  padding: 0 clamp(20px, 5vw, 64px);
  background:
    radial-gradient(60% 80% at 70% 20%, rgba(216,162,74,0.10), transparent 60%),
    radial-gradient(50% 60% at 15% 90%, rgba(120,90,200,0.10), transparent 60%);
}
.hero-inner { max-width: 760px; }
.hero h1 { font-size: clamp(2.8rem, 8vw, 6rem); line-height: 1.02; margin: 0 0 .2em; }
.tagline { color: var(--accent); font-size: clamp(.95rem, 2vw, 1.15rem); letter-spacing: .14em; text-transform: uppercase; margin: 0 0 1.4em; }
.lede { font-size: clamp(1.05rem, 2.2vw, 1.35rem); color: #cfccc6; max-width: 38ch; margin: 0 0 2em; }
.scroll-cue { font-size: .9rem; color: var(--muted); border-bottom: 1px solid var(--line); padding-bottom: 3px; transition: color .2s, border-color .2s; }
.scroll-cue:hover { color: var(--fg); border-color: var(--accent); }

/* ---------- work ---------- */
.work { padding: clamp(48px, 8vw, 110px) clamp(20px, 5vw, 64px); max-width: var(--maxw); margin: 0 auto; }
.work-head { display: flex; flex-wrap: wrap; gap: 20px; align-items: baseline; justify-content: space-between; margin-bottom: 36px; }
.work-head h2 { font-size: clamp(1.6rem, 4vw, 2.4rem); margin: 0; }
.filters { display: flex; flex-wrap: wrap; gap: 8px; }
.pill {
  font-family: var(--body); font-size: .85rem; color: var(--muted);
  background: transparent; border: 1px solid var(--line);
  padding: 8px 16px; border-radius: 999px; cursor: pointer;
  transition: all .2s;
}
.pill:hover { color: var(--fg); border-color: var(--muted); }
.pill.is-active { color: var(--bg); background: var(--fg); border-color: var(--fg); }

/* masonry via columns */
.grid { column-count: 3; column-gap: 18px; }
@media (max-width: 900px) { .grid { column-count: 2; } }
@media (max-width: 560px) { .grid { column-count: 1; } }

.card {
  position: relative; break-inside: avoid; margin-bottom: 18px;
  border-radius: 10px; overflow: hidden; cursor: pointer;
  background: var(--bg-soft); border: 1px solid var(--line);
  opacity: 0; transform: translateY(12px);
  animation: rise .5s ease forwards;
}
@keyframes rise { to { opacity: 1; transform: none; } }
.card img { display: block; width: 100%; height: auto; transition: transform .5s ease; }
.card:hover img { transform: scale(1.04); }
.card .overlay {
  position: absolute; inset: auto 0 0 0;
  padding: 28px 16px 14px;
  background: linear-gradient(transparent, rgba(0,0,0,.82));
  opacity: 0; transition: opacity .3s;
}
.card:hover .overlay { opacity: 1; }
.card .overlay .t { font-family: var(--display); font-size: 1rem; display: block; }
.card .overlay .c { font-size: .8rem; color: var(--muted); }
.empty-note { color: var(--muted); text-align: center; padding: 40px 0; font-style: italic; }

/* ---------- about / contact ---------- */
.about, .contact { padding: clamp(40px, 6vw, 90px) clamp(20px, 5vw, 64px); max-width: 760px; margin: 0 auto; border-top: 1px solid var(--line); }
.about h2, .contact h2 { font-size: clamp(1.4rem, 3vw, 2rem); margin: 0 0 .6em; }
.about p { font-size: 1.1rem; color: #cfccc6; }
.contact a { border-bottom: 1px solid var(--line); transition: border-color .2s; }
.contact a:hover { border-color: var(--accent); }
.contact .social { color: var(--muted); margin-top: .4em; }

.footer { padding: 40px; text-align: center; color: var(--muted); font-size: .82rem; border-top: 1px solid var(--line); }

/* ---------- lightbox ---------- */
.lightbox {
  position: fixed; inset: 0; z-index: 100;
  display: flex; align-items: center; justify-content: center;
  background: rgba(8,8,10,.96); padding: 4vh 6vw;
}
.lightbox[hidden] { display: none; }
.lb-figure { margin: 0; max-width: 90vw; max-height: 92vh; display: flex; flex-direction: column; align-items: center; }
.lb-figure img { max-width: 100%; max-height: 84vh; object-fit: contain; border-radius: 4px; }
.lb-figure figcaption { margin-top: 14px; text-align: center; color: var(--fg); font-family: var(--display); font-size: 1rem; }
.lb-figure figcaption .c { display: block; font-family: var(--body); font-size: .85rem; color: var(--muted); margin-top: 3px; }
.lb-close, .lb-nav {
  position: absolute; background: none; border: none; color: var(--fg);
  cursor: pointer; opacity: .7; transition: opacity .2s;
}
.lb-close:hover, .lb-nav:hover { opacity: 1; }
.lb-close { top: 22px; right: 28px; font-size: 2.4rem; line-height: 1; }
.lb-nav { top: 50%; transform: translateY(-50%); font-size: 3.2rem; padding: 0 18px; }
.lb-prev { left: 1vw; }
.lb-next { right: 1vw; }
@media (max-width: 560px) { .lb-nav { font-size: 2.2rem; padding: 0 6px; } }
