:root {
  --bg: #0b0d12;
  --bg-soft: #11141b;
  --surface: rgba(255, 255, 255, 0.04);
  --surface-2: rgba(255, 255, 255, 0.07);
  --border: rgba(255, 255, 255, 0.08);
  --text: #e7eaf0;
  --muted: #8b93a7;
  --accent: #7c5cff;
  --accent-2: #22d3ee;
  --radius: 14px;
  --shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

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

/* Background effects */
.bg-grid {
  position: fixed;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(ellipse at top, #000 0%, transparent 70%);
  pointer-events: none;
  z-index: -2;
}

.bg-glow {
  position: fixed;
  top: -20%;
  left: 50%;
  transform: translateX(-50%);
  width: 800px;
  height: 800px;
  background: radial-gradient(circle, rgba(124, 92, 255, 0.25), transparent 60%);
  filter: blur(60px);
  pointer-events: none;
  z-index: -1;
}

/* Header */
.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.25rem 2rem;
  max-width: 1200px;
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-weight: 800;
  font-size: 1.15rem;
  letter-spacing: -0.02em;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  border-radius: 8px;
  color: white;
  font-size: 0.9rem;
  font-weight: 800;
}

.nav { display: flex; gap: 0.4rem; }

.nav a {
  padding: 0.5rem 0.95rem;
  border-radius: 999px;
  color: var(--muted);
  font-weight: 500;
  font-size: 0.93rem;
  transition: all 0.2s;
}

.nav a:hover { color: var(--text); background: var(--surface); }
.nav a.active { color: var(--text); background: var(--surface-2); }

/* Main */
main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem;
}

/* Hero */
.hero { text-align: center; padding: 3.5rem 1rem 2.5rem; }
.hero-portfolio { padding-bottom: 2rem; }

.badge {
  display: inline-block;
  padding: 0.4rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  font-size: 0.82rem;
  color: var(--muted);
  margin-bottom: 1.5rem;
}

.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 4rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.04em;
  margin: 0 0 1.2rem;
}

.grad {
  background: linear-gradient(135deg, var(--accent), var(--accent-2));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lead {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 620px;
  margin: 0 auto 1.5rem;
}

/* Gallery */
.gallery { padding: 1rem 0 3rem; }

/* Album-Übersicht */
.album-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 1.2rem;
}

.album {
  display: block;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  overflow: hidden;
  animation: fadeUp 0.6s both;
  animation-delay: calc(var(--i, 0) * 70ms);
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

.album:hover {
  transform: translateY(-4px);
  border-color: rgba(124, 92, 255, 0.45);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.45);
}

.album-cover {
  aspect-ratio: 4 / 3;
  overflow: hidden;
  background: var(--bg-soft);
}

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

.album:hover .album-cover img { transform: scale(1.06); }

.album-meta {
  padding: 0.95rem 1.1rem 1.1rem;
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 0.6rem;
}

.album-meta h3 {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  text-transform: capitalize;
}

.album-meta span {
  color: var(--muted);
  font-size: 0.82rem;
  white-space: nowrap;
}

/* Album-Detail */
.album-header {
  text-align: center;
  padding: 2.5rem 1rem 1.5rem;
}

.album-header h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0.4rem 0 0.6rem;
  text-transform: capitalize;
}

.album-header .lead { margin-bottom: 0; }

.back-link {
  display: inline-block;
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.85rem;
  transition: background 0.2s, color 0.2s;
}

.back-link:hover { color: var(--text); background: var(--surface-2); }

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

.photo {
  position: relative;
  display: block;
  aspect-ratio: 1 / 1;
  overflow: hidden;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--surface);
  cursor: zoom-in;
  animation: fadeUp 0.6s both;
  animation-delay: calc(var(--i, 0) * 60ms);
  transition: transform 0.25s, border-color 0.25s, box-shadow 0.25s;
}

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

.photo:hover {
  transform: translateY(-3px);
  border-color: rgba(124, 92, 255, 0.4);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4);
}

.photo:hover img { transform: scale(1.05); }

.photo-caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 0.85rem 1rem 0.7rem;
  font-size: 0.88rem;
  color: #fff;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.7), transparent);
  opacity: 0;
  transform: translateY(6px);
  transition: opacity 0.25s, transform 0.25s;
}

.photo:hover .photo-caption { opacity: 1; transform: translateY(0); }

.empty {
  text-align: center;
  padding: 3rem 1.5rem;
  max-width: 520px;
  margin: 0 auto;
}

