/* Reset and Box Sizing */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base Styles */
body {
  font-family: "Helvetica Neue", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #222;
  background: #fff;
}

img {
  display: block;
  width: 100%;
}

.container {
  width: 100%;
  max-width: 1500px;
  margin: 0 auto;
  padding: 0 20px;
}

#work {
  scroll-margin-top: 280px;
}

/* Header Styles */
header {
  position: fixed;
  top: 0;
  width: 100%;
  height: 25vh;
  display: flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid rgba(200, 200, 200, 0.3);
  z-index: 1000;
  overflow: hidden;
  transition: height 0.3s ease, background-color 0.3s ease;
}


header.collapsed {
  height: 80px !important;
  background: rgba(255, 255, 255, 0.95);
}

header.collapsed h1 {
  font-size: 1.25rem !important;
}

header.collapsed nav.nav-links a {
  font-size: 1rem !important;
}

/* Header Inner Container */
.header-inner {
  max-width: 1200px;
  width: 100%;
  margin: 0 auto;
  padding: 0 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Header Title */
header h1 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: 2.5rem;
  margin: 0;
}

/* Navigation Links */
nav.nav-links a {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 500;
  font-size: 1.125rem;
  color: #222;
  text-decoration: none;
  margin-left: 20px;
  border-bottom: 1px solid transparent;
  transition: font-size 0.1s ease-out, border-color 0.2s ease;
}

header.shrunk nav.nav-links a,
header.collapsed nav.nav-links a {
  font-size: 1rem;
}

nav.nav-links a:hover,
nav.nav-links a:focus {
  border-color: #222;
  outline: none;
}

/* Hamburger Toggle */
.menu-toggle {
  display: none;
  flex-direction: column;
  justify-content: space-between;
  width: 36px;
  height: 28px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  z-index: 1200;
}

.menu-toggle span {
  display: block;
  height: 3px;
  background: #444;
  border-radius: 2px;
  transition: all 0.3s ease;
}

.menu-toggle span:nth-child(1) {
  width: 100%;
}

.menu-toggle span:nth-child(2) {
  width: 75%;
  align-self: flex-end;
}

.menu-toggle span:nth-child(3) {
  width: 50%;
  align-self: flex-start;
}

.menu-toggle.active span:nth-child(1) {
  transform: rotate(45deg);
  width: 100%;
  align-self: center;
}

.menu-toggle.active span:nth-child(2) {
  opacity: 0;
}

.menu-toggle.active span:nth-child(3) {
  transform: rotate(-45deg);
  width: 100%;
  align-self: center;
}

.menu-toggle:hover span {
  background: #222;
}

/* Headings */
h1,
h2 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  color: #111;
  line-height: 1.2;
  letter-spacing: 0.03em;
  margin-bottom: 0.5em;
}

h1 {
  font-size: 2.5rem;
}

h2 {
  font-size: 1.75rem;
}

/* Paragraphs */
p {
  font-family: "Georgia", serif;
  font-size: 1.1rem;
  color: #444;
  max-width: 700px;
  margin-bottom: 1.5em;
  letter-spacing: 0.01em;
}

/* Main */
main {
  padding-top: 0;
}

/* Hero Section */
.hero {
  margin-top: 25vh;
  display: flex;
  justify-content: center;
}

.hero img {
  width: 100%;
  max-width: 1500px;
  /* max-height: 100vh; */
  object-fit: cover;
}

/* Separator */
.separator {
  width: 100%;
  max-width: 1500px;
  margin: 80px auto;
  height: 1px;
  background: #ddd;
  text-align: center;
}

.separator span {
  position: relative;
  display: inline-block;
  background: #fff;
  padding: 0 15px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  text-transform: lowercase;
  letter-spacing: 0.1em;
  top: -1rem;
  color: #666;
}

/* Section Label */
.section-label {
  text-align: center;
  margin: 100px 0 40px;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1rem;
  color: #555;
  text-transform: lowercase;
  letter-spacing: 0.1em;
}

/* Gallery */
.gallery-container {
  display: flex;
  justify-content: center;
  padding: 40px;
}

