:root {
  --bg: #0f0f0f;
  --surface: #151515;
  --muted: #aeaeb3;
  --accent: #ff6b6b;
  --max-width: 1200px;
}

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

body {
  font-family:
    "Inter",
    system-ui,
    -apple-system,
    "Segoe UI",
    Roboto,
    "Helvetica Neue",
    Arial;
  background: linear-gradient(180deg, var(--bg) 0%, #090909 100%);
  color: #f5f5f5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  line-height: 1.45;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

nav {
  width: 100%;
  position: sticky;
  top: 0;
  z-index: 200;
  background: linear-gradient(180deg, var(--surface), #0f0f0f);
  padding: 14px 18px;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: center;
  gap: 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

nav h2 {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: 0.4px;
  margin-bottom: 6px;
  color: #fff;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 12px;
  align-items: center;
}

nav a {
  text-decoration: none;
  color: #e8e8e8;
  display: block;
  padding: 10px 14px;
  border-radius: 6px;
  transition:
    background 0.15s ease,
    transform 0.12s ease;
  font-weight: 600;
}

nav a.active,
nav a[aria-current="page"] {
  background: rgba(255, 107, 107, 0.14);
  color: #fff;
  box-shadow: 0 0 0 1px rgba(255, 107, 107, 0.22) inset;
}

nav a.active:hover,
nav a[aria-current="page"]:hover {
  background: rgba(255, 107, 107, 0.2);
}

@media (max-width: 700px) {
  nav a.active,
  nav a[aria-current="page"] {
    background: none;
    color: #e8e8e8;
    box-shadow: none;
  }
  nav a.active:hover,
  nav a[aria-current="page"]:hover {
    background: none;
  }
}

nav a:hover {
  background: rgba(255, 107, 107, 0.06);
  transform: translateY(-2px) scale(1.04);
}

.nav-toggle {
  display: none;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.08);
  color: #fff;
  padding: 10px 14px;
  border-radius: 10px;
  font-weight: 700;
  letter-spacing: 0.3px;
  cursor: pointer;
  transition:
    background 0.2s ease,
    transform 0.12s ease;
}

.nav-toggle:active {
  transform: scale(0.98);
}

.content {
  max-width: var(--max-width);
  padding: 48px 36px;
  margin: 0 auto;
  width: 100%;
}

header {
  padding-bottom: 18px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

header h1 {
  font-size: 2.25rem;
  font-weight: 700;
  letter-spacing: 1px;
  color: #ffffff;
}

@media (max-width: 700px) {
  .content {
    padding: 24px 16px;
  }
  header h1 {
    font-size: 1.9rem;
  }
}

.intro {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
  padding: 20px;
  border-radius: 10px;
  margin-bottom: 26px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.6);
}

.intro p {
  color: var(--muted);
  font-size: 1rem;
}

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin: 0 auto;
  padding: 18px 0;
  width: 100%;
  max-width: 1200px;
}

.gallery img {
  width: 100%;
  height: auto;
  border-radius: 12px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
  object-fit: cover;
  transition: transform 0.18s;
}

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


@media (max-width: 900px) {
  .gallery {
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 16px;
    padding: 12px 0;
  }
}

@media (max-width: 640px) {
  .gallery {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
    padding: 10px 0;
  }
  .gallery img {
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
  }
}

@media (max-width: 420px) {
  .gallery {
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 10px;
  }
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(3, 3, 3, 0.92);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
  z-index: 2000;
}

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

.lightbox-content {
  max-width: 92%;
  max-height: 92%;
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: center;
}

.lightbox img {
  max-width: 90vw;
  max-height: 90vh;
  border-radius: 8px;
  transform: scale(0.92);
  transition: transform 0.28s ease;
  box-shadow: 0 18px 50px rgba(0, 0, 0, 0.7);
}

.lightbox.active img {
  transform: scale(1);
}

.caption {
  max-width: 320px;
  color: #dddddd;
  font-size: 0.98rem;
  line-height: 1.5;
}

.lightbox::after {
  content: "✕";
  position: absolute;
  top: 28px;
  right: 32px;
  font-size: 1.8rem;
  color: #fff;
  cursor: pointer;
}

@media (max-width: 820px) {
  .lightbox-content {
    flex-direction: column;
    max-width: 92vw;
    max-height: 92vh;
    gap: 12px;
  }
  .lightbox img {
    width: 100%;
    max-height: 60vh;
    object-fit: contain;
  }
  .caption {
    max-width: 100%;
    text-align: center;
    background: rgba(255, 255, 255, 0.03);
    padding: 12px 14px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.45);
  }
  .lightbox::after {
    top: 16px;
    right: 18px;
  }
}

footer {
  color: var(--muted);
  padding: 24px 0 60px 0;
  font-size: 0.95rem;
}

.contact-card {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
  padding: 22px;
  border-radius: 10px;
  max-width: 680px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.contact-card label {
  display: block;
  margin-bottom: 6px;
  font-weight: 600;
  color: #eaeaea;
}
.contact-card input,
.contact-card textarea {
  width: 100%;
  padding: 10px 12px;
  margin-bottom: 12px;
  border-radius: 6px;
  border: 1px solid rgba(255, 255, 255, 0.06);
  background: rgba(255, 255, 255, 0.02);
  color: #fff;
}
.contact-card button {
  background: var(--accent);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  font-weight: 700;
}

@media (max-width: 900px) {
  nav {
    position: sticky;
    top: 0;
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    gap: 10px;
    padding: 12px 14px;
  }
  .nav-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
  }
  .nav-list {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    padding: 12px 14px 14px 14px;
    flex-direction: column;
    background: rgba(12, 12, 12, 0.98);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    display: none;
    gap: 10px;
    box-shadow: 0 16px 30px rgba(0, 0, 0, 0.35);
  }
  nav.open .nav-list {
    display: flex;
  }
  .nav-list li {
    width: 100%;
  }
  .nav-list a {
    width: 100%;
    text-align: left;
    padding: 12px 14px;
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(255, 255, 255, 0.05);
  }
  .content {
    margin-left: 0;
    padding: 20px;
  }
}

.profile-card {
  display: flex;
  gap: 20px;
  align-items: center;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), transparent);
  padding: 22px;
  border-radius: 12px;
  max-width: 900px;
  margin-top: 18px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.6);
}

.avatar {
  width: 180px;
  height: 180px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 180px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.6);
  border: 4px solid rgba(255, 255, 255, 0.03);
}

.profile-meta {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.profile-meta h2 {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 700;
  color: #fff;
}

.profile-meta p {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.5;
}

.profile-tags {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px;
}
.profile-tags .tag {
  background: rgba(255, 255, 255, 0.03);
  color: #e8e8e8;
  padding: 6px 10px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.85rem;
}

@media (max-width: 720px) {
  .profile-card {
    flex-direction: column;
    text-align: center;
    padding: 18px;
  }
  .avatar {
    width: 140px;
    height: 140px;
    flex: 0 0 140px;
  }
  .profile-meta {
    align-items: center;
  }
}

/* Begrenzung für Bilder in .case .media (Projekte.html) */
.case .media img {
  max-width: 420px;
  max-height: 60vh;
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: 10px;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.6);
  display: block;
  margin: 0 auto;
}
