/* ========================================
   Robert May Photography — Design System
   Ported from original HTML files
   ======================================== */

/* ----------------------------------------
   1. Reset & Base
   ---------------------------------------- */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  background: #1a1a1a;
  min-height: 100vh;
  display: flex;
}

/* ----------------------------------------
   2. Sidebar
   ---------------------------------------- */
.sidebar::-webkit-scrollbar { display: none; }
.sidebar {
  width: 340px;
  min-height: 100vh;
  background: #0c0c0c;
  border-right: 1px solid #222;
  display: flex;
  flex-direction: column;
  padding: 3rem 2.5rem;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  overflow-y: auto;
  scrollbar-width: none;
  -ms-overflow-style: none;
  z-index: 100;
}

.masthead-link { text-decoration: none; color: inherit; transition: text-shadow 0.3s ease; }
.masthead-link:hover { text-shadow: 0 0 12px rgba(255, 255, 255, 0.4); }
.masthead {
  margin-bottom: 0;
  border-bottom: 2px solid #fff;
  padding-bottom: 0.8rem;
}

.masthead h1 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 3.2rem;
  line-height: 0.92;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: #fff;
}

.masthead-sub {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #999;
  margin-top: 1.2rem;
}

.issue-line {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #777;
  padding: 0.8rem 0;
  border-bottom: 1px solid #222;
  margin-bottom: 1.5rem;
}

.disciplines {
  flex: 1;
  display: flex;
  flex-direction: column;
  gap: 0.2rem;
}

.disciplines a {
  display: block;
  font-family: 'Cormorant', serif;
  font-weight: 400;
  font-size: 1.65rem;
  line-height: 1.15;
  color: #aaa;
  text-decoration: none;
  padding: 0.55rem 0;
  border-bottom: 1px solid #1a1a1a;
  transition: color 0.25s ease, padding-left 0.25s ease;
}

.disciplines a:hover {
  color: #fff;
  padding-left: 0.4rem;
}

.disciplines a.active {
  color: #fff;
  font-weight: 500;
}

.disciplines a .discipline-sub {
  display: block;
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #777;
  margin-top: 0.15rem;
  transition: color 0.25s ease;
}

.disciplines a:hover .discipline-sub {
  color: #bbb;
}

.disciplines a.active .discipline-sub {
  color: #999;
}

.sidebar-footer {
  margin-top: 2.5rem;
  padding-top: 1.2rem;
  border-top: 1px solid #1e1e1e;
}

.sidebar-footer a {
  display: block;
  font-family: 'Cormorant', serif;
  font-weight: 400;
  font-style: italic;
  font-size: 1.4rem;
  color: #999;
  text-decoration: none;
  transition: color 0.25s ease;
  margin-bottom: 0.6rem;
}

.sidebar-footer a:hover {
  color: #fff;
}

.sidebar-footer .location {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #888;
}

/* ----------------------------------------
   3. Burger
   ---------------------------------------- */
.burger {
  display: none;
  position: fixed;
  top: 1.2rem;
  left: 1.2rem;
  z-index: 200;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #fff;
  margin-bottom: 5px;
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.burger span:last-child { margin-bottom: 0; }

.burger.open span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.burger.open span:nth-child(2) {
  opacity: 0;
}

.burger.open span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  z-index: 90;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.overlay.visible { opacity: 1; }

/* ----------------------------------------
   4. Main Content Area
   ---------------------------------------- */
.site-layout {
  display: flex;
  min-height: 100vh;
  width: 100%;
}

.main {
  margin-left: 340px;
  flex: 1;
  min-height: 100vh;
  background: #141414;
}

/* ----------------------------------------
   5. Hero
   ---------------------------------------- */
.hero {
  width: 100%;
  height: 85vh;
  overflow: hidden;
  position: relative;
}

.hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* ----------------------------------------
   6. Intro
   ---------------------------------------- */
.intro {
  padding: 3.5rem 3rem 3rem;
  max-width: 800px;
  margin-left: auto;
  text-align: right;
}

.intro p {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.55rem;
  line-height: 1.75;
  color: #bbb;
}

.intro p em {
  font-style: italic;
  color: #ddd;
}

/* ----------------------------------------
   7. Section Dividers
   ---------------------------------------- */
.section-divider {
  padding: 4rem 3rem 2rem;
  border-top: 1px solid #2a2a2a;
  margin-top: 2rem;
}

.section-divider h2 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 3.8rem;
  color: #ddd;
  margin-bottom: 0;
}

