/* ============================================================
   PORTFOLIO — Design Work
   Minimalist portfolio stylesheet
   ============================================================ */

/* --- RESET & BASE ----------------------------------------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  background: #ffffff;
  color: #111111;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-weight: 300;
  min-height: 100vh;
}

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

img {
  display: block;
  width: 100%;
}

/* --- NAVIGATION ------------------------------------------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 52px;
  height: 58px;
  background: rgba(255, 255, 255, 0.94);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.nav-logo {
  display: flex;
  align-items: center;
  opacity: 1;
  transition: opacity 0.25s;
}

.nav-logo:hover {
  opacity: 0.55;
}

.nav-logo-img {
  height: 22px;
  width: auto;
  display: block;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 36px;
}

.nav-link,
.nav-contact-btn {
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #aaa;
  transition: color 0.25s ease;
}

.nav-link:hover,
.nav-contact-btn:hover {
  color: #111;
}

.nav-contact-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
}

/* --- HOME: SCATTERED CANVAS -------------------------------- */
.grid-container {
  position: relative;
  width: 100%;
  min-height: 100vh;
  padding-top: 58px; /* nav height */
  overflow-x: hidden;
}

/* --- PROJECT CARD ----------------------------------------- */
.project-card {
  position: absolute;
  display: block;
  cursor: pointer;
}

.card-preview {
  position: relative;
  overflow: hidden;
  background: #f0f0f0;
  box-shadow:
    0 2px 6px rgba(0, 0, 0, 0.05),
    0 8px 32px rgba(0, 0, 0, 0.09);
  transition: box-shadow 0.4s ease;
}

.card-preview img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform 0.6s ease;
}

.project-card:hover .card-preview img {
  transform: scale(1.03);
}

