/*
 Theme Name:     Divi Child Theme
 Theme URI:      http://www.elegantthemes.com
 Description:    Child Theme for Divi Theme by Elegant Themes
 Author:         Divi.world
 Author URI:     http://divi.world
 Template:       Divi
 Version:        1.0.0
*/
 
/* =Ab hier kannst du deine CSS-Anpassungen eintragen
------------------------------------------------------- */
#main-content {
    background-color: #d56619;
}
#cmplz-document p, #cmplz-document li, #cmplz-document td, .editor-styles-wrapper .cmplz-unlinked-mode p, .editor-styles-wrapper .cmplz-unlinked-mode li, .editor-styles-wrapper .cmplz-unlinked-mode td {
    font-size: 18px;
    margin-top: 0;
}

/* === Top-Bar fest oben fixieren — funktioniert auf jedem Gerät === */
#top-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100001;
}

/* Page-Container muss um Top-Bar-Höhe nach unten geschoben werden */
#page-container {
  padding-top: 43px !important;
}

/* Im Sticky-State von Divi rutscht das Hauptmenü unter den Top-Bar */
.et-fixed-header #main-header {
  top: 3px !important;
}

/* === Mobile-Menü früher aktivieren — bei 1340px statt 980px === */
@media (max-width: 1340px) {
  #et_mobile_nav_menu {
    display: block;
  }
  #top-menu,
  #et-top-navigation > nav,
  #et_top_search,
  #et-top-navigation .et_search_form_container {
    display: none !important;
  }
  .et_header_style_left #et-top-navigation,
  .et_header_style_split #et-top-navigation {
    padding: 18px 0 !important;
  }
}



/* ============================================================
   Klosterhof Standard-Header Anchor-Navigation – Aktiv-Indikator
   ============================================================ */

/* Smooth-Scroll + Padding für Anker unter dem sticky Header */


/* Menü-Items: Position relativ, damit Unterstrich darunter passt */
#top-menu li > a,
#et-secondary-menu li > a,
#et-top-navigation li > a {
    position: relative;
    transition: color 0.2s ease;
}

/* Standard-Zustand: transparenter Strich für Smooth-Übergang */
#top-menu li > a::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    top: calc(50% + 0.1em);   /* ← Mittelachse + halbe Texthöhe */
    height: 3px;
    background-color: transparent;
    border-radius: 2px;
    transition: background-color 0.25s ease;
}

/* Aktiv-Zustand: oranger Strich */
#top-menu li.lp-active > a::after {
    background-color: #d56618;
}

/* Strich beim Hover anzeigen */
#top-menu li > a:hover::after {
    background-color: #d56618;
}



/* Divi-Standard-Hover-Effekt für Textfarbe deaktivieren */
/* WICHTIG: 'color' wird NICHT überschrieben, damit der Customizer
   die Farbe steuern kann (auch im Fixed-Header-Zustand) */
#top-menu li > a:hover {
    opacity: 1 !important;
    transition: none !important;
}
/* Mobile: dichter ans Item heran */
@media (max-width: 980px) {
    #top-menu li.lp-active > a::after {
        top: calc(50% + 0.1em);
    }
}


/* ============================================================
   Sprachenwahl: ;
   ============================================================ */

/* Sprachauswahl im Sekundär-Menü */
#et-secondary-menu .menu-item a {
    font-size: 14px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 0 8px;
}

/* Trennstrich zwischen DE und EN */
#et-secondary-menu .menu-item + .menu-item::before {
    content: "";
    position: absolute;
    left: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 1px;
    height: 20px;
    background-color: rgba(255, 255, 255, 0.5);
}

/* Aktuelle Sprache hervorheben — eleganter Unterstrich mit Abstand */
#et-secondary-menu .current-menu-item a {
    font-weight: 600;
    opacity: 1;
    text-decoration: underline;
    text-decoration-color: #ffffff;       /* Klosterhof-Orange wie Hauptnavi */
    text-decoration-thickness: 2px;       /* etwas kräftiger als Default */
    text-underline-offset: 5px;           /* der Schlüssel: Abstand zum Text */
}

/* Andere Sprachen leicht zurückgenommen */
#et-secondary-menu .menu-item:not(.current-menu-item) a {
    opacity: 0.75;
}

#et-secondary-menu .menu-item:not(.current-menu-item) a:hover {
    opacity: 1;
}