.section-divider .section-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.95rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #555;
}

.section-divider.align-right {
  text-align: right;
  padding-left: 3rem;
  padding-right: 3rem;
}

.section-divider.align-right + .editorial {
  text-align: right;
  margin-left: auto;
  margin-right: 0;
  padding-right: 3rem;
}

/* Case study header */
.case-study-header {
  padding: 4rem 3rem 1rem;
  border-top: 1px solid #2a2a2a;
  margin-top: 2rem;
}

.case-study-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #555;
  margin-bottom: 0.8rem;
}

.case-study-header h2 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 3.2rem;
  color: #ddd;
  margin-bottom: 0.2rem;
}

.case-study-header .section-meta {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.85rem;
  font-weight: 300;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #555;
}

/* ----------------------------------------
   8. Editorial Text
   ---------------------------------------- */
.editorial {
  padding: 2rem 3rem 5rem;
  max-width: 620px;
}

.editorial p {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.35rem;
  line-height: 1.75;
  color: #999;
  font-style: italic;
}

.editorial p + p {
  margin-top: 1rem;
}

.editorial p em {
  font-style: normal;
  color: #ccc;
}

.editorial h2 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 2.4rem;
  color: #ddd;
  margin-bottom: 1rem;
}

.editorial.cta-centre {
  text-align: center;
  margin: 4rem auto 3rem;
  max-width: 720px;
  padding: 3rem 3rem 5rem;
}

.editorial.cta-centre p {
  font-style: normal;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.3rem;
  line-height: 1.8;
  color: #888;
  margin-bottom: 1.5rem;
}

.editorial.cta-centre p:last-child {
  margin-bottom: 0;
}

.editorial.cta-centre em {
  font-style: italic;
  color: #ccc;
}

.editorial.cta-centre a {
  font-family: 'Cormorant', serif;
  font-size: 1.4rem;
  font-weight: 400;
  color: #ccc;
  text-decoration: none;
  border-bottom: 1px solid #444;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.editorial.cta-centre a:hover {
  color: #fff;
  border-color: #fff;
}

.editorial.cta {
  border-left: 2px solid #555;
  padding-left: 1.5rem;
  margin: 3rem 0;
  max-width: 620px;
}

.editorial.cta a {
  color: #ccc;
  text-decoration: none;
  border-bottom: 1px solid #444;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.editorial.cta a:hover {
  color: #fff;
  border-color: #fff;
}

/* ----------------------------------------
   9. Feature Images
   ---------------------------------------- */
.feature {
  width: 100%;
  padding: 0;
  margin-bottom: 6px;
}

.feature img {
  width: 100%;
  object-fit: cover;
  display: block;
}

/* ----------------------------------------
  10. Image Grids
   ---------------------------------------- */
.grid-item {
  overflow: hidden;
  position: relative;
}

.grid-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.grid-item:hover img {
  transform: scale(1.03);
}

.grid-2-equal {
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 6px;
}

.grid-2x2 {
  padding: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 6px;
}

/* ----------------------------------------
  11. Homepage Mosaic
   ---------------------------------------- */
.mosaic {
  display: grid;
  grid-template-columns: repeat(12, 1fr);
  grid-auto-rows: minmax(120px, auto);
  gap: 6px;
  min-height: 100vh;
}

.mosaic a {
  position: relative;
  display: block;
  overflow: hidden;
  color: inherit;
  text-decoration: none;
}

.mosaic a img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.mosaic a:hover img {
  transform: scale(1.04);
}

.mosaic a .label {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 2.5rem 1.2rem 1.2rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.65));
  opacity: 0;
  transition: opacity 0.3s ease;
}

.mosaic a:hover .label {
  opacity: 1;
}

.label h3 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 1.4rem;
  color: #fff;
  letter-spacing: 0.04em;
  margin-bottom: 0.2rem;
}

