﻿/* ─── Variables ─────────────────────────────────────────────────────── */
:root {
  --bg-dark:      #141210;
  --bg-light:     #F5F0EB;
  --text-primary: #1A1714;
  --text-muted:   #6B6460;
  --sidebar-w:    200px;

  --teal:   #1A9B96;
  --olive:  #5E5E2A;
  --purple: #3B1558;
  --wine:   #5C1228;
}

/* ─── Reset ─────────────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { font-size: 16px; }
body {
  font-family: 'Inter', sans-serif;
  background: var(--bg-dark);
  color: var(--text-primary);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; background: none; border: none; }

/* ─── Nav Toggle (bottom-centre trigger) ────────────────────────────── */
.nav-toggle {
  position: fixed;
  bottom: 2.2rem;
  left: 50%;
  transform: translateX(-50%);
  z-index: 400;
  width: 32px;
  height: 18px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 0;
  cursor: pointer;
  background: none;
  border: none;
}

.nav-toggle span {
  display: block;
  width: 100%;
  height: 1px;
  background: rgba(245, 240, 235, 0.4);
  transition: transform 0.35s ease, opacity 0.35s ease, background 0.25s ease;
}

.nav-toggle:hover span { background: rgba(245, 240, 235, 0.85); }

.nav-toggle.open span:nth-child(1) { transform: translateY(8.5px) rotate(45deg); }
.nav-toggle.open span:nth-child(2) { transform: translateY(-8.5px) rotate(-45deg); }

/* ─── Nav Overlay ───────────────────────────────────────────────────── */
.nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  z-index: 350;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
}

.nav-overlay.open {
  opacity: 1;
  pointer-events: auto;
}

/* ─── Nav Panel ─────────────────────────────────────────────────────── */
.nav-panel {
  position: fixed;
  left: 0;
  top: 0;
  height: 100vh;
  width: 280px;
  background: #0d0b0a;
  z-index: 400;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 3rem;
  transform: translateX(-100%);
  transition: transform 0.48s cubic-bezier(0.4, 0, 0.2, 1);
}

.nav-panel.open { transform: translateX(0); }

.nav-list {
  list-style: none;
  margin-bottom: 3rem;
}

.nav-list li { margin-bottom: 1.5rem; }

.nav-link {
  display: block;
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.18em;
  padding-left: 14px;
  border-left: 2px solid transparent;
  color: rgba(245, 240, 235, 0.3);
  transition: color 0.3s ease, border-color 0.3s ease;
}

.nav-link:hover { color: rgba(245, 240, 235, 0.85); }

.nav-link.active {
  color: rgba(245, 240, 235, 0.95);
}

.nav-contact-link {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.2em;
  color: rgba(245, 240, 235, 0.22);
  transition: color 0.25s ease;
}

.nav-contact-link:hover { color: rgba(245, 240, 235, 0.65); }

@media (max-width: 640px) {
  .nav-panel { width: 100%; }
}

/* ─── Hero Section ───────────────────────────────────────────────────── */
#hero {
  position: relative;
  height: 100vh;
  background: var(--bg-dark);
  display: grid;
  grid-template-columns: 55% 45%;
  overflow: hidden;
}

.hero-portrait-wrap {
  position: relative;
  overflow: hidden;
}

.hero-portrait {
  position: absolute;
  inset: 0;
  will-change: transform;
  background: linear-gradient(145deg, #232018 0%, #1A1814 40%, #141210 70%, #1C1816 100%);
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-portrait img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center top;
}

.hero-initials {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(5rem, 12vw, 10rem);
  font-weight: 300;
  color: rgba(245, 240, 235, 0.05);
  letter-spacing: 0.15em;
  user-select: none;
}

.hero-portrait:has(img) .hero-initials { display: none; }

.hero-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 4rem 4rem 4rem 3.5rem;
  position: relative;
  z-index: 2;
  will-change: opacity, transform;
}

.hero-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3.2rem, 5.5vw, 6rem);
  font-weight: 300;
  color: var(--bg-light);
  line-height: 1.05;
  letter-spacing: 0.02em;
}

.hero-rule {
  width: 52px;
  height: 2px;
  background: var(--teal);
  margin: 1.75rem 0 1.25rem;
}

.hero-subtitle {
  font-size: 10.5px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: rgba(245, 240, 235, 0.4);
  margin-bottom: 2.5rem;
}

.hero-bio {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(1.15rem, 1.8vw, 1.45rem);
  font-weight: 300;
  font-style: italic;
  color: rgba(245, 240, 235, 0.55);
  line-height: 1.65;
  max-width: 300px;
}

.scroll-indicator {
  position: absolute;
  bottom: 2.5rem;
  left: calc(55% / 2);
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.6rem;
  z-index: 3;
  transition: opacity 0.6s ease;
}