/* ============================================================
   resmio Consent-Platzhalter
   ============================================================ */

.resmio-wrapper {
    min-height: 520px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.resmio-placeholder-box {
    background: #f5efe6;
    border: 2px dashed #d56618;
    border-radius: 8px;
    padding: 40px 30px;
    max-width: 480px;
    width: 100%;
}

.resmio-placeholder-inner {
    text-align: center;
}

.resmio-placeholder-inner strong {
    font-size: 18px;
    display: block;
    margin-bottom: 12px;
    color: #3a2f25;
}

.resmio-placeholder-inner p {
    color: #3a2f25;
    margin-bottom: 20px;
    line-height: 1.5;
}

.resmio-placeholder-inner button {
    background: #d56618;
    color: #FFFFFF;
    border: none;
    padding: 14px 28px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 15px;
    font-weight: 600;
    transition: background 0.2s ease;
    margin-bottom: 16px;
}

.resmio-placeholder-inner button:hover {
    background: #b8530f;
}

.resmio-placeholder-inner .resmio-note {
    font-size: 12px;
    color: #666;
    margin-top: 12px;
    margin-bottom: 0;
}

.resmio-placeholder-inner .resmio-note a {
    color: #d56618;
    text-decoration: underline;
}



/* ============================================================
   Responsive Tabellen auf Mobile (z.B. DSE Cookie-Liste)
   ============================================================ */

@media (max-width: 767px) {
    
    /* Tabelle wird zur Block-Darstellung */
    .entry-content table,
    .et_pb_post_content table {
        display: block;
        width: 100%;
        border: none;
    }
    
    /* Tabellen-Header verstecken (Labels kommen per ::before) */
    .entry-content table thead,
    .et_pb_post_content table thead {
        position: absolute;
        left: -9999px;
        top: -9999px;
    }
    
    /* Jede Zeile wird zu einer Card */
    .entry-content table tbody,
    .et_pb_post_content table tbody {
        display: block;
    }
    
    .entry-content table tbody tr,
    .et_pb_post_content table tbody tr {
        display: block;
        margin-bottom: 1em;
        padding: 12px 16px;
        background: rgba(255, 255, 255, 0.08);
        border: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 6px;
    }
    
    /* Jede Zelle als eigene Zeile */
    .entry-content table tbody td,
    .et_pb_post_content table tbody td {
        display: block;
        text-align: left;
        padding: 4px 0;
        border: none;
    }
    
    /* Labels per pseudo-element vor jeder Zelle */
    .entry-content table tbody td:nth-of-type(1)::before,
    .et_pb_post_content table tbody td:nth-of-type(1)::before {
        content: "Cookie: ";
        font-weight: 700;
        display: inline-block;
        min-width: 110px;
    }
    
    .entry-content table tbody td:nth-of-type(2)::before,
    .et_pb_post_content table tbody td:nth-of-type(2)::before {
        content: "Zweck: ";
        font-weight: 700;
        display: inline-block;
        min-width: 110px;
    }
    
    .entry-content table tbody td:nth-of-type(3)::before,
    .et_pb_post_content table tbody td:nth-of-type(3)::before {
        content: "Speicherdauer: ";
        font-weight: 700;
        display: inline-block;
        min-width: 110px;
    }
    
    /* Code-Tags umbrechbar machen */
    .entry-content table code,
    .et_pb_post_content table code {
        word-break: break-all;
        display: inline;
    }
}


@media screen and (max-width: 980px) {
  #main-header.et-fixed-header {
    position: fixed;
    top: 0 !important;
  }
}


@media (max-width: 980px) {
  #kh-reservierung { display: flex !important; flex-direction: column !important; }
  #kh-reservierung #kh-hinweis { order: -1 !important; }
}



/* =========================================================
   Klosterhof: Online-Reservierung als Modal
   ========================================================= */

/* --- 1. Reservierungs-Button am Slider-Rand --- */
.kh-reserve-trigger {
  position: relative;
  z-index: 100;
  margin: 0 auto !important;
  transform: translateY(-50%);
  text-align: center;
}
.kh-reserve-trigger img {
  cursor: pointer;
  transition: transform .2s ease, filter .2s ease;
}
.kh-reserve-trigger a:hover img,
.kh-reserve-trigger a:focus-visible img {
  transform: scale(1.04);
  filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .35));
}

