/* ===== Lokale Schriftarten (100% DSGVO-konform) ===== */
/* Playfair Display - Normal */
@font-face {
  font-family: 'Playfair Display';
  font-style: normal;
  font-weight: 400;
  src: url('PlayfairDisplay-Regular.ttf') format('truetype');
}

/* Playfair Display - Fett */
@font-face {
  font-family: 'Playfair Display';
  font-style: normal;
  font-weight: 700;
  src: url('PlayfairDisplay-Bold.ttf') format('truetype');
}

/* ===== Reset & Basis ===== */
* { box-sizing: border-box; }
body { font-family: Georgia, serif; margin: 0; color: #2c3e50; background: #f4f8fa; }
a { color: #1d5a7a; text-decoration: none; }
a:hover { text-decoration: underline; }

/* ===== Header ===== */
header { 
  background: transparent; 
  color: #fff; 
  position: fixed;         /* Hält den Header fest oben auf der Scheibe */
  top: 0;
  left: 0;
  width: 100%;             
  z-index: 20;             /* Höchste Ebene */
}

/* Der innere Container bekommt nun auch auf dem Desktop seine saubere Rolle: */
.header-inner {
  max-width: 100%;
  margin: 0;
  padding: 20px 20px 4px 20px; /* Genug Luft nach oben für das große Logo */
  min-height: 60px;
  
  /* Robustes Flexbox-Layout für perfekte Browser-Symmetrie */
  display: flex;
  align-items: center; 
  justify-content: space-between;
}

/* Das Logo-Bild (Links) - komplett ohne absolute Positionierung */
.header-logo {
  height: 140px;          /* Deine Wunschgröße auf dem Desktop */
  width: auto;           
  display: block;
  flex: 0 0 auto;         /* Verhindert jegliche Stauchung */
  filter: drop-shadow(2px 2px 4px rgba(0,0,0,0.5)); 
}

/* Der Überschriftentext (Mitte) - zentriert sich im verbleibenden Raum */
.header-inner h1 { 
  margin: 0;             
  font-weight: 700;       /* Knackig fett */

  /* Stufenlos auf dem Desktop: schrumpft sanft, bevor der mobile Modus bei 960px zündet */
  font-size: clamp(2.2em, 3.0vw, 4.7em); 
  text-align: center;
  white-space: nowrap;   
  font-family: 'Playfair Display', serif; 
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.85); 
  flex: 1;                /* Nimmt sich den gesamten mittleren Platz */
  padding: 0 20px;
}

/* Der Sprachwahlschalter (Rechts) - Desktop vertikal */
.lang-switch { 
  display: flex; 
  flex-direction: column; /* Richtet die Sprachen untereinander aus */
  gap: 4px;               /* Kompakter Abstand zwischen den Zeilen */
  position: absolute;
  top: 20px;              /* Auf exakt gleicher Höhe wie die Oberkante des Logos */
  right: 20px;            
}

.lang-switch a { 
  color: #fff; 
  opacity: 0.85;        
  padding: 4px 8px; 
  border-radius: 4px; 
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.6); 
  font-family: sans-serif; /* Macht die Emoji-Darstellung stabiler */
}

.lang-switch a.active, .lang-switch a:hover { 
  opacity: 1; 
  background: rgba(255, 255, 255, 0.25); 
}

/* ===== Hero ===== */
.hero {
  position: fixed;      /* Fixiert das Bild fest am oberen Bildschirmrand */
  top: 0;
  left: 0;
  width: 100%;
  height: 220px;        /* Definiert die feste Höhe der Kulisse */
  z-index: 10;          /* Liegt hinter dem Header, aber vor dem Body */
}

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

/* ===== Cards Grid ===== */
.cards-grid { 
  display: grid; 
  grid-template-columns: repeat(2, 1fr); 
  gap: 25px; 
  max-width: 900px; 
  margin: 260px auto 40px auto; 
  padding: 0 20px; 
  position: relative; 
  z-index: 1;                  
}

/* Die neue Karte als Bildträger */
.card { 
  background-size: cover;
  background-position: center;
  position: relative;
  border-radius: 8px; 
  padding: 40px 30px; 
  text-align: center; 
  cursor: default; 
  overflow: hidden;
  min-height: 250px; 
  display: flex;
  flex-direction: column;
  justify-content: center;
}

/* Bildzuordnung für die vier Karten */
.card:nth-child(1) { background-image: url('PANO0001_Pano.jpg'); }
.card:nth-child(2) { background-image: url('Wohnzimmer_1000.jpg'); }
.card:nth-child(3) { background-image: url('hero.webp'); }
.card:nth-child(4) { background-image: url('Schlafzimmer_1000.jpg'); }

/* Der dunkle Schutzfilm für lesbaren Text */
.card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.45); 
  z-index: 1;
}

/* Texte und Knöpfe über den Film zwingen */
.card h3, .card p, .card .button-group {
  position: relative;
  z-index: 2;
  color: #fff; 
}

.card h3 { 
  margin: 0 0 12px; 
  font-weight: normal; 
  font-size: 1.5em;
  text-shadow: 1px 1px 4px rgba(0,0,0,0.6);
}

.card p { 
  margin: 0 0 20px 0; 
  color: #f0f4f8; 
  font-size: 0.95em; 
  text-shadow: 1px 1px 3px rgba(0,0,0,0.6);
}

