/* =====================
   RESET & BASE
   ===================== */

*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --sidebar-width: 300px;
  --bg: #f5f4f0;
  --text: #111;
  --muted: #999;
  --font-display: 'Georgia', serif;
  --font-body: 'Georgia', serif;
}

html, body {
  height: 100%;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
}

body { display: flex; }

/* =====================
   SIDEBAR
   ===================== */

.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: var(--sidebar-width);
  height: 100vh;
  padding: 50px 36px;
  display: flex;
  flex-direction: column;
  z-index: 100;
  background: var(--bg);
}

.logo {
  font-family: var(--font-display);
  font-size: 38px;
  font-style: normal;
  text-decoration: none;
  color: var(--text);
  letter-spacing: 0.01em;
  line-height: 1.3;
  margin-bottom: 40px;
}

.logo:hover { color: #555; }

/* =====================
   MENU
   ===================== */

.menu {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.menu-parent {
  color: var(--muted);
  font-size: 16px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  transition: color 0.2s ease;
  line-height: 1.5;
  cursor: pointer;
  background: none;
  border: none;
  padding: 5px 0;
  font-family: var(--font-body);
  font-style: normal;
  display: flex;
  align-items: center;
  gap: 6px;
}

.menu-parent:hover,
.menu-parent.open { color: var(--text); }

.menu-arrow {
  font-size: 9px;
  transition: transform 0.2s ease;
}

.menu-parent.open .menu-arrow { transform: rotate(90deg); }

.menu-sub {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  max-height: 0;
  opacity: 0;
  transition: max-height 0.3s ease, opacity 0.25s ease;
  padding-left: 12px;
  border-left: 1px solid #ddd;
  margin-left: 2px;
  width: 100%;
}

.menu-sub.open {
  max-height: 400px;
  opacity: 1;
  margin-top: 6px;
  margin-bottom: 6px;
}

.menu-item {
  text-decoration: none;
  color: var(--muted);
  font-size: 16px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-style: normal;
  transition: color 0.2s ease;
  line-height: 1.5;
  padding: 5px 0;
  display: block;
  width: 100%;
}

.menu-item:hover,
.menu-item.active { color: var(--text); }

.menu-divider {
  width: 100%;
  height: 1px;
  background: #e0e0e0;
  margin: 16px 0;
}

.menu-icons {
  display: flex;
  gap: 14px;
  margin-top: 16px;
  align-items: center;
}

.menu-icons a {
  color: var(--muted);
  transition: color 0.2s ease;
  display: flex;
  align-items: center;
  text-decoration: none;
}

.menu-icons a:hover { color: var(--text); }
.menu-icons svg { display: block; fill: currentColor; }

/* hamburger — hidden on desktop */
.hamburger {
  display: none;
  position: fixed;
  top: 20px;
  right: 20px;
  z-index: 200;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}

.hamburger span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--text);
  transition: all 0.3s ease;
}

.hamburger.open span:nth-child(1) { transform: rotate(45deg) translate(5px, 5px); }
.hamburger.open span:nth-child(2) { opacity: 0; }
.hamburger.open span:nth-child(3) { transform: rotate(-45deg) translate(5px, -5px); }

/* =====================
   MAIN VIEWER
   ===================== */

.main {
  margin-left: var(--sidebar-width);
  flex: 1;
  height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.viewer {
  position: relative;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 80px;
}

.viewer img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  opacity: 0;
  transition: opacity 0.4s ease;
}

.viewer img.loaded { opacity: 1; }

.nav-prev,
.nav-next {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  font-size: 22px;
  color: var(--muted);
  cursor: pointer;
  padding: 16px;
  z-index: 20;
}

.nav-prev { left: calc(var(--sidebar-width) + 8px); }
.nav-next { right: 16px; }
.nav-prev:hover,
.nav-next:hover { color: var(--text); }

.project-title-overlay {
  position: absolute;
  bottom: 20px;
  right: 40px;
  font-size: 11px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  font-style: normal;
  color: var(--muted);
  z-index: 20;
  pointer-events: none;
}

.group-label {
  position: absolute;
  bottom: 20px;
  left: 20px;
  font-size: 11px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  font-style: normal;
  color: var(--muted);
  pointer-events: none;
  z-index: 30;
  opacity: 0;
}

.group-label.visible { opacity: 1; }

/* =====================
   GRID PAGES
   ===================== */

.page-content {
  margin-left: var(--sidebar-width);
  width: calc(100vw - var(--sidebar-width));
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 60px 40px 80px;
}

.page-title {
  font-family: var(--font-display);
  font-size: 13px;
  font-style: normal;
  letter-spacing: 0.04em;
  color: var(--muted);
  text-transform: uppercase;
  margin-bottom: 40px;
}

.grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
  max-width: 1100px;
  width: 100%;
  margin: 0 auto;
}

.project { text-decoration: none; color: var(--text); }

.project img {
  width: 100%;
  height: 60vh;
  object-fit: cover;
}

.project-label {
  font-size: 13px;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  font-style: normal;
  color: var(--muted);
  margin-top: 12px;
}

/* =====================
   ABOUT + CONTACT
   ===================== */

.text-content {
  margin-left: var(--sidebar-width);
  padding: 80px 100px 120px 120px;
  width: calc(100vw - var(--sidebar-width));
  min-height: 100vh;
}

/* =====================
   ABOUT LAYOUT
   ===================== */

.about-row {
  display: flex;
  align-items: flex-start;
  gap: 80px;
  margin-bottom: 50px;
  width: 100%;
}

.about-photo-wrap {
  flex: 0 0 420px;
  padding-top: 120px;
}

