/* Motion & Ergänzungen — Farben über Tailwind/Stitch-Tokens */

:root {
  --motion-ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --motion-ease-soft: cubic-bezier(0.33, 1, 0.68, 1);
  --motion-duration: 0.7s;
  --motion-duration-short: 0.45s;
  --motion-reveal-y: 32px;
  --motion-stagger-step: 75ms;
  --color-motion-primary: rgba(233, 193, 118, 0.35);
  /* Buchungs-Modal (an Vorlage angelehnt) */
  --booking-modal-bg: #0f1f18;
  --booking-modal-border: rgba(170, 207, 190, 0.14);
  --booking-modal-field-bg: #050d0a;
  --booking-modal-field-border: rgba(193, 200, 195, 0.22);
  --booking-modal-field-border-focus: rgba(233, 193, 118, 0.55);
  --booking-modal-title: #f0faf5;
  --booking-modal-text: rgba(197, 235, 217, 0.92);
  --booking-modal-text-muted: rgba(197, 235, 217, 0.55);
  --booking-modal-label: #d4b878;
  --booking-modal-placeholder: rgba(197, 235, 217, 0.35);
  --booking-modal-close: rgba(240, 250, 245, 0.85);
  --booking-modal-shadow: 0 32px 80px rgba(0, 0, 0, 0.55);
  /* Brotkrumen (IA / interne Verlinkung) */
  --breadcrumb-fg: rgba(197, 235, 217, 0.55);
  --breadcrumb-fg-hover: #e9c176;
  --breadcrumb-current: rgba(197, 235, 217, 0.92);
  --breadcrumb-sep: rgba(170, 207, 190, 0.28);
}