/* Das alte Emoji-Icon komplett unsichtbar schalten */
.card .icon { 
  display: none; 
}

.card:hover { 
  /* Nimmt den alten Hover-Hintergrund weg, da jetzt das Bild wirkt */
  background: transparent; 
}

.button-group {
  display: flex;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-pano {
  display: inline-block;
  padding: 10px 20px;
  margin: 4px;
  border-radius: 6px;
  background: #1d5a7a;
  color: #fff;
  text-decoration: none;
  font-size: 0.9em;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-pano:hover {
  transform: translateY(-3px);
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
  background: #17506e;
}


/* ===== Modal ===== */
.modal { 
  display: none; 
  position: fixed; 
  z-index: 1000; 
  left: 0; 
  top: 0; 
  width: 100%; 
  height: 100%; 
  overflow-y: auto; 
  background: rgba(0,0,0,0.7); 
}

.modal-content { 
  background: #fff; 
  margin: 3% auto; 
  padding: 30px; 
  max-width: 900px; 
  border-radius: 8px; 
  position: relative; 
  max-height: 90vh; 
  overflow-y: auto; 
}

.close { 
  position: absolute; 
  top: 15px; 
  right: 20px; 
  font-size: 2em; 
  cursor: pointer; 
  color: #666; 
}

.close:hover { 
  color: #000; 
}

.modal-content h2 { 
  margin: 0 0 20px; 
  color: #1d5a7a; 
  font-weight: normal; 
}

/* ===== Panorama Modal ===== */
.pano-full { 
  width: 100%; 
  height: 70vh; 
  min-height: 400px; 
}

#pano-modal .modal-content {
  padding: 8px;
  overflow: hidden;
}

/* ===== Gallery Modal ===== */
.gallery-modal .gallery-grid { 
  display: grid; 
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); 
  gap: 15px; 
}

.gallery-modal .gallery-grid img { 
  width: 100%; 
  height: 150px; 
  object-fit: cover; 
  border-radius: 6px; 
}

/* ===== Destinations Modal ===== */
.destination-list { 
  list-style: none; 
  padding: 0; 
}

.destination-list li { 
  padding: 12px; 
  border-bottom: 1px solid #eee; 
}

.destination-list li:last-child { 
  border-bottom: none; 
}

/* ===== Booking Modal ===== */
.booking-modal .calendar-container { 
  margin: 25px 0; 
}

.booking-modal .payment-info { 
  margin-top: 25px; 
}

.booking-modal .payment-info h3 { 
  margin-top: 0; 
  color: #1d5a7a; 
}

.qr-code { 
  display: block; 
  width: 180px; 
  height: 180px; 
  margin: 15px auto; 
}

.bank-table { 
  width: 100%; 
  font-size: 0.95em; 
}

.bank-table td { 
  padding: 6px 8px 6px 0; 
  vertical-align: top; 
}

.payment-note { 
  font-size: 0.85em; 
  color: #667; 
  margin-top: 15px; 
  font-style: italic; 
}

.btn { 
  display: inline-block; 
  padding: 14px 28px; 
  border-radius: 6px; 
  text-decoration: none; 
  margin-top: 20px; 
}

.btn-primary { 
  background: #1d5a7a; 
  color: #fff; 
}

.btn-primary:hover { 
  background: #17506e; 
  text-decoration: none; 
}

/* ===== Footer ===== */
footer { 
  background: #1d5a7a; 
  color: #fff; 
  text-align: center; 
  padding: 2px; 
  position: sticky;
  top: 100vh;
}

.footer-inner { 
  max-width: 900px; 
  margin: 0 auto; 
}

footer a { 
  color: #cfe3ee; 
}

footer p {
  margin: 4px;
}

/* ===== Responsive: Tablets (Karten auf 1 Spalte setzen) ===== */
@media (max-width: 900px) {
  .cards-grid { 
    grid-template-columns: 1fr; 
    margin-top: 260px; 
  }
}

/* ===== Responsive: Mobile & Tablets (Header-Umschaltung ab 960px) ===== */
@media (max-width: 960px) {
  .header-inner {
    display: grid;
    grid-template-columns: 1fr 1fr; 
    gap: 15px 10px;
    padding: 15px 20px;
    min-height: auto;
  }
  
  .header-logo {
    height: 75px;         
    grid-column: 1;                 
    grid-row: 1;                    
    justify-self: start;            
  }
  
  .lang-switch {
    margin-left: 0;       
    grid-column: 2;                 
    grid-row: 1;                    
    justify-self: end;              
    flex-direction: row; 
  }
  
  .header-inner h1 {
    white-space: normal;  
    font-size: clamp(1.2em, 4.5vw, 2.0em); 
    grid-column: 1 / span 2;        
    grid-row: 2;                    
    text-align: center;
    padding: 0;
  }
  
  .modal-content { 
    margin: 5% auto; 
    padding: 20px; 
  }
  
  .pano-full { 
    height: 50vh; 
    min-height: 300px; 
  }
  
  .calendar-container iframe { 
    height: 400px; 
  }
}

/* ===== Zusätzlicher Umschaltpunkt NUR für echte Smartphones (unter 600px) ===== */
@media (max-width: 600px) {
  .modal-content { 
    margin: 5% auto; 
    padding: 20px; 
  }
  
  .pano-full { 
    height: 50vh; 
    min-height: 300px; 
  }
  
  .calendar-container iframe { 
    height: 400px; 
  }
}