.about-photo {
  width: 420px;
  height: auto;
  display: block;
  margin-left: 100px;
}

.about-text {
  flex: 1;
  max-width: 500px;
}

.about-text h1 {
  font-family: var(--font-display);
  font-size: 48px;
  font-style: normal;
  font-weight: normal;
  margin-bottom: 16px;
}

.about-text hr {
  border: none;
  border-top: 1px solid #ddd;
  margin-bottom: 28px;
  width: 225%;
}

.about-text p {
  font-size: 20px;
  font-style: normal;
  line-height: 1.75;
  margin-bottom: 18px;
}

.about-text h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-style: normal;
  font-weight: normal;
  margin-top: 28px;
  margin-bottom: 10px;
}

/* =====================
   PRESS SECTION
   ===================== */

.press-section {
  padding-top: 80px;
  padding-bottom: 100px;
  width: 100%;
}

.press-section h3 {
  font-family: var(--font-display);
  font-size: 20px;
  font-style: normal;
  font-weight: normal;
}

.press-row {
  display: flex;
  align-items: flex-start;
  gap: 40px;
  width: 91%;
  padding-top: 35px;
  margin-top: 30px;
}

.press-text { max-width: 720px; }

.press-text p {
  font-size: 20px;
  font-style: normal;
  line-height: 1.7;
}

.press-photo img {
  width: 800px;
  height: auto;
  display: block;
  margin-left: 100px;
}

/* =====================
   CONTACT PAGE
   ===================== */

  .page-heading {
  font-family: var(--font-display);
  font-size: 48px;
  font-style: normal;
  font-weight: normal;
  border-bottom: 1px solid #ddd;
  padding-bottom: 30px;
  margin-bottom: 10px;
}

.contact-item { 
  margin-top: 5px;
  margin-bottom: 30px; 
}

.contact-label {
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-style: normal;
  color: var(--muted);
  display: block;
  margin-bottom: 6px;
}

.contact-value {
  font-size: 24px;
  font-style: normal;
  text-decoration: none;
  color: var(--text);
}

.contact-value:hover { color: #666; }

/* =====================
   HOME HERO
   ===================== */

.home-hero {
  width: 90%;
  margin: 0 auto 80px auto;
}

.home-hero a { display: block; }

.home-hero img {
  width: 100%;
  height: 85vh;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.home-hero:hover img { transform: scale(1.02); }

/* =====================
   TABLET — iPad (768px–1024px)
   ===================== */

@media (max-width: 1024px) and (min-width: 768px) {
  :root { --sidebar-width: 240px; }

  .logo { font-size: 28px; }

  .page-content { padding: 50px 30px 60px; }

  .grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
  }

  .project img { height: 40vh; }

  .text-content { padding: 60px 60px 80px 60px; }

  .about-row { gap: 40px; }

  .about-photo-wrap {
    flex: 0 0 280px;
    padding-top: 80px;
  }

  .about-photo {
    width: 280px;
    margin-left: 0;
  }

  .about-text hr { width: 160%; }

  .press-photo img {
    width: 400px;
    margin-left: 0;
  }

  .home-hero { width: 100%; }
  .home-hero img { height: 70vh; }
}

/* =====================
   MOBILE — iPhone + Android (< 768px)
   ===================== */

@media (max-width: 767px) {

  body { flex-direction: column; }

  /* Show hamburger */
  .hamburger { display: flex; }

  /* Sidebar becomes full-screen overlay */
  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    padding: 60px 36px 40px;
    transform: translateX(-100%);
    transition: transform 0.3s ease;
    overflow-y: auto;
    z-index: 150;
  }

  .sidebar.mobile-open {
    transform: translateX(0);
  }

  .logo { font-size: 28px; margin-bottom: 30px; }

.mobile-topbar {
  display: flex;
  background-color: red;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background: var(--bg);
  z-index: 99;
  border-bottom: 1px solid #eee;
}

.mobile-logo {
  font-family: var(--font-display);
  font-size: 22px;
  text-decoration: none;
  color: var(--text);
}

  /* Main content — full width, pushed down from topbar */
  .main,
  .page-content,
  .text-content {
    margin-left: 0;
    width: 100%;
    padding-top: 70px;
  }

  .main {
    height: calc(100vh - 60px);
  }

  .viewer { padding: 20px; }

  .nav-prev { left: 8px; }
  .nav-next { right: 8px; }

  /* Grid — single column */
  .grid {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .project img { height: 50vw; }

  .page-content { padding: 70px 20px 60px; }

  /* About — stack vertically */
  .text-content { padding: 70px 24px 60px; }

  .about-row {
    flex-direction: column;
    gap: 30px;
    margin-bottom: 40px;
  }

  .about-photo-wrap {
    flex: none;
    width: 100%;
    padding-top: 0;
  }

  .about-photo {
    width: 100%;
    margin-left: 0;
  }

  .about-text {
    max-width: 100%;
  }

  .about-text h1 { font-size: 32px; }
  .about-text h3 { font-size: 18px; }
  .about-text p  { font-size: 17px; }
  .about-text hr { width: 100%; }

  /* Press */
  .press-row {
    flex-direction: column;
    gap: 24px;
    width: 100%;
  }

  .press-photo img {
    width: 100%;
    margin-left: 0;
  }

  .press-text { max-width: 100%; }
  .press-text p { font-size: 17px; }

  /* Contact */
  .contact-value { font-size: 20px; }

  /* Hero */
  .home-hero { width: 100%; margin-bottom: 40px; }
  .home-hero img { height: 50vh; }

  /* Viewer title */
  .project-title-overlay {
    bottom: 10px;
    right: 16px;
    font-size: 10px;
  }
}