/* --- 2. Slider-Punkte blockieren den Button nicht --- */
.et_pb_slider .et-pb-controllers {
  pointer-events: none;
  bottom: 70px; /* Wert wie auf DEV */
}
.et_pb_slider .et-pb-controllers a {
  pointer-events: auto;
}

/* --- 3. Modal: Grundgerüst --- */
.kh-modal {
  position: fixed;
  inset: 0;
  z-index: 2147483000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  background: rgba(0, 0, 0, .7);
  opacity: 0;
  visibility: hidden;
  transition: opacity .25s ease, visibility .25s ease;
}
.kh-modal.is-open {
  opacity: 1;
  visibility: visible;
}
.kh-modal__dialog {
  position: relative;
  width: 100%;
  max-width: 1100px;
  max-height: 90vh;
  max-height: 90dvh;
  overflow-y: auto;
  background: #1b1615;
  border: 1px solid #c96d2b;
  border-radius: 10px;
  padding: 56px 32px 32px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, .5);
  transform: translateY(20px);
  transition: transform .25s ease;
}
.kh-modal.is-open .kh-modal__dialog {
  transform: none;
}
.kh-modal__close {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 44px;
  height: 44px;
  border: 0;
  background: transparent;
  font-size: 32px;
  line-height: 1;
  color: #f3d9a4;
  cursor: pointer;
}
.kh-modal__close:hover,
.kh-modal__close:focus-visible {
  color: #c96d2b;
}
body.kh-modal-open {
  overflow: hidden;
}

/* --- 4. Modal-Inhalt: Text links, Widget rechts --- */
.kh-modal .et_pb_row {
  width: 100% !important;
  max-width: none !important;
  margin: 0 !important;
  padding: 0 !important;
  display: flex !important;
  flex-direction: row-reverse;
  align-items: flex-start;
  gap: 40px;
  background: transparent !important;
}
.kh-modal .et_pb_column {
  margin: 0 !important;
  padding: 0 !important;
  float: none !important;
}
.kh-modal .et_pb_column:first-child { /* Widget */
  flex: 0 0 480px;
  width: 480px !important;
  max-width: 100%;
}
.kh-modal .et_pb_column:last-child { /* Hinweistext */
  flex: 1 1 0;
  width: auto !important;
  min-width: 0;
}
.kh-modal .et_pb_code {
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
}
.kh-modal .et_pb_code_inner {
  display: flex;
  justify-content: center;
}
.kh-modal .et_pb_code_inner > *,
.kh-modal iframe {
  margin-left: auto !important;
  margin-right: auto !important;
  max-width: 100%;
}
.kh-modal .et_pb_text {
  margin: 0 !important;
  font-size: 16px;
  text-align: left;
  overflow-wrap: anywhere;
}
.kh-modal .et_pb_text p {
  line-height: 1.45 !important;
  padding-bottom: .8em;
}
.kh-modal .et_pb_text h1,
.kh-modal .et_pb_text h2,
.kh-modal .et_pb_text h3 {
  line-height: 1.2 !important;
  padding-bottom: .4em;
}
.kh-modal .et_pb_text h1,
.kh-modal .et_pb_text h2 {
  font-size: 32px !important;
}
.kh-modal .et_pb_text a {
  font-size: inherit;
}

/* --- 5. Tablet & Handy: Hinweistext oben, Widget darunter --- */
@media (max-width: 980px) {
  .kh-modal__dialog {
    padding: 52px 16px 20px;
  }
  .kh-modal__dialog,
  .kh-modal.is-open .kh-modal__dialog {
    transform: none;
    transition: none;
  }
  .kh-modal .et_pb_row {
    flex-direction: column-reverse;
    gap: 28px;
  }
  .kh-modal .et_pb_column:first-child,
  .kh-modal .et_pb_column:last-child {
    flex: none;
    width: 100% !important;
  }
  .kh-modal .et_pb_text {
    text-align: center;
  }
  .kh-modal .et_pb_text h1,
  .kh-modal .et_pb_text h2 {
    font-size: 26px !important;
  }
  .kh-modal__close {
    position: fixed;
    top: calc(env(safe-area-inset-top, 0px) + 12px);
    right: 12px;
    border-radius: 50%;
    background: rgba(27, 22, 21, .92);
    border: 1px solid #c96d2b;
    z-index: 2;
  }
}