.scroll-indicator.hidden { opacity: 0; pointer-events: none; }

.scroll-indicator-text {
  font-size: 9.5px;
  text-transform: uppercase;
  letter-spacing: 0.22em;
  color: rgba(245, 240, 235, 0.25);
}

.scroll-dot {
  width: 5px; height: 5px;
  border-radius: 50%;
  background: rgba(245, 240, 235, 0.3);
  animation: bounce 2.2s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateY(0); }
  50%       { transform: translateY(9px); }
}

/* ─── Project Sections ───────────────────────────────────────────────── */
.project {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow: hidden;
  box-shadow: inset 0 10px 50px rgba(0, 0, 0, 0.45);
}

/* Shared image + info positioning base */
.pj-photo {
  position: absolute;
  margin: 0;
  overflow: hidden;
}

.pj-photo img {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Portrait / vertical hero — show the full image, accent gradient fills the gaps */
.pj-photo.portrait img {
  object-fit: contain;
  object-position: center;
}

.pj-info {
  position: absolute;
  padding: clamp(1rem, 3vw, 2.5rem);
  max-width: 44%;
}

/* Shared text elements */
.project-num {
  display: block;
  font-size: 10px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.25em;
  color: rgba(245, 240, 235, 0.45);
  margin-bottom: 0.75rem;
}

.project-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(2rem, 3.5vw, 3.5rem);
  font-weight: 300;
  color: var(--bg-light);
  letter-spacing: 0.04em;
  line-height: 1.1;
  margin-bottom: 2.5rem;
}