.label span {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.55rem;
  color: #bbb;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

/* Grid placement — asymmetric mosaic */
.m-1 { grid-column: 1 / 8;  grid-row: 1 / 4; }    /* Travel - large landscape */
.m-3 { grid-column: 8 / 13; grid-row: 1 / 4; }     /* Street - square */
.m-4 { grid-column: 5 / 13; grid-row: 4 / 7; }     /* Commercial - wide right */
.m-5 { grid-column: 1 / 5;  grid-row: 4 / 7; }     /* Portraiture - narrow left */
.m-6 { grid-column: 8 / 13; grid-row: 7 / 10; }    /* Events - narrow right */
.m-8 { grid-column: 1 / 8;  grid-row: 7 / 10; }    /* Wildlife - wide left */

/* ----------------------------------------
  12. Video Hero & Placeholder
   ---------------------------------------- */
.video-hero {
  width: 100%;
  height: 85vh;
  overflow: hidden;
  position: relative;
  background: #0a0a0a;
}

.video-hero video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.video-hero-overlay {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 3rem;
  background: linear-gradient(transparent, rgba(0,0,0,0.7));
  pointer-events: none;
}

.video-hero-label {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.75rem;
  font-weight: 300;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #666;
}

.video-placeholder {
  width: 100%;
  aspect-ratio: 16/9;
  background: #0c0c0c;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 6px;
}

.video-inner {
  text-align: center;
}

.video-inner svg {
  width: 64px;
  height: 64px;
  margin-bottom: 1.2rem;
}

.video-inner p {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.8rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #444;
}

/* ----------------------------------------
  13. Journal
   ---------------------------------------- */
.journal-listing {
  min-height: 100vh;
}

.journal-posts {
  padding: 0 3rem 3rem;
  max-width: 800px;
}

.journal-entry {
  border-bottom: 1px solid #222;
}

.journal-entry a {
  display: block;
  text-decoration: none;
  color: inherit;
  padding: 2rem 0;
  transition: padding-left 0.25s ease;
}

.journal-entry a:hover {
  padding-left: 0.4rem;
}

.journal-entry-photo {
  width: 100%;
  max-height: 300px;
  overflow: hidden;
  margin-bottom: 1.2rem;
}

.journal-entry-photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.journal-entry time {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #555;
}

.journal-entry h3 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 2rem;
  color: #ddd;
  margin: 0.3rem 0 0.5rem;
  transition: color 0.25s ease;
}

.journal-entry a:hover h3 {
  color: #fff;
}

.journal-entry p {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.15rem;
  line-height: 1.6;
  color: #888;
  font-style: italic;
}

p.journal-tags {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.65rem;
  font-weight: 300;
  font-style: normal;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #555;
  margin-top: 0.6rem;
}

/* Single journal post */
.journal-post {
  min-height: 100vh;
}

.journal-hero {
  width: 100%;
  max-height: 60vh;
  overflow: hidden;
}

.journal-hero img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.journal-header {
  padding: 3rem 3rem 1rem;
  max-width: 800px;
}

.journal-header time {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #555;
}

.journal-header h2 {
  font-family: 'Cormorant', serif;
  font-weight: 300;
  font-size: 3.2rem;
  color: #ddd;
  margin: 0.3rem 0 0.5rem;
}

.journal-body {
  padding: 1rem 3rem 3rem;
  max-width: 800px;
}

.journal-body p {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  line-height: 1.8;
  color: #999;
  margin-bottom: 1.2rem;
}

.journal-body p em {
  font-style: italic;
  color: #ccc;
}

.journal-body p strong {
  font-weight: 500;
  color: #bbb;
}

.journal-body h1,
.journal-body h2,
.journal-body h3,
.journal-body h4,
.journal-body h5,
.journal-body h6 {
  font-family: 'Cormorant', serif;
  color: #ddd;
}

.journal-body h2 {
  font-weight: 300;
  font-size: 2.4rem;
  margin: 2rem 0 1rem;
}

.journal-body h3 {
  font-weight: 400;
  font-size: 1.8rem;
  color: #ccc;
  margin: 1.5rem 0 0.8rem;
}

.journal-body blockquote {
  border-left: 2px solid #555;
  padding-left: 1.5rem;
  margin: 1.5rem 0;
}

.journal-body blockquote p {
  color: #777;
  font-style: italic;
}

