/* ============================================================
   Legacy page — A Decade of Design
   Inherits from styles.css; this file only contains page-specific rules
   ============================================================ */

.legacy-page {
  background: var(--cream);
}

/* Nav always solid on legacy page (no hero overlay) */
.legacy-page .nav {
  position: fixed;
  background: rgba(245, 239, 228, 0.96);
  backdrop-filter: blur(10px);
  padding: 14px 0;
  border-bottom: 1px solid rgba(184, 148, 90, 0.2);
}
.legacy-page .nav__brand img { height: 38px; filter: none; }
.legacy-page .nav__links a { color: var(--ink); text-shadow: none; }
.legacy-page .nav__links a.active { color: var(--gold-deep); }
.legacy-page .nav__links a.active::after {
  content: ''; position: absolute; bottom: 0; left: 0;
  width: 100%; height: 1px; background: var(--gold);
}
.legacy-page .nav__menu span { background: var(--ink); box-shadow: none; }

/* ===== Hero ===== */
.legacy-hero {
  padding: 200px 0 100px;
  background: var(--paper);
  text-align: center;
  position: relative;
}
.legacy-hero::before {
  content: '';
  position: absolute; bottom: 0; left: 0; right: 0;
  height: 1px;
  background: linear-gradient(to right, transparent, var(--rule), transparent);
}
.legacy-hero__title {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  font-size: clamp(2.6rem, 6vw, 5rem);
  line-height: 1;
  margin: 24px 0 0;
  letter-spacing: -0.015em;
}
.legacy-hero__title span { display: block; }
.legacy-hero__title .italic { color: var(--gold-deep); font-style: italic; }
.legacy-hero__lede {
  max-width: 700px;
  margin: 0 auto;
  font-size: 1.15rem;
  color: var(--ink-soft);
  line-height: 1.75;
}

/* ===== Grid section ===== */
.legacy-grid-section {
  padding: 120px 0 140px;
  background: var(--cream);
}
.legacy-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(380px, 1fr));
  gap: 36px;
}

/* ===== Tile ===== */
.legacy-tile {
  position: relative;
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  background: var(--ink);
  border: none;
  cursor: pointer;
  overflow: hidden;
  font-family: inherit;
  text-align: left;
  color: var(--paper);
  box-shadow: 0 20px 60px -20px rgba(26, 36, 54, 0.4);
  transition: transform 0.5s ease, box-shadow 0.5s ease;
  padding: 0;
}
.legacy-tile:hover {
  transform: translateY(-4px);
  box-shadow: 0 30px 80px -20px rgba(26, 36, 54, 0.5);
}
.legacy-tile__image {
  position: absolute; inset: 0;
  background-size: cover;
  background-position: center;
  transition: transform 1.4s ease;
}
.legacy-tile:hover .legacy-tile__image {
  transform: scale(1.06);
}
.legacy-tile__overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to top, rgba(26, 36, 54, 0.92) 0%, rgba(26, 36, 54, 0.5) 50%, rgba(26, 36, 54, 0.2) 100%);
}
.legacy-tile__overlay::after {
  content: '';
  position: absolute; inset: 14px;
  border: 1px solid rgba(184, 148, 90, 0.35);
  pointer-events: none;
}
.legacy-tile__content {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 40px 36px 38px;
  z-index: 2;
}
.legacy-tile__content .eyebrow {
  font-family: 'Cardo', serif;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.7rem;
}
.legacy-tile__content h3 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 400;
  font-size: clamp(1.8rem, 2.8vw, 2.4rem);
  line-height: 1.1;
  color: var(--paper);
  margin: 14px 0 10px;
}
.legacy-tile__content h3 .italic { font-style: italic; }
.legacy-tile__meta {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  color: rgba(245, 239, 228, 0.78);
  font-size: 1rem;
  margin-bottom: 22px;
}
.legacy-tile__action {
  display: inline-block;
  font-family: 'Cardo', serif;
  text-transform: uppercase;
  letter-spacing: 0.28em;
  font-size: 0.75rem;
  color: #e8cd96;
  padding-bottom: 4px;
  border-bottom: 1px solid var(--gold);
  transition: color 0.3s, border-color 0.3s;
}
.legacy-tile:hover .legacy-tile__action {
  color: var(--paper);
  border-color: var(--paper);
}

