@font-face {
  font-family: 'Veilflower';
  src: url('font/MYFONT.otf') format('opentype'),
       url('font/MYFONT.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}

/* Reset & Typography */
html, body {
  margin: 0;
  padding: 0;
  height: 100%;
  font-family: Georgia, "Times New Roman", Times, serif;
  color: #111;
  background: #faf9f0;
}

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

/* Accent & spacing variables */
:root {
  --accent: #888;
  --sidebar-width: 220px; /* balanced for layout */
  --gutter: 20px;
  --logo-width: 200px;
}

/* Site Layout */
.site { 
  display: flex;
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  flex: 0 0 var(--sidebar-width);
  width: var(--sidebar-width);
  padding: 0px 24px;
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  background: #faf9f0;
  display: flex;
  flex-direction: column;
  align-items: center; /* center logo + nav horizontally */
  z-index: 100;
  box-sizing: border-box;
}

/* Logo */
.brand {
  width: 100%;
  display: flex;
  justify-content: center;
  margin-top: 50px;
  margin-bottom: 20px;
}

.brand .logo-img {
  max-width: var(--logo-width);
  width: 100%;
}

/* Nav Wrapper */
.nav-wrapper {
  width: 100%;
  display: flex;
  justify-content: center; /* center nav block horizontally */
}

/* Navigation */
.nav {
  display: flex;
  flex-direction: column;
  align-items: center; /* center menu text */
  width: 100%;
  text-align: center;
}

.nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav li {
  margin: 4px 0;
}

.nav a {
  font-size: 15px;
  font-weight: 400;
  letter-spacing: 0.04em;
  color: #111;
  display: inline-block; /* shrink to text width so centering works cleanly */
  padding: 8px 0;
}

.nav a.active {
  font-weight: 600;
  color: #1f6064;
}

.nav a:hover {
  font-weight: 600;
  color: #000;
}


/* Main Content */
.main {
  flex: 1;
  margin-left: calc(var(--sidebar-width) + 10px);
  padding: 30px 20px;
  max-width: calc(100% - var(--sidebar-width) - 30px);
  box-sizing: border-box;
  overflow-x: hidden;
}

/* Gallery (Work Page) */
.gallery {
  column-count: 2;
  column-gap: 15px;
  padding-left: 5px;
  padding-right: 5px;
}

.tile {
  break-inside: avoid;
  margin-bottom: 15px;
  overflow: hidden;
  border-radius: 4px;
  cursor: pointer;
}

.tile img {
  width: 100%;
  height: auto;
  display: block;
  transition: transform .35s ease-out, opacity .35s ease-out;
}

.tile img:hover {
  transform: scale(1.02);
  opacity: 0.95;
}

/* Lightbox overlay */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.85);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9999;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.lightbox.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox img {
  max-width: 90%;
  max-height: 90%;
  border-radius: 4px;
}

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  font-size: 50px;
  color: white;
  cursor: pointer;
  padding: 10px;
  opacity: 0.7;
  transition: opacity 0.2s ease;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  opacity: 1;
}

.lightbox-prev { left: 40px; }
.lightbox-next { right: 40px; }

/* --- UNIVERSAL PAGE CONSISTENCY --- */
.main.about,
.main.cv {
  margin-left: calc(var(--sidebar-width) + 10px);
  padding: 10px 40px;
  max-width: calc(100% - var(--sidebar-width) - 40px);
  background: #faf9f0;
  color: #111;
}

.about p,
.cv-content p,
.cv-content li {
  font-family: Georgia, "Times New Roman", Times, serif;
  line-height: 1.7;
  font-size: 16px;
}

/* --- ABOUT PAGE --- */
.about {
  display: flex;
  align-items: center;       /* vertical centering */
  justify-content: flex-start;  /* align everything to the left of page */
  min-height: auto;
  margin-top: 40px; /* adjust number to taste */
  gap: 60px;                 /* space between image and text box */
  flex-wrap: wrap;           /* stack on mobile */
  padding-left: 40px;        /* optional: spacing from left edge */
}

.about-img {
  max-width: 430px;
  width: 100%;
  height: auto;
  border-radius: 8px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
  flex-shrink: 0;
}

/* Container for text + borders */
.artist-text-box {
  display: flex;
  flex-direction: column;
  align-items: center;  /* center text and borders horizontally within box */
  justify-content: center;
  max-width: 600px;
  width: 100%;
}