.journal-body img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5rem 0;
}

.journal-body a {
  color: #ccc;
  text-decoration: none;
  border-bottom: 1px solid #444;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.journal-body a:hover {
  color: #fff;
  border-color: #fff;
}

.journal-body ul, .journal-body ol {
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.25rem;
  line-height: 1.8;
  color: #999;
  margin: 0 0 1.2rem 1.5rem;
}

.journal-body code {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.9rem;
  background: #1a1a1a;
  padding: 0.15rem 0.4rem;
  color: #bbb;
}

.journal-body pre {
  background: #1a1a1a;
  padding: 1.2rem;
  margin: 1.2rem 0;
  overflow-x: auto;
}

.journal-body pre code {
  background: none;
  padding: 0;
}

.journal-footer {
  padding: 2rem 3rem 4rem;
  border-top: 1px solid #222;
  margin-top: 2rem;
  max-width: 800px;
}

.journal-footer a {
  font-family: 'Cormorant', serif;
  font-size: 1.2rem;
  color: #888;
  text-decoration: none;
  transition: color 0.25s ease;
}

.journal-footer a:hover {
  color: #fff;
}

.preview-banner {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.7rem;
  font-weight: 300;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #b08d57;
  border: 1px solid #b08d5744;
  text-align: center;
  padding: 0.6rem 1rem;
  margin-bottom: 2rem;
}

/* ----------------------------------------
  14. Error pages
   ---------------------------------------- */

.error-page {
  padding: 6rem 2rem;
  text-align: center;
}

.error-code {
  font-family: 'IBM Plex Mono', monospace;
  font-weight: 300;
  font-size: 5rem;
  color: #333;
  line-height: 1;
  margin-bottom: 2rem;
}

.error-page .editorial {
  text-align: center;
  margin: 0 auto;
}

.error-page .editorial a {
  color: #999;
  border-bottom: 1px solid #333;
  transition: color 0.25s ease, border-color 0.25s ease;
}

.error-page .editorial a:hover {
  color: #fff;
  border-color: #fff;
}

/* ----------------------------------------
  15. Responsive (max-width: 768px)
   ---------------------------------------- */
@media (max-width: 768px) {
  .burger {
    display: block;
  }

  .overlay {
    display: block;
    pointer-events: none;
  }

  .overlay.visible {
    pointer-events: auto;
  }

  .sidebar {
    transform: translateX(-100%);
    transition: transform 0.35s cubic-bezier(0.25, 0.46, 0.45, 0.94);
    z-index: 100;
    width: 85vw;
    max-width: 340px;
  }

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

  .main {
    margin-left: 0;
  }

  body {
    flex-direction: column;
  }

  .masthead h1 {
    font-size: 2.6rem;
  }

  .disciplines a {
    font-size: 1.5rem;
    padding: 0.5rem 0;
  }

  .hero {
    height: 50vh;
  }

  .intro {
    padding: 2.5rem 1.5rem 2rem;
  }

  .feature {
    padding: 0;
  }

  .grid-2-equal {
    padding: 0;
    margin-bottom: 6px;
    grid-template-columns: 1fr;
  }

  .grid-2x2 {
    grid-template-columns: 1fr;
  }

  .section-divider {
    padding: 3rem 1.5rem 1.5rem;
  }

  .case-study-header {
    padding: 3rem 1.5rem 1rem;
  }

  .editorial {
    padding: 2rem 1.5rem 1.5rem;
  }

  .editorial p {
    font-size: 1.15rem;
  }

  .mosaic {
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: auto;
  }

  .mosaic a {
    grid-column: auto !important;
    grid-row: auto !important;
    aspect-ratio: 4/3;
  }

  .mosaic a .label {
    opacity: 1;
  }

  .video-hero {
    height: 50vh;
  }

  .video-hero-overlay {
    padding: 1.5rem;
  }

  .journal-posts {
    padding: 0 1.5rem 2rem;
  }

  .journal-header {
    padding: 2rem 1.5rem 1rem;
  }

  .journal-header h2 {
    font-size: 2.4rem;
  }

  .journal-body {
    padding: 1rem 1.5rem 2rem;
  }

  .journal-footer {
    padding: 1.5rem 1.5rem 3rem;
  }

}
