body {
    margin: 0;
    padding: 0;
    background-color: rgb(255, 57, 195); /* das ist der rote Hintergrund */
    background-image: url("dein-schloss.png");
    background-repeat: no-repeat;
    background-position: center center;
    background-size: contain; /* oder cover */
    min-height: 100vh;
}

body{
  margin:0;
  font-family: 'Great Vibes', cursive;
  background: rgb(255, 57, 195);
  color: white;
}

.background {
    background-color: rgb(255, 57, 195);
    height: 90vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 11px;              /* Abstand statt margin */
    padding: 20px;    
    padding-top: 90px;      /* Luft am Rand */
    box-sizing: border-box;
    text-align: center;
}

.background h1 {
    color: white;
    font-size: 60px;
    margin: 0;       
    font-size: 72px;
    color: #fff8dc;
    text-shadow: 
        2px 2px 6px rgba(0,0,0,0.5),
        0 0 15px rgba(255,215,0,0.7);       /* wichtig: kein extra “push” */
}

.background img {
    width: min(900px, 90vw);
    height: auto;
    max-height: calc(100vh - 140px); /* entscheidend: Bild darf nicht höher als Viewport */
    object-fit: contain;
}

.galleryschrift h1 {
    height: 10vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;         /* Luft am Rand */
    box-sizing: border-box;
    text-align: center;
    font-size: 72px;
    color: #fff8dc;
    text-shadow: 
        2px 2px 6px rgba(0,0,0,0.5),
        0 0 15px rgba(255,215,0,0.7);
}

.title{
  text-align:center;
  margin: 20px 10px;
  font-size: 56px;
}

.gallery{
  max-width: 1100px;
  margin: 0 auto;
  padding: 10px 20px 30px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 12px;
  box-sizing: border-box;
}

.thumb{
  border: 0;
  padding: 0;
  background: rgba(255,255,255,0.15);
  border-radius: 16px;
  overflow: hidden;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0,0,0,0.25);
}

.thumb img{
  width: 100%;
  height: 170px;
  object-fit: cover;
  display: block;
  transition: transform .15s ease;
}

.thumb:hover img{
  transform: scale(1.03);
}

/* Lightbox */
.lightbox{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.85);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.lightbox img{
  max-width: 95vw;
  max-height: 90vh;
  border-radius: 16px;
}

@media (max-width: 768px){
  .title{ font-size: 40px; }
  .thumb img{ height: 150px; }
}

@media (max-width: 768px) {
    .background h1 {
        font-size: 40px;
    }

    .background img {
        max-width: 95%;
    }
}