.empty h3 { margin: 0 0 0.5rem; font-weight: 700; }
.empty p { color: var(--muted); margin: 0; }
.empty code {
  background: rgba(0, 0, 0, 0.35);
  padding: 0.15rem 0.45rem;
  border-radius: 5px;
  font-size: 0.88rem;
}

/* Lightbox */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(5, 7, 12, 0.92);
  z-index: 100;
  display: grid;
  grid-template-columns: auto 1fr auto;
  grid-template-rows: 1fr auto;
  grid-template-areas:
    "prev stage next"
    "thumbs thumbs thumbs";
  align-items: center;
  padding: 2rem 1rem 1rem;
  gap: 1rem;
  animation: fade 0.2s ease;
}

.lightbox[hidden] { display: none; }

.lightbox-stage {
  grid-area: stage;
  display: grid;
  place-items: center;
  position: relative;
  min-width: 0;
  min-height: 0;
  width: 100%;
  height: 100%;
}

.lightbox-img {
  max-width: 100%;
  max-height: 72vh;
  border-radius: 10px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.6);
  object-fit: contain;
}

.lightbox-caption {
  margin-top: 0.8rem;
  color: var(--muted);
  font-size: 0.9rem;
  text-align: center;
}

.lightbox-close {
  position: absolute;
  top: 1.2rem;
  right: 1.4rem;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 1.6rem;
  line-height: 1;
  cursor: pointer;
  transition: background 0.2s, transform 0.15s;
  z-index: 2;
}

.lightbox-close:hover { background: var(--surface-2); transform: scale(1.05); }

.lightbox-nav {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  font-size: 2rem;
  line-height: 1;
  cursor: pointer;
  display: grid;
  place-items: center;
  padding: 0 0 4px;
  transition: background 0.2s, transform 0.15s, border-color 0.2s;
}

.lightbox-nav:hover {
  background: var(--surface-2);
  border-color: rgba(124, 92, 255, 0.45);
  transform: scale(1.05);
}

.lightbox-nav[hidden] { display: none; }
.lightbox-prev { grid-area: prev; }
.lightbox-next { grid-area: next; }

.lightbox-thumbs {
  grid-area: thumbs;
  display: flex;
  gap: 0.5rem;
  overflow-x: auto;
  padding: 0.6rem 0.4rem;
  scrollbar-width: thin;
  scrollbar-color: var(--surface-2) transparent;
  justify-content: safe center;
  scroll-behavior: smooth;
}

.lightbox-thumbs::-webkit-scrollbar { height: 8px; }
.lightbox-thumbs::-webkit-scrollbar-track { background: transparent; }
.lightbox-thumbs::-webkit-scrollbar-thumb {
  background: var(--surface-2);
  border-radius: 999px;
}

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

.lightbox-thumb {
  flex: 0 0 auto;
  width: 76px;
  height: 76px;
  padding: 0;
  border-radius: 8px;
  border: 2px solid transparent;
  background: var(--surface);
  cursor: pointer;
  overflow: hidden;
  opacity: 0.6;
  transition: opacity 0.2s, border-color 0.2s, transform 0.15s;
}

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

.lightbox-thumb:hover {
  opacity: 1;
  transform: translateY(-2px);
}

.lightbox-thumb.is-active {
  opacity: 1;
  border-color: var(--accent);
  box-shadow: 0 0 0 2px rgba(124, 92, 255, 0.25);
}

/* Pages */
.page { padding: 3rem 0; max-width: 720px; margin: 0 auto; }

.page h1 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  margin: 0 0 1rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem;
  margin: 1.2rem 0;
}

.card h3 { margin: 0 0 0.5rem; font-size: 1.1rem; font-weight: 700; }
.card p { margin: 0; color: var(--muted); font-size: 0.95rem; }

.link { color: var(--accent-2); border-bottom: 1px dashed rgba(34, 211, 238, 0.4); }
.link:hover { color: var(--text); }

/* Footer */
.site-footer {
  max-width: 1200px;
  margin: 3rem auto 0;
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  color: var(--muted);
  flex-wrap: wrap;
  gap: 0.5rem;
}

.site-footer a:hover { color: var(--text); }

/* Animations */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

@keyframes fade {
  from { opacity: 0; }
  to { opacity: 1; }
}

@media (max-width: 600px) {
  .site-header { padding: 1rem; }
  main { padding: 1rem; }
  .hero { padding: 2rem 0.5rem; }
  .photo-grid { grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 0.6rem; }
}