/* Top and bottom border GIFs */
.border-gif {
  width: 70%;     /* adjust this number to taste (60–80% is common) */
  max-width: 420px; 
  margin-left: auto;
  margin-right: auto;
  height: auto;
  display: block;
}

.top-border {
  margin-bottom: 10px; /* spacing between top border and text */
}

.bottom-border {
  margin-top: 10px; /* spacing between text and bottom border */
}

/* Artist statement text */
.artist-statement {
  text-align: center;
  font-size: 14px;
  line-height: 1.7;
  color: #111;
  background: #faf9f0;
  padding: 20px;
  z-index: 1;
}


/* --- ANIMATION PAGE --- */
.animation-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 20px 40px 20px;
  text-align: center;
}

.video-container {
  position: relative;
  width: 100%;
  max-width: 1160px;
  aspect-ratio: 16 / 9;
  margin-bottom: 40px;
}

.video-container iframe {
  width: 100%;
  height: 100%;
  border: none;
  border-radius: 6px;
}

.animation-gallery {
  width: 100%;
  max-width: 1160px;
  column-count: 2;
  column-gap: 20px;
  padding: 0;
  margin: 0 auto;
}

.animation-gallery img {
  width: 100%;
  border-radius: 6px;
  margin-bottom: 20px;
  display: block;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.animation-gallery img:hover {
  transform: scale(1.02);
  opacity: 0.9;
}

.animation-title {
  font-family: 'Veilflower', Georgia, serif;
  font-size: 6rem;
  font-weight: 600;
  text-align: center;
  color: #1f6064;
}

/* --- BOOK PAGE --- */
.book-page {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 10px 20px 40px 20px;
  text-align: center;
}

.book-title {
  font-family: 'Veilflower', Georgia, serif;
  font-size: 6rem;
  font-weight: 600;
  text-align: center;
  color: #1f6064;
}

/* --- UNIFY HEADER SPACING --- */
.page-title,
.animation-title,
.book-title {
  margin-top: 20px;
  margin-bottom: 10px;
  line-height: 1.05;
}

.book-subtitle,
.animation-subtitle {
  font-size: 16px;
  line-height: 1.6;
  max-width: 840px;
  margin: 0 auto 30px auto;
  text-align: center;
  color: #333;
  padding: 0 10px;
}

.book-hero {
  width: 100%;
  max-width: 1160px;
  margin: 0px auto 40px auto;
}

.book-hero img {
  width: 100%;
  border-radius: 6px;
  display: block;
}

/* -------------------------------------------------- */
/* RESPONSIVE DESIGN */
@media (max-width: 900px) {
  :root { --sidebar-width: 0; }

  .site { flex-direction: column; }

  .sidebar {
    position: relative;
    width: 100%;
    height: auto;
    padding: 20px 0;
    align-items: center;
    border-bottom: 1px solid #ddd;
  }

  .brand { margin: 10px 0; }

  .nav { width: auto; padding: 0; }

  .nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 16px;
  }

  .main { margin-left: 0; padding-top: 20px; max-width: 100%; }

  body, .main, .about p, .cv-content, .artist-statement {
    font-size: clamp(14px, 2vw, 16px);
    line-height: 1.6;
    text-align: center;
  }

  h1, .animation-title { font-size: clamp(2rem, 6vw, 4rem); }

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

  .gallery, .animation-gallery { column-count: 1; column-gap: 0; max-width: 95%; margin: 0 auto; }

  .animation-page, .book-page { padding: 10px 10px 30px 10px; }

  .video-container { max-width: 100%; aspect-ratio: 16 / 9; }

  .about { flex-direction: column; gap: 20px; margin-top: 20px; text-align: center; }

  .about-img { max-width: 80%; }

  .artist-text-box { width: 90%; }

  .artist-statement { max-width: 90%; text-align: center; }

  .border-gif { width: 150%; }

  .lightbox-prev, .lightbox-next { font-size: 1.5rem; left: 20px; right: 20px; }
    /* NEW — scale book + animation titles */
  .book-title,
  .animation-title {
    font-size: clamp(2.5rem, 8vw, 4rem);
    line-height: 1.1;
  }

  /* NEW — fix spacing & responsiveness for text + borders */
  .artist-text-box {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
  }

  /* NEW — make border GIFs scale correctly */
  .border-gif {
    width: 100%;        /* was 150%, causing overflow */
    max-width: 500px;   /* prevents huge stretching on tablets */
  }

  /* optional but recommended cleanup for consistency */
  .artist-statement {
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
  }
}