@media (prefers-reduced-motion: no-preference) {
  html {
    scroll-behavior: smooth;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
}

/* ---- Scroll reveal (benötigt class motion-js auf <html>, gesetzt wenn keine reduced-motion) ---- */
@media (prefers-reduced-motion: no-preference) {
  html.motion-js [data-reveal]:not(.reveal--visible) {
    opacity: 0;
    transform: translate3d(0, var(--motion-reveal-y), 0);
    filter: blur(0);
    will-change: opacity, transform;
  }

  html.motion-js [data-reveal].reveal--visible {
    opacity: 1;
    transform: none;
    transition:
      opacity var(--motion-duration) var(--motion-ease-out),
      transform var(--motion-duration) var(--motion-ease-out);
    will-change: auto;
  }

  /* Stagger-Container: Kinder nacheinander */
  html.motion-js [data-reveal-stagger]:not(.is-visible) > * {
    opacity: 0;
    transform: translate3d(0, 24px, 0);
  }

  html.motion-js [data-reveal-stagger].is-visible > * {
    opacity: 1;
    transform: none;
    transition:
      opacity calc(var(--motion-duration) * 0.95) var(--motion-ease-out),
      transform calc(var(--motion-duration) * 0.95) var(--motion-ease-out);
  }

  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(1) {
    transition-delay: calc(var(--motion-stagger-step) * 0);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(2) {
    transition-delay: calc(var(--motion-stagger-step) * 1);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(3) {
    transition-delay: calc(var(--motion-stagger-step) * 2);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(4) {
    transition-delay: calc(var(--motion-stagger-step) * 3);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(5) {
    transition-delay: calc(var(--motion-stagger-step) * 4);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(6) {
    transition-delay: calc(var(--motion-stagger-step) * 5);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(7) {
    transition-delay: calc(var(--motion-stagger-step) * 6);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(8) {
    transition-delay: calc(var(--motion-stagger-step) * 7);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(9) {
    transition-delay: calc(var(--motion-stagger-step) * 8);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(10) {
    transition-delay: calc(var(--motion-stagger-step) * 9);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(11) {
    transition-delay: calc(var(--motion-stagger-step) * 10);
  }
  html.motion-js [data-reveal-stagger].is-visible > *:nth-child(12) {
    transition-delay: calc(var(--motion-stagger-step) * 11);
  }
}

/* ---- Eintritt oben im Viewport (ohne JS) ---- */
@media (prefers-reduced-motion: no-preference) {
  @keyframes motion-page-rise {
    from {
      opacity: 0;
      transform: translate3d(0, 28px, 0);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes motion-fade-in {
    from {
      opacity: 0;
    }
    to {
      opacity: 1;
    }
  }

  @keyframes motion-hero-panel {
    from {
      opacity: 0;
      transform: translate3d(0, 40px, 0) scale(0.98);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes motion-hero-glow {
    from {
      opacity: 0;
      transform: scale(0.92);
    }
    to {
      opacity: 1;
      transform: scale(1);
    }
  }

  @keyframes motion-hero-ken {
    0% {
      transform: scale(1.04);
    }
    100% {
      transform: scale(1.1);
    }
  }

  @keyframes motion-nav-slide {
    from {
      opacity: 0;
      transform: translate3d(0, -16px, 0);
    }
    to {
      opacity: 1;
      transform: none;
    }
  }

  @keyframes motion-scroll-hint {
    0%,
    100% {
      transform: translate3d(0, 0, 0);
      opacity: 0.4;
    }
    50% {
      transform: translate3d(0, 12px, 0);
      opacity: 0.78;
    }
  }

  .anim-page-head {
    animation: motion-page-rise 0.8s var(--motion-ease-out) backwards;
  }

  .anim-page-head-delayed {
    animation: motion-page-rise 0.8s var(--motion-ease-out) 0.12s backwards;
  }

  .anim-fade-soft {
    animation: motion-fade-in 0.9s var(--motion-ease-soft) 0.2s backwards;
  }

  .anim-hero-panel {
    animation: motion-hero-panel 1s var(--motion-ease-out) 0.08s backwards;
  }

  .anim-hero-bg {
    animation: motion-hero-ken 28s var(--motion-ease-soft) infinite alternate;
  }

  .anim-hero-scroll-hint {
    animation: motion-scroll-hint 2.4s var(--motion-ease-soft) infinite;
  }

  .site-nav--enter {
    animation: motion-nav-slide 0.65s var(--motion-ease-out) backwards;
  }

  .anim-hero-eyebrow {
    animation: motion-page-rise 0.65s var(--motion-ease-out) 0.05s backwards;
  }

  .anim-hero-title {
    animation: motion-page-rise 0.85s var(--motion-ease-out) 0.14s backwards;
  }

  .anim-hero-lead {
    animation: motion-page-rise 0.75s var(--motion-ease-out) 0.22s backwards;
  }

  .anim-hero-text {
    animation: motion-page-rise 0.75s var(--motion-ease-out) 0.28s backwards;
  }

  .anim-hero-cta {
    animation: motion-hero-glow 0.7s var(--motion-ease-out) 0.36s backwards;
  }

  .anim-hero-rating {
    animation: motion-fade-in 0.8s var(--motion-ease-soft) 0.5s backwards;
  }
}

/* ---- Dezente Hover-Lift (Karten / CTAs) ---- */
@media (prefers-reduced-motion: no-preference) {
  .motion-lift {
    transition:
      transform var(--motion-duration-short) var(--motion-ease-out),
      box-shadow var(--motion-duration-short) var(--motion-ease-out);
  }

  .motion-lift:hover {
    transform: translate3d(0, -4px, 0);
    box-shadow: 0 16px 40px -12px var(--color-motion-primary);
  }

  .motion-lift:active {
    transform: translate3d(0, -1px, 0);
    transition-duration: 0.12s;
  }
}

@media (prefers-reduced-motion: reduce) {
  .anim-page-head,
  .anim-page-head-delayed,
  .anim-fade-soft,
  .anim-hero-panel,
  .anim-hero-bg,
  .anim-hero-scroll-hint,
  .site-nav--enter,
  .anim-hero-eyebrow,
  .anim-hero-title,
  .anim-hero-lead,
  .anim-hero-text,
  .anim-hero-cta,
  .anim-hero-rating {
    animation: none !important;
  }
}

/* ---- Startseite: Leistungs-Dialog (Vorlage: dunkles Panel, Gold-Labels) ---- */
/* Ohne fixed + inset kann der Dialog im Seitenfluss landen und „im Footer“ erscheinen */
.home-service-dialog {
  padding: 0;
  border: none;
  background: transparent;
  color: var(--booking-modal-text);
  color-scheme: dark;
}

.home-service-dialog:not([open]) {
  display: none;
}

.home-service-dialog[open] {
  position: fixed;
  inset: 0;
  z-index: 200;
  box-sizing: border-box;
  width: 100vw;
  max-width: none;
  min-height: 100vh;
  min-height: 100dvh;
  height: auto;
  max-height: none;
  margin: 0;
  padding: max(12px, env(safe-area-inset-top, 0px)) max(12px, env(safe-area-inset-right, 0px))
    max(12px, env(safe-area-inset-bottom, 0px)) max(12px, env(safe-area-inset-left, 0px));
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  overscroll-behavior: contain;
}

@media (min-width: 768px) {
  .home-service-dialog[open] {
    padding: max(20px, env(safe-area-inset-top, 0px)) max(24px, env(safe-area-inset-right, 0px))
      max(24px, env(safe-area-inset-bottom, 0px)) max(24px, env(safe-area-inset-left, 0px));
  }
}

.home-service-dialog::backdrop {
  background: rgba(0, 12, 8, 0.78);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

@media (prefers-reduced-motion: reduce) {
  .home-service-dialog::backdrop {
    backdrop-filter: none;
    -webkit-backdrop-filter: none;
  }
}

.home-service-dialog__panel {
  width: 100%;
  max-width: min(100%, 32rem);
  flex-shrink: 0;
  background: var(--booking-modal-bg);
  border: 1px solid var(--booking-modal-border);
  border-radius: 12px;
  box-shadow: var(--booking-modal-shadow);
  padding: 24px;
  max-height: min(calc(100dvh - env(safe-area-inset-top, 0px) - env(safe-area-inset-bottom, 0px) - 32px), 680px);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

@media (min-width: 768px) {
  .home-service-dialog__panel {
    padding: 40px;
    max-height: min(90vh, 680px);
  }
}

.home-service-dialog__panel::-webkit-scrollbar {
  width: 6px;
}

.home-service-dialog__panel::-webkit-scrollbar-track {
  background: transparent;
}

.home-service-dialog__panel::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
}

.home-service-dialog__header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 24px;
  padding-bottom: 8px;
}

.home-service-dialog__eyebrow {
  font-family: Manrope, system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--booking-modal-label);
  display: block;
  margin-bottom: 8px;
}

.home-service-dialog__title {
  font-family: "Noto Serif", Georgia, serif;
  font-size: clamp(1.625rem, 4.5vw, 2.125rem);
  font-weight: 700;
  line-height: 1.2;
  letter-spacing: -0.02em;
  color: var(--booking-modal-title);
  margin: 0;
  padding-right: 8px;
}

.home-service-dialog__close {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin: -8px -8px 0 0;
  padding: 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--booking-modal-close);
  cursor: pointer;
  transition: color 0.2s ease, background-color 0.2s ease;
}

.home-service-dialog__close:hover {
  color: var(--booking-modal-label);
  background: rgba(255, 255, 255, 0.04);
}

.home-service-dialog__close:focus-visible {
  outline: 2px solid var(--booking-modal-field-border-focus);
  outline-offset: 2px;
}

.home-service-dialog__desc {
  font-family: Manrope, system-ui, sans-serif;
  font-size: 0.875rem;
  line-height: 1.55;
  color: var(--booking-modal-text);
  margin: 0 0 8px;
}

.home-service-dialog__meta {
  font-family: Manrope, system-ui, sans-serif;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  color: var(--booking-modal-label);
  margin: 0 0 32px;
}

.home-service-dialog__form {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.home-service-dialog__field label {
  font-family: Manrope, system-ui, sans-serif;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--booking-modal-text-muted);
  display: block;
  margin-bottom: 8px;
}

.home-service-dialog__field label .booking-label-opt {
  text-transform: none;
  letter-spacing: normal;
  font-weight: 400;
  color: var(--booking-modal-placeholder);
}

.home-service-dialog__field:focus-within label {
  color: var(--booking-modal-label);
}

.home-service-dialog__input,
.home-service-dialog__select,
.home-service-dialog__textarea {
  width: 100%;
  box-sizing: border-box;
  font-family: Manrope, system-ui, sans-serif;
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--booking-modal-text);
  background: var(--booking-modal-field-bg);
  border: 1px solid var(--booking-modal-field-border);
  border-radius: 10px;
  padding: 14px 16px;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.home-service-dialog__input::placeholder,
.home-service-dialog__textarea::placeholder {
  color: var(--booking-modal-placeholder);
}

.home-service-dialog__input:focus,
.home-service-dialog__select:focus,
.home-service-dialog__textarea:focus {
  outline: none;
  border-color: var(--booking-modal-field-border-focus);
  box-shadow: 0 0 0 1px rgba(233, 193, 118, 0.15);
}

.home-service-dialog__textarea {
  resize: vertical;
  min-height: 88px;
}

.home-service-dialog__select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='20' height='20' viewBox='0 0 24 24' fill='none' stroke='%23d4b878' stroke-width='2' stroke-linecap='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 44px;
}

.home-service-dialog__select option {
  background-color: var(--booking-modal-field-bg);
  color: var(--booking-modal-text);
}

.home-service-dialog__row {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

@media (min-width: 480px) {
  .home-service-dialog__row {
    grid-template-columns: 1fr 1fr;
  }
}

.home-service-dialog__status {
  font-size: 0.875rem;
  min-height: 1.25rem;
  margin: -8px 0 0;
}

.home-service-dialog__submit {
  width: 100%;
  margin-top: 8px;
  padding: 16px 24px;
  border: none;
  border-radius: 10px;
  font-family: Manrope, system-ui, sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: #1a1408;
  background: linear-gradient(135deg, #e9c176 0%, #c9a055 100%);
  cursor: pointer;
  box-shadow: 0 8px 32px rgba(233, 193, 118, 0.22);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.home-service-dialog__submit:hover {
  box-shadow: 0 12px 40px rgba(233, 193, 118, 0.3);
}

.home-service-dialog__submit:active {
  transform: scale(0.99);
}

.home-service-dialog__disclaimer {
  margin-top: 16px;
  font-family: Manrope, system-ui, sans-serif;
  font-size: 9px;
  line-height: 1.5;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--booking-modal-text-muted);
}

.home-service-dialog__status.text-error {
  color: #ffb4ab;
}

.home-service-dialog__status.text-primary {
  color: var(--booking-modal-label);
}

@media (prefers-reduced-motion: reduce) {
  .home-service-dialog__submit {
    transition: none;
  }

  .home-service-dialog__submit:active {
    transform: none;
  }
}

.home-tile-desc-3 {
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.home-service-dialog[open].home-service-dialog--anim {
  animation: home-dialog-in 0.35s var(--motion-ease-out, cubic-bezier(0.22, 1, 0.36, 1)) both;
}

@keyframes home-dialog-in {
  from {
    opacity: 0;
    transform: translate3d(0, 16px, 0) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .home-service-dialog.home-service-dialog--anim {
    animation: none !important;
  }
}

/* ---- Mobile: Grundlagen, Navigation, Touch ---- */
html {
  overflow-x: clip;
}

body {
  overflow-x: clip;
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body.site-nav-drawer-open {
  overflow: hidden;
  touch-action: none;
}

@media (prefers-reduced-motion: no-preference) {
  .site-nav__drawer:not([hidden]) {
    animation: site-nav-drawer-in 0.28s var(--motion-ease-out, cubic-bezier(0.22, 1, 0.36, 1)) both;
  }
}

@keyframes site-nav-drawer-in {
  from {
    opacity: 0;
    transform: translateY(-6px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.site-nav__menu-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border-radius: 10px;
  border: 1px solid rgba(170, 207, 190, 0.22);
  background: rgba(255, 255, 255, 0.04);
  color: rgba(240, 250, 245, 0.92);
  cursor: pointer;
  transition: background-color 0.2s ease, border-color 0.2s ease, color 0.2s ease;
}

.site-nav__menu-btn:hover {
  border-color: rgba(233, 193, 118, 0.35);
  color: #e9c176;
}

.site-nav__menu-btn:focus-visible {
  outline: 2px solid #e9c176;
  outline-offset: 2px;
}

.site-nav__drawer-inner {
  max-height: min(70dvh, calc(100dvh - 5.5rem - env(safe-area-inset-top, 0px)));
  overflow-y: auto;
  overscroll-behavior: contain;
  -webkit-overflow-scrolling: touch;
}

.site-nav__drawer-link {
  display: flex;
  align-items: center;
  min-height: 48px;
  padding: 12px 8px;
  margin: 0 -4px;
  border-radius: 10px;
  font-family: "Noto Serif", Georgia, serif;
  font-size: 0.9375rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  color: rgba(170, 207, 190, 0.95);
  border-bottom: 1px solid rgba(170, 207, 190, 0.08);
  transition: background-color 0.15s ease, color 0.15s ease;
}

.site-nav__drawer-link:last-child {
  border-bottom: none;
}

.site-nav__drawer-link:active {
  background: rgba(255, 255, 255, 0.05);
}

.site-nav__drawer-link--active {
  color: #e9c176;
  border-bottom-color: rgba(233, 193, 118, 0.2);
}

/* Filter-Chips horizontal scroll (Galerie) */
@media (max-width: 767px) {
  .mobile-scroll-chips {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 8px;
    margin: 0 -4px;
    padding-left: 4px;
    padding-right: 4px;
    scroll-snap-type: x proximity;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .mobile-scroll-chips::-webkit-scrollbar {
    display: none;
  }

  .mobile-scroll-chips > * {
    scroll-snap-align: start;
    flex-shrink: 0;
  }
}

/* Galerie: Kategorie-Chips */
.gallery-filter-chip {
  flex-shrink: 0;
  cursor: pointer;
  border-radius: 9999px;
  min-height: 44px;
  padding: 0.5rem 1.25rem;
  font-family: Manrope, system-ui, sans-serif;
  font-size: 0.75rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gallery-chip-fg, rgba(170, 207, 190, 0.95));
  background: transparent;
  border: 1px solid transparent;
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    background 0.2s ease;
}

.gallery-filter-chip:hover {
  color: var(--gallery-chip-fg-hover, #e9c176);
}

.gallery-filter-chip:focus-visible {
  outline: 2px solid #e9c176;
  outline-offset: 2px;
}

.gallery-filter-chip--active {
  color: #e9c176;
  border-color: rgba(233, 193, 118, 0.45);
  background: rgba(25, 59, 47, 0.55);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

@media (prefers-reduced-motion: reduce) {
  .gallery-filter-chip {
    transition: none;
  }
}

/* Eingebettete Karte (Kontakt / Buchung) */
.site-map-panel {
  --site-map-radius: 0.5rem;
}

.site-map-panel__viewport {
  isolation: isolate;
}

.site-map-panel__iframe {
  display: block;
}

.site-map-panel__caption a:focus-visible {
  outline: 2px solid var(--breadcrumb-fg-hover);
  outline-offset: 2px;
}

@media (prefers-reduced-motion: reduce) {
  .site-map-panel.motion-lift {
    transition: none;
  }
}

.site-breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  row-gap: 8px;
  column-gap: 0;
  list-style: none;
  margin: 0;
  padding: 0;
  font-family: Manrope, system-ui, sans-serif;
  font-size: 0.6875rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-breadcrumb__item {
  display: inline-flex;
  align-items: center;
}

.site-breadcrumb__item:not(:last-child)::after {
  content: "/";
  color: var(--breadcrumb-sep);
  pointer-events: none;
  font-weight: 300;
}

.site-breadcrumb__link {
  color: var(--breadcrumb-fg);
  text-decoration: none;
  border-radius: 4px;
  padding: 4px 0;
  transition: color 0.2s var(--motion-ease-soft);
}

.site-breadcrumb__link:hover {
  color: var(--breadcrumb-fg-hover);
}

.site-breadcrumb__link:focus-visible {
  outline: 2px solid var(--breadcrumb-fg-hover);
  outline-offset: 2px;
}

.site-breadcrumb__current {
  color: var(--breadcrumb-current);
  font-weight: 500;
  padding: 4px 0;
}

@media (prefers-reduced-motion: reduce) {
  .site-breadcrumb__link {
    transition: none;
  }

  .site-nav__drawer:not([hidden]) {
    animation: none !important;
  }
}