/* Hover overlay — light grey, very low opacity */
.card-overlay {
  position: absolute;
  inset: 0;
  background: rgba(230, 230, 230, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.project-card:hover .card-overlay {
  opacity: 1;
}

.card-overlay-title {
  font-family: 'Inter', sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #222;
  text-align: center;
  padding: 0 16px;
}

/* Floating keyframes — each card gets its own rhythm */
@keyframes float1 { 0%,100%{transform:translateY(0)}    50%{transform:translateY(-7px)} }
@keyframes float2 { 0%,100%{transform:translateY(-4px)} 50%{transform:translateY(3px)}  }
@keyframes float3 { 0%,100%{transform:translateY(-2px)} 50%{transform:translateY(-8px)} }
@keyframes float4 { 0%,100%{transform:translateY(0)}    50%{transform:translateY(-6px)} }
@keyframes float5 { 0%,100%{transform:translateY(-5px)} 50%{transform:translateY(2px)}  }
@keyframes float6 { 0%,100%{transform:translateY(-3px)} 50%{transform:translateY(-9px)} }
@keyframes float7 { 0%,100%{transform:translateY(0)}    50%{transform:translateY(-5px)} }

/* ── Scattered layout — 7 cards ──────────────────────────── */

/* 1 · Flames of the Khan — large, top-left-center */
.project-card:nth-child(1) {
  left: 36%;
  top: 100px;
  width: 400px;
  animation: float1 6.2s ease-in-out infinite;
}

/* 2 · GBI — small, top far-left, higher */
.project-card:nth-child(2) {
  left: 9%;
  top: 170px;
  width: 300px;
  animation: float2 7.1s ease-in-out infinite;
}

/* 3 · THE VOID — small, top far-right */
.project-card:nth-child(3) {
  left: 71%;
  top: 92px;
  width: 220px;
  animation: float3 5.8s ease-in-out infinite;
}

/* 4 · ONE THIRD — medium, bottom far-left */
.project-card:nth-child(4) {
  left: 10%;
  top: 430px;
  width: 320px;
  animation: float4 6.6s ease-in-out infinite;
}

/* 5 · LINA — medium-large, top right-center */
.project-card:nth-child(5) {
  left: 54%;
  top: 480px;
  width: 280px;
  animation: float5 7.4s ease-in-out infinite;
}

/* 6 · UMPATAMPA — small, bottom center */
.project-card:nth-child(6) {
  left: 35%;
  top: 450px;
  width: 230px;
  animation: float6 6.0s ease-in-out infinite;
}

/* 7 · Best New Artist — small, bottom right */
.project-card:nth-child(7) {
  left: 77%;
  top: 415px;
  width: 210px;
  animation: float7 5.5s ease-in-out infinite;
}


/* --- PROJECT DETAIL PAGE ---------------------------------- */
.project-page {
  padding-top: 58px;
  min-height: 100vh;
  overflow-y: auto;
}

/* Wide view mode — per-project size override */
.project-page--wide .project-work,
.project-page--wide .project-header {
  max-width: 28vw;
}

.project-back-wrap {
  padding: 36px 52px 0;
}

.sidebar-back {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #bbb;
  transition: color 0.25s ease;
}

.sidebar-back:hover {
  color: #111;
}

.sidebar-back:hover .back-arrow {
  transform: translateX(-3px);
}

.back-arrow {
  display: inline-block;
  font-size: 15px;
  line-height: 1;
  transition: transform 0.25s ease;
}

/* Centered work area — FIRST */
.project-work {
  max-width: 65vw;
  margin: 0 auto;
  padding: 32px 0 0;
}

/* Text block — BELOW work, left-aligned */
.project-header {
  max-width: 65vw;
  margin: 0 auto;
  padding: 36px 0 80px;
  text-align: left;
}

/* Project title — serif, left-aligned */
.project-title {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-size: 30px;
  font-weight: 400;
  line-height: 1.0;
  color: #111;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}

/* Description — left-aligned */
.project-description {
  font-size: 12px;
  font-weight: 300;
  line-height: 1.95;
  color: #555;
  text-align: left;
  max-width: 560px;
}

.project-description p + p {
  margin-top: 1.4em;
}

/* Tags / details below description */
.project-tags {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid #ebebeb;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.tag-row {
  display: flex;
  gap: 20px;
  align-items: baseline;
}

.tag-label {
  font-size: 9px;
  font-weight: 400;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: #ccc;
  min-width: 72px;
}

.tag-value {
  font-size: 12px;
  font-weight: 400;
  color: #444;
  letter-spacing: 0.02em;
}

/* Centered work area */
.project-work {
  max-width: 65vw;
  margin: 0 auto;
  padding: 0;
}

.project-image-stack {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Two images side by side */
.project-img-row {
  display: flex;
  gap: 16px;
}

.project-img-row .project-img {
  flex: 1;
  width: 0;
  min-width: 0;
}

.project-img {
  width: 100%;
  display: block;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.04),
    0 6px 28px rgba(0, 0, 0, 0.09);
}

.project-img-block {
  width: 100%;
  aspect-ratio: 16 / 9;
  display: block;
}

/* Video players */
.project-video-wrap {
  width: 100%;
  box-shadow:
    0 1px 3px rgba(0, 0, 0, 0.04),
    0 6px 28px rgba(0, 0, 0, 0.09);
}

/* Responsive 16:9 iframe (Vimeo / YouTube) */
.project-video-wrap:has(.project-video-iframe) {
  position: relative;
  aspect-ratio: 16 / 9;
}

.project-video-iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

/* Native mp4 player */
.project-video-native {
  width: 100%;
  display: block;
  outline: none;
  background: #000;
}


  font-weight: 400;
  color: #444;
  letter-spacing: 0.03em;
}

/* --- ANIMATIONS ------------------------------------------- */
body {
  animation: pageIn 0.4s ease both;
}

@keyframes pageIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.project-card {
  animation: cardIn 0.55s ease both;
}

.project-card:nth-child(1) { animation-delay: 0.04s; }
.project-card:nth-child(2) { animation-delay: 0.09s; }
.project-card:nth-child(3) { animation-delay: 0.14s; }
.project-card:nth-child(4) { animation-delay: 0.19s; }
.project-card:nth-child(5) { animation-delay: 0.24s; }
.project-card:nth-child(6) { animation-delay: 0.29s; }

@keyframes cardIn {
  from {
    opacity: 0;
    transform: translateY(18px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Sidebar content fade in */
.project-sidebar > * {
  animation: sideIn 0.5s ease both;
}

.project-sidebar > *:nth-child(1) { animation-delay: 0.1s; }
.project-sidebar > *:nth-child(2) { animation-delay: 0.16s; }
.project-sidebar > *:nth-child(3) { animation-delay: 0.22s; }
.project-sidebar > *:nth-child(4) { animation-delay: 0.28s; }
.project-sidebar > *:nth-child(5) { animation-delay: 0.33s; }
.project-sidebar > *:nth-child(6) { animation-delay: 0.38s; }
.project-sidebar > *:nth-child(7) { animation-delay: 0.43s; }

@keyframes sideIn {
  from {
    opacity: 0;
    transform: translateX(10px);
  }
  to {
    opacity: 1;
    transform: translateX(0);
  }
}

/* --- RESPONSIVE ------------------------------------------- */
@media (max-width: 1200px) {
  .grid-container {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 900px) {
  .nav {
    padding: 0 28px;
  }

  .grid-container {
    padding: calc(58px + 36px) 28px 72px;
    grid-template-columns: repeat(2, 1fr);
    gap: 32px 24px;
  }
}

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

  .project-layout {
    flex-direction: column-reverse;
    height: auto;
    overflow: visible;
    padding-top: 58px;
  }

  .project-content {
    flex: none;
    height: auto;
    overflow: visible;
  }

  .project-images-scroll {
    flex: none;
    height: auto;
    overflow: visible;
    padding: 32px 24px;
  }

  .project-details-overlay {
    flex-wrap: wrap;
    padding: 16px 24px;
    gap: 24px;
  }

  .project-sidebar {
    flex: none;
    height: auto;
    overflow: visible;
    padding: 32px 24px 60px;
    border-left: none;
    border-top: 1px solid #ebebeb;
  }

  .project-title {
    font-size: 44px;
  }
}

/* --- LIGHTBOX -------------------------------------------- */
.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 900;
  align-items: center;
  justify-content: center;
}

.lightbox.active {
  display: flex;
}

/* Blurred, low-opacity backdrop */
.lightbox-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(255, 255, 255, 0.55);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  animation: lbFadeIn 0.25s ease;
}

/* Image + close button wrapper */
.lightbox-frame {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: flex-start;
  animation: lbScaleIn 0.25s ease;
}

/* The enlarged image */
.lightbox-img {
  max-width: 82vw;
  max-height: 88vh;
  object-fit: contain;
  display: block;
  box-shadow:
    0 4px 24px rgba(0, 0, 0, 0.08),
    0 16px 64px rgba(0, 0, 0, 0.12);
}

/* Close × button — right side of image */
.lightbox-close {
  position: absolute;
  top: 0;
  right: -38px;
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  font-size: 20px;
  line-height: 1;
  color: #aaa;
  cursor: pointer;
  padding: 0;
  transition: color 0.2s ease;
}

.lightbox-close:hover {
  color: #111;
}

@keyframes lbFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes lbScaleIn {
  from { opacity: 0; transform: scale(0.96); }
  to   { opacity: 1; transform: scale(1); }
}

/* Make project images clickable */
.project-img {
  cursor: zoom-in;
}

/* --- CONTACT DRAWER --------------------------------------- */
.drawer-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(255, 255, 255, 0.5);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 800;
}
.drawer-backdrop.active {
  display: block;
}

.contact-drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 320px;
  height: 100vh;
  background: #fff;
  border-left: 1px solid #ebebeb;
  z-index: 850;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.4, 0, 0.2, 1);
  display: flex;
  flex-direction: column;
}
.contact-drawer.active {
  transform: translateX(0);
}

.drawer-close {
  position: absolute;
  top: 20px;
  right: 24px;
  background: none;
  border: none;
  font-size: 22px;
  color: #aaa;
  cursor: pointer;
  padding: 0;
  line-height: 1;
  transition: color 0.2s ease;
}
.drawer-close:hover { color: #111; }

.drawer-content {
  padding: 72px 36px 48px;
  display: flex;
  flex-direction: column;
  gap: 0;
  overflow-y: auto;
}

.drawer-photo {
  width: 100%;
  display: block;
  margin-bottom: 24px;
}

.drawer-name {
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: #111;
  margin: 0 0 22px;
  text-align: left;
}

.drawer-links {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.drawer-links p {
  font-family: 'Inter', sans-serif;
  font-size: 12px;
  font-weight: 400;
  color: #555;
  letter-spacing: 0.04em;
  margin: 0;
  text-align: left;
}

.drawer-links a {
  color: #555;
  text-decoration: none;
  transition: color 0.2s ease;
}
.drawer-links a:hover { color: #111; }

/* Dashed underline on Instagram @handle */
.insta-link {
  text-decoration: underline;
  text-decoration-style: dashed;
  text-underline-offset: 3px;
}
.insta-link:hover { color: #111; }