/* ===== Full-screen gallery overlay ===== */
.legacy-gallery {
  position: fixed; inset: 0;
  background: var(--paper);
  z-index: 100;
  overflow-y: auto;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  -webkit-overflow-scrolling: touch;
}
.legacy-gallery.open {
  opacity: 1;
  pointer-events: auto;
}
.legacy-gallery__close {
  position: fixed;
  top: 24px; right: 32px;
  width: 52px; height: 52px;
  background: var(--ink);
  border: 1px solid var(--gold);
  color: var(--paper);
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem; line-height: 0.7;
  cursor: pointer;
  z-index: 101;
  transition: background 0.3s;
  box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}
.legacy-gallery__close:hover { background: var(--gold-deep); }

.legacy-gallery__inner {
  max-width: 1240px;
  margin: 0 auto;
  padding: 90px 32px 100px;
}
.legacy-gallery__header {
  text-align: center;
  margin-bottom: 70px;
  padding-top: 30px;
}
.legacy-gallery__header h2 {
  font-size: clamp(2.4rem, 5vw, 4rem);
  margin: 20px 0 14px;
}
.legacy-gallery__meta {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 1.2rem;
  color: var(--muted);
  margin-bottom: 32px;
}
.legacy-gallery__description {
  max-width: 700px;
  margin: 0 auto 40px;
  font-size: 1.1rem;
  color: var(--ink-soft);
  line-height: 1.75;
}
.legacy-gallery__header .rule {
  margin-left: auto;
  margin-right: auto;
}

.legacy-gallery__photos {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
}
.legacy-gallery__photos figure {
  margin: 0;
  background: var(--ink);
  aspect-ratio: 3 / 2;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  transition: transform 0.4s ease;
}
.legacy-gallery__photos figure:hover {
  transform: scale(1.005);
}
.legacy-gallery__photos figure::after {
  content: '';
  position: absolute; inset: 10px;
  border: 1px solid rgba(245, 239, 228, 0.0);
  pointer-events: none;
  transition: border-color 0.4s;
}
.legacy-gallery__photos figure:hover::after {
  border-color: rgba(184, 148, 90, 0.4);
}
.legacy-gallery__photos img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
/* Make the first photo span both columns (hero placement) */
.legacy-gallery__photos figure:first-child {
  grid-column: 1 / -1;
  aspect-ratio: 16 / 9;
}

.legacy-gallery__footer {
  margin-top: 70px;
  padding-top: 50px;
  border-top: 1px solid var(--rule);
  text-align: center;
}

/* ===== Photo lightbox (within gallery) ===== */
.legacy-lightbox {
  position: fixed; inset: 0;
  background: rgba(15, 22, 36, 0.96);
  z-index: 200;
  display: flex; align-items: center; justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease;
  padding: 50px;
}
.legacy-lightbox.open {
  opacity: 1;
  pointer-events: auto;
}
.legacy-lightbox img {
  max-width: 95vw;
  max-height: 92vh;
  box-shadow: 0 30px 80px rgba(0,0,0,0.5);
  border: 1px solid rgba(184, 148, 90, 0.4);
}
.legacy-lightbox__close {
  position: absolute;
  top: 24px; right: 32px;
  width: 50px; height: 50px;
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--paper);
  font-family: 'Cormorant Garamond', serif;
  font-size: 2rem; line-height: 0.8;
  cursor: pointer;
  transition: background 0.3s;
}
.legacy-lightbox__close:hover { background: var(--gold); }

/* ===== Responsive ===== */
@media (max-width: 880px) {
  .legacy-hero { padding: 140px 0 70px; }
  .legacy-grid-section { padding: 70px 0 90px; }
  .legacy-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
  .legacy-tile { aspect-ratio: 4 / 5; }
  .legacy-tile__content { padding: 30px 28px; }

  .legacy-gallery__inner { padding: 70px 22px 80px; }
  .legacy-gallery__close { top: 16px; right: 16px; width: 44px; height: 44px; font-size: 1.6rem; }
  .legacy-gallery__photos {
    grid-template-columns: 1fr;
  }
  .legacy-gallery__photos figure:first-child {
    grid-column: 1;
    aspect-ratio: 3 / 2;
  }
  .legacy-lightbox { padding: 20px; }
  .legacy-lightbox__close { top: 12px; right: 12px; }
}
