/* Pension Hartenstein · Styling System */

:root {
  --color-forest: #223727;
  --color-forest-dark: #16241a;
  --color-forest-light: #37533d;
  --color-sage: #7d9682;
  --color-sage-light: #eaf0eb;
  --color-sand: #faf7f2;
  --color-sand-card: #f3efe6;
  --color-sand-border: #e6ded0;
  --color-amber: #c58245;
  --color-amber-soft: #f8eee2;
  --color-charcoal: #1c221e;
  --color-charcoal-muted: #576159;
}

body {
  font-family: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background-color: var(--color-sand);
  color: var(--color-charcoal);
  overflow-x: hidden;
  scroll-behavior: smooth;
  text-rendering: optimizeLegibility;
}

.font-serif {
  font-family: 'Cormorant Garamond', Georgia, serif;
}

/* Glassmorphism Navigation */
.glass-nav {
  background: rgba(250, 247, 242, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid rgba(214, 203, 187, 0.5);
}

/* Subtle Card Shadows */
.card-elevation {
  box-shadow: 0 4px 20px -2px rgba(34, 55, 39, 0.05), 0 2px 6px -1px rgba(34, 55, 39, 0.03);
  transition: all 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.card-elevation:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px -4px rgba(34, 55, 39, 0.09), 0 6px 12px -2px rgba(34, 55, 39, 0.04);
}

/* Image Zoom Effect */
.img-zoom {
  transition: transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

.group:hover .img-zoom {
  transform: scale(1.04);
}

/* ================= HERO SECTION ================= */
.hero-perfect-bg {
  position: relative;
  background-color: #faf7f2;
}

/* Das reale Hausfoto: Groß, füllt die rechte Seite des Hero und reicht bis zum rechten Viewport-Rand */
.hero-perfect-bg::before {
  content: '';
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 50%;
  background-image: url('../images/hero-house-crisp.png');
  background-position: right center;
  background-repeat: no-repeat;
  background-size: cover;
  pointer-events: none;
  z-index: 1;
  /* Bild-Maske: maximal 70px Fade links und dezenter 40px Fade unten in die exakt gleiche Cremefarbe (#faf7f2) */
  -webkit-mask-image: linear-gradient(to right, transparent 0px, #000 70px),
                      linear-gradient(to bottom, #000 calc(100% - 40px), transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(to right, transparent 0px, #000 70px),
              linear-gradient(to bottom, #000 calc(100% - 40px), transparent 100%);
  mask-composite: intersect;
}

@media (max-width: 1024px) {
  .hero-perfect-bg::before {
    left: 35%;
    opacity: 0.35;
    -webkit-mask-image: linear-gradient(to right, transparent 0px, #000 50px),
                        linear-gradient(to bottom, #000 calc(100% - 40px), transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(to right, transparent 0px, #000 50px),
                linear-gradient(to bottom, #000 calc(100% - 40px), transparent 100%);
    mask-composite: intersect;
  }
}

@media (max-width: 640px) {
  .hero-perfect-bg::before {
    left: 0;
    opacity: 0.18;
    background-position: center top;
    -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 20%, #000 calc(100% - 40px), transparent 100%);
    mask-image: linear-gradient(to bottom, transparent 0%, #000 20%, #000 calc(100% - 40px), transparent 100%);
  }
}

/* 3. Feature-Zeile: 3-Spalten-Layout mit gleicher Nutzbreite */
.hero-feature-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
  align-items: start;
}

@media (max-width: 640px) {
  .hero-feature-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}


/* ================= CALENDAR STYLES ================= */
.calendar-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 6px;
}

.cal-day-cell {
  position: relative;
  aspect-ratio: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  font-size: 0.85rem;
  font-weight: 500;
  transition: all 0.2s ease;
  cursor: pointer;
  user-select: none;
  border: 1px solid transparent;
}

/* Status variants */
.cal-day-cell.is-past {
  opacity: 0.35;
  cursor: not-allowed;
  background: transparent;
}

.cal-day-cell.is-free {
  background-color: #ffffff;
  border-color: #e5ede6;
  color: #1e2820;
}
.cal-day-cell.is-free:hover {
  background-color: #eaf3ec;
  border-color: #a3c2a9;
  transform: scale(1.06);
  z-index: 2;
}

.cal-day-cell.is-limited {
  background-color: #fffaf2;
  border-color: #f7e6d0;
  color: #7c4819;
}
.cal-day-cell.is-limited:hover {
  background-color: #faefde;
  border-color: #e5b983;
  transform: scale(1.06);
  z-index: 2;
}

.cal-day-cell.is-booked {
  background-color: #f3f3f3;
  border-color: #e8e8e8;
  color: #9e9e9e;
  cursor: not-allowed;
  text-decoration: line-through;
  opacity: 0.65;
}

/* Range Selection in Calendar */
.cal-day-cell.is-selected-start {
  background-color: var(--color-forest) !important;
  color: #ffffff !important;
  font-weight: 700;
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
  box-shadow: 0 4px 10px rgba(34, 55, 39, 0.3);
}

.cal-day-cell.is-selected-end {
  background-color: var(--color-forest) !important;
  color: #ffffff !important;
  font-weight: 700;
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
  box-shadow: 0 4px 10px rgba(34, 55, 39, 0.3);
}

.cal-day-cell.is-selected-single {
  background-color: var(--color-forest) !important;
  color: #ffffff !important;
  font-weight: 700;
  box-shadow: 0 4px 12px rgba(34, 55, 39, 0.3);
}

.cal-day-cell.is-in-range {
  background-color: #dbebe0 !important;
  color: #17311e !important;
  border-radius: 2px;
}

/* Calendar status dot */
.cal-dot {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  margin-top: 2px;
}
.cal-dot.dot-free {
  background-color: #2e7d32;
}
.cal-dot.dot-limited {
  background-color: #ed6c02;
}
.cal-dot.dot-booked {
  background-color: #d32f2f;
}

/* ================= COOKIE BANNER ================= */
.cookie-banner-wrap {
  position: fixed;
  bottom: 24px;
  right: 24px;
  max-width: 440px;
  width: calc(100% - 48px);
  z-index: 9999;
  transform: translateY(120%);
  opacity: 0;
  transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.5s ease;
}

.cookie-banner-wrap.is-visible {
  transform: translateY(0);
  opacity: 1;
}

/* Handy: schmaler Streifen am unteren Rand statt Karte über dem Inhalt */
@media (max-width: 639px) {
  .cookie-banner-wrap { left: 0; right: 0; bottom: 0; width: 100%; max-width: none; }
  .cookie-banner-wrap > div { display: flex; align-items: center; gap: 12px; padding: 10px 16px; border-radius: 0; border-width: 1px 0 0; }
  .cookie-banner-wrap > div > * { margin-top: 0 !important; }
  .cookie-banner-wrap > div > div:first-child { display: none; }
  .cookie-banner-wrap p { flex: 1; font-size: 11px; line-height: 1.4; }
  .cookie-banner-wrap > div > div:last-child { padding-top: 0; flex-shrink: 0; }
}

/* Custom Checkbox / Radio styling */
.custom-option-card {
  cursor: pointer;
  transition: all 0.25s ease;
  border: 2px solid transparent;
}
.custom-option-card.active {
  border-color: var(--color-forest);
  background-color: #ffffff;
  box-shadow: 0 4px 14px rgba(34, 55, 39, 0.08);
}

/* Google Maps Container */
.map-responsive-container {
  overflow: hidden;
  padding-bottom: 56.25%;
  position: relative;
  height: 0;
  border-radius: 1.5rem;
}
.map-responsive-container iframe {
  left: 0;
  top: 0;
  height: 100%;
  width: 100%;
  position: absolute;
  border: 0;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
  width: 7px;
}
::-webkit-scrollbar-track {
  background: var(--color-sand);
}
::-webkit-scrollbar-thumb {
  background: #c3d1c6;
  border-radius: 9999px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--color-sage);
}

/* Logo: Kastanienblatt als transparentes Wasserzeichen hinter "HARTENSTEIN" */
.brand-mark { position: relative; isolation: isolate; }
.brand-mark__leaf {
  position: absolute; z-index: -1; left: 50%; top: 50%;
  width: 92px; height: 92px;
  transform: translate(-30%, -58%) rotate(-14deg);
  opacity: .17; pointer-events: none;
  transition: transform .8s cubic-bezier(.16, 1, .3, 1), opacity .8s;
}
.brand-mark:hover .brand-mark__leaf { transform: translate(-30%, -58%) rotate(0deg); opacity: .22; }
@media (prefers-reduced-motion: reduce) { .brand-mark__leaf { transition: none; } }

/* Neuer Button-/Menütext bei exakt gleicher Grösse:
   Der bisherige Text bleibt unsichtbar stehen und hält in jeder Bildschirmbreite
   genau die alte Breite und Höhe. Der neue Text (data-label) liegt zentriert darüber. */
.keep-size { position: relative; -webkit-text-fill-color: transparent; }
.keep-size::after {
  content: attr(data-label);
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center; text-align: center; white-space: nowrap;
  -webkit-text-fill-color: currentColor; pointer-events: none;
}
