html, body { height: 100%; }

body {
  margin: 0;
  background: #0b0b0d url('back.jpg') center / cover no-repeat fixed;
  font-family: system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: #111;
}

.wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(16px, 4vw, 48px);
  box-sizing: border-box;
}

.grid {
  width: min(1120px, 100%);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(10px, 1.8vw, 18px);
}

.tile {
  margin: 0;
  border-radius: 14px;
  overflow: hidden;
  box-shadow: 0 10px 30px rgba(0,0,0,0.35);
  background: rgba(255,255,255,0.06);
  backdrop-filter: blur(2px);
  aspect-ratio: 4 / 3;
  cursor: zoom-in;
}

.tile img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  user-select: none;
  -webkit-user-drag: none;
}

/* Footer-Link unten */
.footer {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 10px;
  text-align: center;
  pointer-events: none;
  z-index: 2;
}

.footer a {
  pointer-events: auto;
  display: inline-block;
  padding: 10px 14px;
  border-radius: 999px;
  color: rgba(255,255,255,0.92);
  text-decoration: none;
  font-weight: 600;
  letter-spacing: 0.02em;
  background: rgba(0,0,0,0.45);
  box-shadow: 0 10px 30px rgba(0,0,0,0.25);
}

.footer a:hover { filter: brightness(1.08); }

/* Impressum Card */
.card {
  width: min(760px, 100%);
  background: rgba(255,255,255,0.92);
  border-radius: 18px;
  padding: clamp(16px, 3vw, 28px);
  box-shadow: 0 18px 45px rgba(0,0,0,0.35);
  line-height: 1.55;
}

.card h1 {
  margin: 0 0 14px 0;
  font-size: clamp(22px, 2.4vw, 30px);
}

.card p { margin: 10px 0; }
.card .small { font-size: 0.9rem; color: #333; }

/* Overlay / Modal */
.overlay[hidden] { display: none; }

.overlay {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: clamp(14px, 3vw, 30px);
  background: rgba(0,0,0,0.72);
  backdrop-filter: blur(4px);
}

.overlay img {
  border-radius: 14px;
  box-shadow: 0 18px 60px rgba(0,0,0,0.55);
  max-width: 92vw;
  max-height: 92vh;
  object-fit: contain;
  cursor: zoom-out;
}

.overlay-close {
  position: fixed;
  top: 14px;
  right: 14px;
  width: 44px;
  height: 44px;
  border: 0;
  border-radius: 999px;
  background: rgba(255,255,255,0.18);
  color: rgba(255,255,255,0.95);
  font-size: 28px;
  line-height: 44px;
  cursor: pointer;
}

.overlay-close:hover { filter: brightness(1.08); }

@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 560px) {
  body { background-attachment: scroll; }
  .grid { grid-template-columns: 1fr; }
  .footer { bottom: 8px; }
}
