/* =============================================
   PETER WEGNER v2 — site styles
   ============================================= */

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

:root {
  --black: #000;
  --white: #fff;
  --gray: #999;
  --red: #c00;
  --font: "aktiv-grotesk", "Aktiv Grotesk", "Akzidenz-Grotesk",
          "Acumin Pro", "Gill Sans", "Franklin Gothic Medium", sans-serif;
  --nav-size: 9px;
  --gap: 10px;
}

html, body {
  height: 100%;
}

body {
  font-family: var(--font);
  background: var(--white);
  color: var(--black);
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

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

a:hover { color: var(--gray); }

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

/* ── LAYOUT ── */

.site-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 30px var(--gap) 60px;
}

/* ── HEADER ── */

header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding-bottom: 10px;
  border-bottom: 0.5px solid var(--black);
  margin-bottom: 20px;
  flex-wrap: wrap;
  gap: 8px;
}

.site-title {
  font-size: 19px;
  font-weight: bold;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #333;
  flex-shrink: 0;
}

nav {
  display: flex;
  gap: 20px;
  font-size: var(--nav-size);
  font-weight: bold;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  flex-wrap: wrap;
}

nav a { color: var(--black); }
nav a:hover { color: var(--gray); }
nav a.active { color: var(--red); }

/* ── CATEGORY GRID (level 1) ── */

.grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  column-gap: var(--gap);
  row-gap: 7px;
}

.grid-item {
  min-width: 0;
  cursor: pointer;
}

.grid-item a {
  display: block;
}

.grid-item img {
  width: 100%;
  display: block;
  aspect-ratio: 1;
  object-fit: cover;
  transition: opacity 0.15s ease;
}

.grid-item a:hover img { opacity: 0.85; }

.grid-item .caption {
  font-size: 9px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-top: 5px;
  color: var(--black);
}

/* ── PROJECT GRID (level 2) ── */

.project-header {
  margin-bottom: 20px;
}

.project-header h1 {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.project-back {
  font-size: var(--nav-size);
  font-weight: bold;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 16px;
  display: block;
}

.project-back:hover { color: var(--gray); }

.thumb-grid {
  columns: 3;
  column-gap: var(--gap);
}

.thumb-item {
  break-inside: avoid;
  margin-bottom: var(--gap);
  cursor: pointer;
}

.thumb-item img {
  width: 100%;
  display: block;
  transition: opacity 0.15s ease;
}

.thumb-item:hover img { opacity: 0.85; }

/* ── LIGHTBOX ── */

.lightbox {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.93);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.lightbox.open { display: flex; }

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

.lightbox-img-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 0;
}

.lightbox-img-wrap img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  display: block;
}

.lightbox-caption {
  margin-top: 16px;
  font-size: 12px;
  line-height: 1.6;
  letter-spacing: 0.04em;
  color: #ccc;
  text-align: left;
  width: 100%;
  max-width: 800px;
}

.lightbox-caption strong {
  font-weight: 700;
  color: #fff;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 28px;
  font-size: var(--nav-size);
  font-weight: bold;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #fff;
  cursor: pointer;
  background: none;
  border: none;
  padding: 4px;
}

.lightbox-close:hover { color: #999; }

.lightbox-prev,
.lightbox-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 20px;
  color: #fff;
  cursor: pointer;
  background: none;
  border: none;
  padding: 10px;
  opacity: 0.6;
  transition: opacity 0.15s;
}

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

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

.lightbox-counter {
  position: absolute;
  top: 24px;
  left: 28px;
  font-size: var(--nav-size);
  font-weight: bold;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #666;
}

/* ── ABOUT ── */

.about-slideshow { margin-bottom: 0; }

.about-slides { position: relative; }

.about-slide {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  opacity: 0;
  transition: opacity 0.8s ease;
  pointer-events: none;
}

.about-slide.active {
  position: relative;
  opacity: 1;
  pointer-events: auto;
}

.about-slide img { width: 100%; height: auto; display: block; }

.about-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 10px;
  margin-bottom: 20px;
}

.dot {
  width: 9px; height: 9px;
  border-radius: 50%;
  border: none;
  background: #bbb;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s ease;
}

.dot.active { background: #666; }

.about-rule {
  border: none;
  border-top: 0.5px solid var(--black);
  margin: 0 0 20px;
}

.about-text p {
  font-size: 13px;
  line-height: 1.5;
  margin-bottom: 1em;
  color: #333;
}

.about-links {
  margin-top: 20px;
  font-size: 12px;
  font-weight: bold;
  line-height: 1.5;
  color: #333;
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.about-links-sep { color: #888; font-weight: normal; padding: 0 1px; }
.about-links a { color: #333; }
.about-links a:hover { color: var(--gray); }

/* ── RESPONSIVE ── */

@media (max-width: 700px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .grid-item .caption { display: none; }
  .thumb-grid { columns: 2; }
  .lightbox-inner { padding: 60px 40px 20px; }
  .lightbox-prev { left: 6px; }
  .lightbox-next { right: 6px; }
  nav { gap: 12px; }
}