.gallery {
  width: 100%;
  max-width: 1500px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  grid-auto-rows: auto;
  gap: 40px;
}

.gallery figure {
  position: relative;
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.3s ease;
}

.gallery figure.tall {
  grid-row: span 2;
}


figure img {
  transition: transform 0.4s ease, opacity 0.4s ease;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

figure:hover img {
  transform: scale(1.03);
}

/* Zoom overlay */
.zoom-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: saturate(180%) blur(10px);
  z-index: 9998;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.zoom-overlay.active {
  opacity: 1;
  pointer-events: auto;
  transition: background 0.3s ease;
}

/* Placeholder to reserve space */
.gallery figure.placeholder {
  visibility: hidden;
}

/* The expanded clone: default styling */
.expanded-clone {
  border-radius: 8px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  transition: all 0.4s ease;
}

.expanded-clone img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.zoom-arrow {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  font-size: 3rem;
  color: white;
  cursor: pointer;
  user-select: none;
  background: rgba(0, 0, 0, 0.4);
  padding: 0.5rem 1rem;
  border-radius: 50%;
  z-index: 10000;
  transition: background 0.3s ease;
}

.zoom-arrow:hover {
  background: rgba(0, 0, 0, 0.8);
}

.left-arrow {
  left: 10px;
}

.right-arrow {
  right: 10px;
}



/* Captions */
figcaption {
  position: absolute;
  bottom: 0;
  width: 100%;
  background: rgba(255, 255, 255, 0.85);
  color: #333;
  font-family: 'Cormorant Garamond', serif;
  font-size: 14px;
  padding: 10px;
  text-align: center;
  opacity: 0;
  transform: translateY(20px);
  transition: all 0.3s ease;
}

figure.visible figcaption,
figure:hover figcaption {
  opacity: 1;
  transform: translateY(0);
}

.caption-link {
  font-family: "Georgia", serif;
  font-size: 13px;
  color: #555;
  text-decoration: underline;
}

/* Description Block */
.description-block {
  max-width: 600px;
  margin: 60px auto;
  font-family: 'Cormorant Garamond', serif;
  font-size: 17px;
  color: #444;
  text-align: center;
}

/* Floating Layout */
.floating-layout {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 40px;
  max-width: 1500px;
  margin: 100px auto;
  padding: 0 20px;
}

.floating-layout .image,
.floating-layout .text {
  flex: 1 1 400px;
}

/* Footer */
footer {
  text-align: center;
  font-size: 14px;
  color: #777;
  margin-top: 100px;
  padding: 40px 20px;
}

/* Scrollbar Removal for No Scroll Class */
body.no-scroll {
  overflow: hidden;
  height: 100vh;
}

/* Page Shimmer Overlay */
.page-shimmer {
  position: fixed;
  top: 0;
  left: -150%;
  width: 150%;
  height: 100vh;
  background: linear-gradient(120deg,
      transparent 40%,
      rgba(255, 255, 255, 0.8) 50%,
      transparent 60%);
  transform: skewX(-20deg);
  pointer-events: none;
  z-index: 9999;
  animation: shimmer 1.5s ease forwards;
}

@keyframes shimmer {
  0% {
    left: -150%;
  }

  100% {
    left: 150%;
  }
}

/* Responsive */
@media (max-width: 900px) {
  .header-inner {
    padding: 0 20px;
  }
}

@media (max-width: 768px) {
  header h1 {
    font-size: 1.25rem;
  }

  nav.nav-links {
    display: flex;
    flex-direction: column;
    position: static;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    opacity: 1;
    pointer-events: auto;
  }

  nav.nav-links.show {
    display: flex;
  }

  nav.nav-links a {
    margin: 10px 0;
  }

  .menu-toggle {
    display: flex;
    opacity: 0;
    pointer-events: none;
  }

  header.mobile-collapsed nav.nav-links {
    opacity: 0;
    pointer-events: none;
  }

  header.mobile-collapsed .menu-toggle {
    opacity: 1;
    pointer-events: auto;
  }

  .gallery-container {
    padding: 0;
  }

  .description-block {
    padding: 20px;
    font-size: 0.8em;
    text-align: justify;
  }
}