/* ── Layout 1: image top-left 65×68%, title bottom-right ─────────────── */
.layout-1 { background: var(--accent); }
.layout-1 {
  background: linear-gradient(135deg,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 25%, #141210) 100%);
}
.layout-1 .pj-photo { left: 0; top: 0; width: 65%; height: 68%; }
.layout-1 .pj-info  { right: 17.5%; bottom: 0; transform: translateX(50%); max-width: 30%; }

/* ── Layout 2: image right full-height 48%, title top-left ───────────── */
.layout-2 { background: var(--accent); }
.layout-2 {
  background: linear-gradient(to right,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 35%, #141210) 100%);
}
.layout-2 .pj-photo { right: 0; top: 0; width: 70%; height: 100%; }
.layout-2 .pj-info  { left: 15%; top: 0; transform: translateX(-50%); max-width: 26%; }

/* ── Layout 3: image right-anchored 62×62%, title left ───────────────── */
.layout-3 { background: var(--accent); }
.layout-3 {
  background: linear-gradient(160deg,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 22%, #141210) 100%);
}
.layout-3 .pj-photo { right: 0; top: 18%; width: 62%; height: 90%; }
.layout-3 .pj-info  { left: 19%; top: 0; transform: translateX(-50%); max-width: 34%; }

/* ── Layout 4: image left full-height 58%, title bottom-right ────────── */
.layout-4 { background: var(--accent); }
.layout-4 {
  background: linear-gradient(to right,
    color-mix(in srgb, var(--accent) 30%, #141210) 0%,
    var(--accent) 100%);
}
.layout-4 .pj-photo { left: 0; top: 0; width: 58%; height: 100%; }
.layout-4 .pj-info  { right: 21%; bottom: 0; transform: translateX(50%); max-width: 37%; }

/* ── Layout 5: image left/center 55×84%, title top-right ─────────────── */
/* gradient runs left→right so the right strip (colour-visible area) gets full accent */
.layout-5 { background: var(--accent); }
.layout-5 {
  background: linear-gradient(to right,
    color-mix(in srgb, var(--accent) 25%, #141210) 0%,
    var(--accent) 100%);
}
.layout-5 .pj-photo { left: 0; top: 8%; width: 55%; height: 84%; }
.layout-5 .pj-info  { right: 22.5%; top: 0; transform: translateX(50%); max-width: 40%; }

/* ── Layout 6: image tall right-anchored 52×90%, title top-left ─────── */
.layout-6 { background: var(--accent); }
.layout-6 {
  background: linear-gradient(to bottom,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 20%, #141210) 100%);
}
.layout-6 .pj-photo { right: 2%; bottom: 0; width: 62%; height: 90%; }
.layout-6 .pj-info  { left: 18%; top: 0; transform: translateX(-50%); max-width: 32%; }

/* ── Layout 7: image right full-height 65%, title bottom-left ────────── */
/* stakeholder-approved                                                    */
.layout-7 { background: var(--accent); }
.layout-7 {
  background: linear-gradient(to bottom,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 18%, #141210) 100%);
}
.layout-7 .pj-photo { right: 0; top: 0; width: 65%; height: 100%; }
.layout-7 .pj-info  { left: 17.5%; bottom: 0; transform: translateX(-50%); max-width: 30%; }

/* ── Layout 8: image right/center 62×70%, title top-left ─────────────── */
.layout-8 { background: var(--accent); }
.layout-8 {
  background: linear-gradient(135deg,
    var(--accent) 0%,
    color-mix(in srgb, var(--accent) 25%, #141210) 100%);
}
.layout-8 .pj-photo { left: 33%; top: 15%; width: 62%; height: 70%; }
.layout-8 .pj-info  { left: 16.5%; top: 0; transform: translateX(-50%); max-width: 28%; }

/* ── (layouts B–S removed — replaced by layout-1 through layout-8 above) */
/* Gallery button */
.view-more-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 11px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(245, 240, 235, 0.8);
  padding: 0.85rem 1.8rem;
  border: 1px solid rgba(245, 240, 235, 0.35);
  transition: background 0.3s ease, color 0.3s ease, border-color 0.3s ease;
}

.view-more-btn:hover {
  background: rgba(245, 240, 235, 0.12);
  color: rgba(245, 240, 235, 1);
  border-color: rgba(245, 240, 235, 0.6);
}

/* GLightbox overrides — no captions, faster fade */
.gslide-description,
.gslide-title,
.gdesc-inner { display: none !important; }

.ginner-container { transition: opacity 0.4s ease !important; }

/* Hidden gallery items — in DOM for GLightbox, not rendered */
.gallery-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  left: -9999px;
}

/* ─── Contact Section ────────────────────────────────────────────────── */
#contact {
  position: relative;
  z-index: 1;
  background: var(--bg-dark);
  padding: 9rem 5rem 7rem 5rem;
}

.contact-rule {
  width: 52px;
  height: 2px;
  background: var(--teal);
  margin-bottom: 3rem;
}

.contact-heading {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(3rem, 5.5vw, 5rem);
  font-weight: 300;
  color: var(--bg-light);
  line-height: 1.1;
  margin-bottom: 3.5rem;
}

.contact-details { margin-bottom: 3rem; }

.contact-line {
  display: block;
  font-size: 17px;
  color: rgba(245, 240, 235, 0.55);
  line-height: 2.1;
  transition: color 0.25s ease;
}

a.contact-line:hover { color: var(--bg-light); }

.contact-line--icon { display: flex; align-items: center; gap: 0.5rem; }

.contact-footer {
  margin-top: 6rem;
  padding-top: 2rem;
  border-top: 1px solid rgba(245, 240, 235, 0.08);
  font-size: 10.5px;
  text-transform: uppercase;
  letter-spacing: 0.16em;
  color: rgba(245, 240, 235, 0.18);
}

/* ─── Reveal Animations ──────────────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.85s ease, transform 0.85s ease;
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

.reveal-d1 { transition-delay: 0.15s; }
.reveal-d2 { transition-delay: 0.3s; }
.reveal-d3 { transition-delay: 0.45s; }
.reveal-d4 { transition-delay: 0.6s; }

/* ─── Responsive ─────────────────────────────────────────────────────── */
@media (max-width: 1024px) {
  #hero { grid-template-columns: 1fr; }
  .hero-portrait-wrap { display: none; }
  .hero-content { padding: 5rem 2.5rem 4rem; }
  .hero-bio { max-width: 100%; }

  /* All layout presets collapse to the same stacked view */
  .layout-1, .layout-2, .layout-3, .layout-4,
  .layout-5, .layout-6, .layout-7, .layout-8 {
    height: auto;
    display: flex;
    flex-direction: column;
  }

  .layout-1 .pj-photo, .layout-2 .pj-photo, .layout-3 .pj-photo,
  .layout-4 .pj-photo, .layout-5 .pj-photo, .layout-6 .pj-photo,
  .layout-7 .pj-photo, .layout-8 .pj-photo {
    position: relative;
    inset: auto;
    width: 100%;
    height: auto;
    aspect-ratio: 16 / 10;
  }

  .layout-1 .pj-info, .layout-2 .pj-info, .layout-3 .pj-info,
  .layout-4 .pj-info, .layout-5 .pj-info, .layout-6 .pj-info,
  .layout-7 .pj-info, .layout-8 .pj-info {
    position: relative;
    inset: auto;
    transform: none;
    max-width: 100%;
    padding: 3.5rem 2.5rem 4.5rem;
  }
}

@media (max-width: 640px) {
  .hero-name { font-size: 2.8rem; }
  .hero-content { padding: 4rem 1.5rem 3rem; }
  #contact { padding: 5rem 1.5rem 4rem; }

  .layout-1 .pj-info, .layout-2 .pj-info, .layout-3 .pj-info,
  .layout-4 .pj-info, .layout-5 .pj-info, .layout-6 .pj-info,
  .layout-7 .pj-info, .layout-8 .pj-info {
    padding: 3rem 1.5rem 4rem;
  }
}
