/*
  ============================================
  style.css — how the website LOOKS
  ============================================
  HTML = structure (boxes and text)
  CSS  = style (colours, size, spacing)
  JS   = behaviour (clicking, building albums)

  Colours used on this site:
  --paper  = page background (soft off-white)
  --ink    = main text (near black)
  --muted  = quieter grey text
  --line   = thin borders
  ============================================
*/

/* ----- Colour + font variables ----- */
:root {
  --paper: #f7f6f3;
  --ink: #141414;
  --muted: #6b6b6b;
  --line: #e4e1da;
  --white: #ffffff;
  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-body: "Outfit", system-ui, sans-serif;
}

/* ----- Reset: remove browser default spacing ----- */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  background: var(--paper);
  color: var(--ink);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  min-height: 100vh;
}

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

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

a:hover {
  opacity: 0.7;
}

/* ============================================
   HEADER
   ============================================ */
.site-header {
  position: sticky;          /* stays at top while scrolling */
  top: 0;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: rgb(247 246 243 / 0.9);
  backdrop-filter: blur(10px); /* frosted glass effect */
  border-bottom: 1px solid var(--line);
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  letter-spacing: 0.02em;
}

.logo:hover {
  opacity: 1;
}

.logo-img {
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  object-fit: cover;
}

.site-nav {
  display: flex;
  gap: 1.5rem;
}

.site-nav a {
  font-size: 0.9rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.site-nav a:hover,
.site-nav a.active {
  color: var(--ink);
  opacity: 1;
}

/* Phone menu button — hidden on desktop */
.menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--ink);
}

/* ============================================
   HERO (big name on home page)
   ============================================ */
.hero {
  text-align: center;
  padding: 5.5rem 1.5rem 3.5rem;
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(3rem, 10vw, 5.5rem); /* grows/shrinks with screen */
  font-weight: 500;
  letter-spacing: -0.02em;
  line-height: 1;
  margin-bottom: 1rem;
}

.hero-sub {
  font-size: 1rem;
  color: var(--muted);
  font-weight: 300;
}

.hero-sub a {
  color: var(--ink);
  border-bottom: 1px solid var(--line);
}

.hero-sub a:hover {
  border-bottom-color: var(--ink);
  opacity: 1;
}

/* ============================================
   ALBUM GRID (Pixieset-style covers)
   ============================================ */
.albums {
  display: grid;
  /* 3 columns on big screens, auto-fit means it wraps nicely */
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem 1.25rem;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1.5rem 5rem;
}

.album-card {
  display: block;
}

.album-card:hover {
  opacity: 1;
}

.album-cover {
  overflow: hidden;          /* hides zoomed image edges */
  background: #ddd;
  aspect-ratio: 4 / 5;       /* tall portrait-style covers */
}

.album-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;         /* fill the box without stretching */
  transition: transform 0.5s ease;
}

.album-card:hover .album-cover img {
  transform: scale(1.04);    /* gentle zoom on hover */
}

.album-title {
  margin-top: 0.75rem;
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 500;
  letter-spacing: 0.01em;
}

.album-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: 0.15rem;
}

/* ============================================
   SINGLE GALLERY PAGE
   ============================================ */
.gallery-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 5rem;
}

.back-link {
  display: inline-block;
  font-size: 0.9rem;
  color: var(--muted);
  margin-bottom: 2rem;
}

.gallery-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.gallery-header h1 {
  font-family: var(--font-display);
  font-size: clamp(2.2rem, 6vw, 3.5rem);
  font-weight: 500;
}

.gallery-count {
  color: var(--muted);
  margin-top: 0.4rem;
}

.photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 0.75rem;
}

.photo-thumb {
  border: none;
  padding: 0;
  background: #ddd;
  cursor: zoom-in;
  aspect-ratio: 1;
  overflow: hidden;
}

.photo-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.photo-thumb:hover img {
  transform: scale(1.03);
}

/* ============================================
   LIGHTBOX (big photo when you click)
   ============================================ */
.lightbox {
  position: fixed;
  inset: 0;                  /* top/right/bottom/left = 0 */
  z-index: 2000;
  background: rgb(0 0 0 / 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.lightbox[hidden] {
  display: none;
}

.lightbox img {
  max-width: min(1100px, 100%);
  max-height: 80vh;
  object-fit: contain;
}

.lightbox-caption {
  position: absolute;
  bottom: 1.25rem;
  left: 0;
  right: 0;
  text-align: center;
  color: #fff;
  font-size: 0.9rem;
}

.lightbox-close,
.lightbox-nav {
  position: absolute;
  background: none;
  border: none;
  color: #fff;
  font-size: 2.5rem;
  cursor: pointer;
  line-height: 1;
  padding: 0.5rem;
  z-index: 2001;
}

.lightbox-close {
  top: 1rem;
  right: 1.25rem;
}

.lightbox-prev {
  left: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-nav[hidden] {
  display: none;
}

/* ============================================
   CONTACT PAGE
   ============================================ */
.contact-page {
  max-width: 720px;
  margin: 0 auto;
  padding: 4rem 1.5rem 5rem;
  text-align: center;
}

.contact-page h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 3.5rem);
  font-weight: 500;
  margin-bottom: 0.75rem;
}

.contact-intro {
  color: var(--muted);
  margin-bottom: 2.5rem;
}

.contact-links {
  display: grid;
  gap: 1rem;
}

.contact-card {
  display: block;
  padding: 1.35rem 1.5rem;
  border: 1px solid var(--line);
  background: var(--white);
  text-align: left;
  transition: border-color 0.2s ease;
}

.contact-card:hover {
  opacity: 1;
  border-color: var(--ink);
}

.contact-label {
  display: block;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 0.25rem;
}

.contact-value {
  font-family: var(--font-display);
  font-size: 1.4rem;
}

/* ============================================
   FOOTER
   ============================================ */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 1.5rem;
  text-align: center;
}

.social {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 1.25rem;
  margin-bottom: 1rem;
}

.social a {
  font-size: 0.85rem;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.copyright {
  font-size: 0.8rem;
  color: var(--muted);
}

/* Empty / error message */
.empty-msg {
  text-align: center;
  color: var(--muted);
  padding: 3rem 1rem;
}

/* ============================================
   PHONES / TABLETS
   ============================================ */
@media (max-width: 900px) {
  .albums {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 640px) {
  .menu-btn {
    display: block;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0.5rem 0;
  }

  /* When JS adds .open, show the menu */
  .site-nav.open {
    display: flex;
  }

  .site-nav a {
    padding: 0.85rem 1.5rem;
  }

  .albums {
    grid-template-columns: 1fr;
    gap: 1.75rem;
  }

  .hero {
    padding: 3.5rem 1.25rem 2.5rem;
  }

  .photo-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 0.5rem;
  }
}
