@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;0,600;0,700;1,300;1,400;1,500;1,600;1,700&display=swap');

* { box-sizing: border-box; }

[hidden] { display: none !important; }

html, body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  font-family: 'Cormorant Garamond', Georgia, serif;
  -webkit-font-smoothing: antialiased;
  background: #080808;
  color: #e8e3d5;
}

img { -webkit-user-drag: none; user-select: none; }

a { text-decoration: none; color: inherit; }

button {
  font-family: inherit;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-pop { text-shadow: 0 1px 0 rgba(255,255,255,0.08), 0 2px 6px rgba(0,0,0,0.55), 0 4px 12px rgba(0,0,0,0.25); }

/* ---------- Landing ---------- */

.landing-page {
  position: relative;
  min-height: 100dvh;
  width: 100%;
  overflow: hidden;
  opacity: 0;
  animation: fade-in 1.6s ease-in-out 0.1s forwards;
}

@keyframes fade-in { to { opacity: 1; } }

.landing-hero-wrap {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}

.landing-hero {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.12);
  pointer-events: none;
  transition: transform 6s ease-out;
}

.landing-scrim {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: linear-gradient(to top, rgba(0,0,0,0.8), rgba(0,0,0,0.2) 55%, transparent);
  pointer-events: none;
}

.has-hero .landing-scrim { display: block; }
.landing-page:not(.has-hero) .landing-scrim { background: none; }

.landing-inner {
  position: relative;
  z-index: 2;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 1.5rem;
}

@media (min-width: 768px) {
  .landing-inner { padding: 3rem; }
}

.landing-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}

.brand {
  margin: 0;
  font-size: 1.25rem;
  font-style: italic;
  font-weight: 300;
  letter-spacing: 0.02em;
  color: rgba(232, 227, 213, 0.8);
}

@media (min-width: 768px) { .brand { font-size: 1.5rem; } }

.nav-link {
  font-size: 1.125rem;
  font-weight: 600;
  font-style: italic;
  letter-spacing: 0.02em;
  color: rgba(232, 227, 213, 0.9);
  opacity: 0.8;
  transition: opacity 0.3s;
}

.nav-link:hover { opacity: 1; }

@media (min-width: 768px) { .nav-link { font-size: 1.25rem; } }

.landing-bio {
  max-width: 42rem;
  color: rgba(232, 227, 213, 0.9);
  font-weight: 300;
  line-height: 1.7;
  font-size: 0.95rem;
  opacity: 0;
  transform: translateY(10px);
  animation: rise-in 1.5s ease-out 0.7s forwards;
}

@keyframes rise-in { to { opacity: 1; transform: translateY(0); } }

@media (min-width: 768px) { .landing-bio { font-size: 1.05rem; } }

/* ---------- Portfolio ---------- */

.portfolio-page {
  min-height: 100dvh;
  width: 100%;
  background: #fff;
  color: #000;
  opacity: 0;
  animation: fade-in 1s ease-in-out forwards;
}

.portfolio-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 50;
  padding: 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  mix-blend-mode: difference;
  color: #fff;
  pointer-events: none;
}

.portfolio-header a, .portfolio-header button { pointer-events: auto; }

@media (min-width: 768px) { .portfolio-header { padding: 3rem; } }

.portfolio-header .brand { color: #fff; opacity: 0.8; }
.portfolio-header .brand:hover { opacity: 1; }

.portfolio-header-right {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.5rem;
}

.gallery-title {
  margin: 0;
  font-size: 1.125rem;
  font-weight: 300;
  font-style: italic;
  letter-spacing: 0.02em;
  opacity: 0.8;
}

@media (min-width: 768px) { .gallery-title { font-size: 1.25rem; } }

.gallery-link {
  font-size: 0.9rem;
  font-weight: 300;
  font-style: italic;
  letter-spacing: 0.02em;
  opacity: 0.5;
  transition: opacity 0.3s;
}

.gallery-link:hover { opacity: 0.8; }

.diptych-list {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding: 0.375rem;
}

.diptych-row {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  opacity: 0;
  transform: translateY(-28px);
  transition: opacity 1.1s ease-out, transform 0.6s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.diptych-row.is-visible { opacity: 1; transform: translateY(0); }

@media (min-width: 768px) { .diptych-row { flex-direction: row; } }

.diptych-half {
  width: 100%;
  height: 50vh;
  position: relative;
  overflow: hidden;
  cursor: zoom-in;
}

.diptych-half:focus { outline: none; }
.diptych-half:focus-visible { outline: 2px solid rgba(0, 0, 0, 0.6); outline-offset: -2px; }

@media (min-width: 768px) { .diptych-half { width: 50%; height: 70vh; } }

.diptych-half img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.7s ease-in-out;
  pointer-events: none;
}

.diptych-half:hover img { transform: scale(1.02); }

/* ---------- Lightbox ---------- */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0,0,0,0.96);
}

.lightbox img {
  max-width: 88vw;
  max-height: 88vh;
  object-fit: contain;
  user-select: none;
}

.lightbox-close {
  position: absolute;
  top: 1.5rem; right: 2rem;
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  font-weight: 300;
  color: rgba(255,255,255,0.35);
  transition: color 0.3s;
}

.lightbox-close:hover { color: rgba(255,255,255,0.8); }

.lightbox-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2rem; height: 2rem;
  background: rgba(255,255,255,0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s;
}

.lightbox-arrow:hover { background: rgba(255,255,255,0.2); }
.lightbox-prev { left: 1.5rem; }
.lightbox-next { right: 1.5rem; }

.lightbox-count {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  color: rgba(255,255,255,0.25);
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.15em;
}
